[CalendarServer-changes] [7572] CalendarServer/branches/users/glyph/deploybuild
source_changes at macosforge.org
source_changes at macosforge.org
Tue Jun 7 17:01:27 PDT 2011
Revision: 7572
http://trac.macosforge.org/projects/calendarserver/changeset/7572
Author: glyph at apple.com
Date: 2011-06-07 17:01:27 -0700 (Tue, 07 Jun 2011)
Log Message:
-----------
when bundling, write out an environment file describing the bundle.
Modified Paths:
--------------
CalendarServer/branches/users/glyph/deploybuild/run
CalendarServer/branches/users/glyph/deploybuild/support/build.sh
Modified: CalendarServer/branches/users/glyph/deploybuild/run
===================================================================
--- CalendarServer/branches/users/glyph/deploybuild/run 2011-06-08 00:01:23 UTC (rev 7571)
+++ CalendarServer/branches/users/glyph/deploybuild/run 2011-06-08 00:01:27 UTC (rev 7572)
@@ -234,6 +234,10 @@
do_home_install;
fi;
+ if "${do_bundle}"; then
+ write_environment;
+ fi;
+
# Finally, run the server.
run;
}
Modified: CalendarServer/branches/users/glyph/deploybuild/support/build.sh
===================================================================
--- CalendarServer/branches/users/glyph/deploybuild/support/build.sh 2011-06-08 00:01:23 UTC (rev 7571)
+++ CalendarServer/branches/users/glyph/deploybuild/support/build.sh 2011-06-08 00:01:27 UTC (rev 7572)
@@ -566,7 +566,23 @@
fi;
}
+# Used only when bundling: write out, into the bundle, an 'environment.sh' file
+# that contains all the environment variables necessary to invoke commands in
+# the deployed bundle.
+write_environment () {
+ local dstroot="${install}";
+ cat > "${dstroot}/environment.sh" << __EOF__
+export PATH="${dstroot}/bin:\${PATH}";
+export C_INCLUDE_PATH="${dstroot}/include:\${C_INCLUDE_PATH:-}";
+export LD_LIBRARY_PATH="${dstroot}/lib:\${LD_LIBRARY_PATH:-}";
+export CPPFLAGS="-I${dstroot}/include \${CPPFLAGS:-} ";
+export LDFLAGS="-L${dstroot}/lib \${LDFLAGS:-} ";
+export DYLD_LIBRARY_PATH="${dstroot}/lib:\${DYLD_LIBRARY_PATH:-}";
+__EOF__
+}
+
+
#
# Enumerate all the dependencies with c_dependency and py_dependency;
# depending on options parsed by ../run:parse_options and on-disk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20110607/6061d71d/attachment.html>
More information about the calendarserver-changes
mailing list