Skip to content

Commit

Permalink
[sqitch] Have sqitch also push PERL5LIB to the runtime_env, so that T…
Browse files Browse the repository at this point in the history
…ry::Tiny is found.

Also fix CODEOWNERS

Signed-off-by: Irving Popovetsky irving@chef.io
  • Loading branch information
Irving Popovetsky committed Jun 27, 2018
1 parent 57d24b2 commit 3ffb04e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,6 @@ lessmsi @mwrock
visual-cpp-build-tools-2015 @mwrock
visual-cpp-redist-2013 @mwrock
wix @mwrock
postgresql-client @joshbrand @irvingpop

# # Community Plans
#
Expand Down Expand Up @@ -155,6 +154,7 @@ nuget @mwrock
optipng @predominant
pango @rsertelon
pngquant @predominant
postgresql-client @joshbrand @irvingpop
protobuf-cpp @afiune
rabbitmqadmin @predominant
redis @irvingpop
Expand Down
12 changes: 8 additions & 4 deletions sqitch/plan.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,14 @@ pkg_build_deps=(core/gcc core/make core/coreutils core/perl core/local-lib core/
pkg_lib_dirs=(lib)
pkg_bin_dirs=(bin)

do_setup_environment() {
push_runtime_env PERL5LIB "${pkg_prefix}/lib/perl5:${pkg_prefix}/lib/perl5/x86_64-linux-thread-multi"
}

do_prepare() {
eval "$(perl -I$(pkg_path_for core/local-lib)/lib/perl5 -Mlocal::lib=$(pkg_path_for core/local-lib))"
eval "$(perl -I"$(pkg_path_for core/local-lib)"/lib/perl5 -Mlocal::lib="$(pkg_path_for core/local-lib)")"
# Create a new lib dir in our pacakge for cpanm to house all of its libs
eval $(perl -Mlocal::lib=${pkg_prefix})
eval "$(perl -Mlocal::lib="${pkg_prefix}")"

cpanm Module::Build
}
Expand All @@ -32,8 +36,8 @@ do_install() {
./Build
./Build install

for file in ${pkg_prefix}/bin/*; do
sed -i "1 s,.*,& -I${pkg_prefix}/lib/perl5," $file
for file in "${pkg_prefix}"/bin/*; do
sed -i "1 s,.*,& -I${pkg_prefix}/lib/perl5," "$file"
done
}

Expand Down

0 comments on commit 3ffb04e

Please sign in to comment.