[CalendarServer-changes] [14381] CalendarServer/trunk/bin/package

source_changes at macosforge.org source_changes at macosforge.org
Thu Feb 5 17:31:25 PST 2015


Revision: 14381
          http://trac.calendarserver.org//changeset/14381
Author:   wsanchez at apple.com
Date:     2015-02-05 17:31:25 -0800 (Thu, 05 Feb 2015)
Log Message:
-----------
More better

Modified Paths:
--------------
    CalendarServer/trunk/bin/package

Modified: CalendarServer/trunk/bin/package
===================================================================
--- CalendarServer/trunk/bin/package	2015-02-05 22:30:42 UTC (rev 14380)
+++ CalendarServer/trunk/bin/package	2015-02-06 01:31:25 UTC (rev 14381)
@@ -65,7 +65,7 @@
 
 
 parse_options () {
-  OPTIND=1;
+  local OPTIND=1;
   while getopts "hFfn" option; do
     case "${option}" in
       '?') usage; ;;
@@ -93,37 +93,35 @@
 
   parse_options "$@";
 
-  # Build the product
+  #
+  # Build everything
+  #
 
   if "${clean}"; then
     develop_clean;
   fi;
 
-  develop;
-
   install -d "${destination}";
+  local destination="$(cd "${destination}" && pwd)";
 
-  install -d "${destination}/virtualenv";
-  cp -pR "${py_virtualenv}/" "${destination}/virtualenv";
+  init_build;
 
-  # Make the python virtualenv relocatable
-  "${bootstrap_python}" -m virtualenv --relocatable "${destination}/virtualenv";
+      dev_roots="${destination}/roots";
+  py_virtualenv="${destination}/virtualenv";
+      py_bindir="${py_virtualenv}/bin";
 
-  cp -pR "${dev_roots}"/*/ "${destination}/virtualenv/";
+  c_dependencies;
+  py_dependencies;
 
   install -d "${destination}/bin";
-  install -m 555 "${wd}/support/_run_from_ve" "${destination}/bin";
-  ln -fsv _run_from_ve "${destination}/bin/caldavd";
 
-  for script in $(
-    python -c 'import setup; print "\n".join("calendarserver_{}".format(n) for n in setup.script_entry_points.keys())';
-  ); do
-    ln -fsv _run_from_ve "${destination}/bin/${script}";
-  done;
+  (
+    cd "${destination}/bin" && \
+      find ../virtualenv/bin \
+        '(' -name 'caldavd' -o -name 'calendarserver_*' -o -name 'python' ')' \
+        -exec ln -fs '{}' . ';';
+  );
 
-  # More here...
-  # Looks like we need to install calendarserver.
-  # Maybe should rebuild virtualenv insted of copying it.
 }
 
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20150205/41d6ca50/attachment-0001.html>


More information about the calendarserver-changes mailing list