Print this page
Remove Python 2.6


  16 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  17 # If applicable, add the following below this CDDL HEADER, with the
  18 # fields enclosed by brackets "[]" replaced with your own identifying
  19 # information: Portions Copyright [yyyy] [name of copyright owner]
  20 #
  21 # CDDL HEADER END
  22 #
  23 #
  24 # Copyright 2016 OmniTI Computer Consulting, Inc.  All rights reserved.
  25 # Use is subject to license terms.
  26 #
  27 # Load support functions
  28 . ../../lib/functions.sh
  29 
  30 PROG=mercurial
  31 VER=3.9.2
  32 PKG=developer/versioning/mercurial
  33 SUMMARY="$PROG - a free and open source, distributed version control system"
  34 DESC="$SUMMARY"
  35 
  36 DEPENDS_IPS="runtime/python-26 \
  37              web/curl \
  38              library/security/openssl@1.0.2
  39              library/zlib"
  40 
  41 # For inet_ntop which isn't detected properly in the configure script
  42 CONFIGURE_OPTS=""
  43 
  44 PYTHONPATH=/usr
  45 PYTHON=$PYTHONPATH/bin/python2.6
  46 PYTHONLIB=$PYTHONPATH/lib
  47 
  48 python_build() {
  49     logmsg "Building using python setup.py"
  50     pushd $TMPDIR/$BUILDDIR > /dev/null
  51     ISALIST=i386
  52     export ISALIST
  53     logmsg "--- setup.py (32) build"
  54     logcmd $PYTHON ./setup.py build ||
  55         logerr "--- build failed"
  56     logmsg "--- setup.py (32) install"
  57     logcmd $PYTHON \
  58         ./setup.py install --root=$DESTDIR ||
  59         logerr "--- install failed"
  60 
  61     ISALIST="amd64 i386"
  62     export ISALIST
  63     logmsg "--- setup.py (64) build"
  64     logcmd $PYTHON ./setup.py build ||
  65         logerr "--- build failed"
  66     logmsg "--- setup.py (64) install"
  67     logcmd $PYTHON \
  68         ./setup.py install --root=$DESTDIR ||
  69         logerr "--- install failed"
  70     popd > /dev/null
  71 
  72     mv $DESTDIR/usr/lib/python2.6/site-packages $DESTDIR/usr/lib/python2.6/vendor-packages ||
  73         logerr "Cannot move from site-packages to vendor-packages"
  74 }
  75 
  76 init
  77 download_source $PROG $PROG $VER
  78 patch_source
  79 prep_build
  80 python_build
  81 make_package
  82 clean_up


  16 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  17 # If applicable, add the following below this CDDL HEADER, with the
  18 # fields enclosed by brackets "[]" replaced with your own identifying
  19 # information: Portions Copyright [yyyy] [name of copyright owner]
  20 #
  21 # CDDL HEADER END
  22 #
  23 #
  24 # Copyright 2016 OmniTI Computer Consulting, Inc.  All rights reserved.
  25 # Use is subject to license terms.
  26 #
  27 # Load support functions
  28 . ../../lib/functions.sh
  29 
  30 PROG=mercurial
  31 VER=3.9.2
  32 PKG=developer/versioning/mercurial
  33 SUMMARY="$PROG - a free and open source, distributed version control system"
  34 DESC="$SUMMARY"
  35 
  36 DEPENDS_IPS="runtime/python-27 \
  37              web/curl \
  38              library/security/openssl@1.0.2
  39              library/zlib"
  40 
  41 # For inet_ntop which isn't detected properly in the configure script
  42 CONFIGURE_OPTS=""
  43 
  44 PYTHONPATH=/usr
  45 PYTHON=$PYTHONPATH/bin/python2.7
  46 PYTHONLIB=$PYTHONPATH/lib
  47 
  48 python_build() {
  49     logmsg "Building using python setup.py"
  50     pushd $TMPDIR/$BUILDDIR > /dev/null
  51     ISALIST=i386
  52     export ISALIST
  53     logmsg "--- setup.py (32) build"
  54     logcmd $PYTHON ./setup.py build ||
  55         logerr "--- build failed"
  56     logmsg "--- setup.py (32) install"
  57     logcmd $PYTHON \
  58         ./setup.py install --root=$DESTDIR ||
  59         logerr "--- install failed"
  60 
  61     ISALIST="amd64 i386"
  62     export ISALIST
  63     logmsg "--- setup.py (64) build"
  64     logcmd $PYTHON ./setup.py build ||
  65         logerr "--- build failed"
  66     logmsg "--- setup.py (64) install"
  67     logcmd $PYTHON \
  68         ./setup.py install --root=$DESTDIR ||
  69         logerr "--- install failed"
  70     popd > /dev/null
  71 
  72     mv $DESTDIR/usr/lib/python2.7/site-packages $DESTDIR/usr/lib/python2.7/vendor-packages ||
  73         logerr "Cannot move from site-packages to vendor-packages"
  74 }
  75 
  76 init
  77 download_source $PROG $PROG $VER
  78 patch_source
  79 prep_build
  80 python_build
  81 make_package
  82 clean_up