[CalendarServer-changes] [7569] CalendarServer/branches/users/glyph/deploybuild/support/build.sh

source_changes at macosforge.org source_changes at macosforge.org
Tue Jun 7 17:01:16 PDT 2011


Revision: 7569
          http://trac.macosforge.org/projects/calendarserver/changeset/7569
Author:   glyph at apple.com
Date:     2011-06-07 17:01:16 -0700 (Tue, 07 Jun 2011)
Log Message:
-----------
Bootstrap the directory structure first; also, different compilation options practically means a different src dir, unless you want to clean everything out manually.

Modified Paths:
--------------
    CalendarServer/branches/users/glyph/deploybuild/support/build.sh

Modified: CalendarServer/branches/users/glyph/deploybuild/support/build.sh
===================================================================
--- CalendarServer/branches/users/glyph/deploybuild/support/build.sh	2011-06-08 00:01:13 UTC (rev 7568)
+++ CalendarServer/branches/users/glyph/deploybuild/support/build.sh	2011-06-08 00:01:16 UTC (rev 7569)
@@ -399,7 +399,13 @@
     echo "";
     echo "Installing ${name}...";
     cd "${path}";
-    "${python}" ./setup.py install "${install_flag}${install}";
+    if "${do_bundle}"; then
+      # Since we've built our own Python, an option-free installation is the
+      # best bet.
+      "${python}" ./setup.py install;
+    else
+      "${python}" ./setup.py install "${install_flag}${install}";
+    fi;
     cd /;
   fi;
 }
@@ -532,16 +538,17 @@
 
   # Extra arguments are processed below, as arguments to './configure'.
 
-  srcdir="${top}/${path}";
-
-  www_get ${f_hash} "${name}" "${srcdir}" "${uri}";
-
   if "${do_bundle}"; then
     local dstroot="${install}";
+    srcdir="${install}/src/${path}";
   else
     local dstroot="${srcdir}/_root";
+    srcdir="${top}/${path}";
   fi;
 
+  www_get ${f_hash} "${name}" "${srcdir}" "${uri}";
+
+
   export              PATH="${dstroot}/bin:${PATH}";
   export    C_INCLUDE_PATH="${dstroot}/include:${C_INCLUDE_PATH:-}";
   export   LD_LIBRARY_PATH="${dstroot}/lib:${LD_LIBRARY_PATH:-}";
@@ -550,7 +557,7 @@
   export DYLD_LIBRARY_PATH="${dstroot}/lib:${DYLD_LIBRARY_PATH:-}";
 
   if "${do_setup}" && (
-      "${force_setup}" || [ ! -d "${dstroot}" ]); then
+      "${force_setup}" || "${do_bundle}" || [ ! -d "${dstroot}" ]); then
     echo "Building ${name}...";
     cd "${srcdir}";
     ./configure --prefix="${dstroot}" "$@";
@@ -573,10 +580,15 @@
   # Dependencies compiled from C source code
   #
 
-  # Normally we depend on the system Python, but a bundle install should be as
-  # self-contained as possible.
 
   if "${do_bundle}"; then
+    # First a bit of bootstrapping: fill out the standard directory structure.
+    for topdir in bin lib include share src; do
+      mkdir -p "${install}/${topdir}";
+    done;
+
+    # Normally we depend on the system Python, but a bundle install should be as
+    # self-contained as possible.
     local pyfn="Python-2.7.1";
     c_dependency -m "aa27bc25725137ba155910bd8e5ddc4f" \
         "Python" "${pyfn}" \
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20110607/df4a37ca/attachment.html>


More information about the calendarserver-changes mailing list