Skip to content
Permalink
Browse files

htcondor: update to 8.7.7, add Python 3.5 and 3.6 subports

  • Loading branch information
lpsinger committed Apr 9, 2018
1 parent a379221 commit 6883f8674bafaadcbd8e0fa1dffaa385652da16d
@@ -5,9 +5,8 @@ PortGroup github 1.0
PortGroup cmake 1.0
PortGroup active_variants 1.1

github.setup htcondor htcondor 8_6_8 V
github.setup htcondor htcondor 8_7_7 V
version [strsed ${github.version} g/_/\./]
revision 1
maintainers {aronnax @lpsinger}

categories science parallel net
@@ -38,9 +37,9 @@ variant personal \
startupitem.stop "${prefix}/sbin/condor_off -all -master"
}

set pythons_suffixes {27 34}
set pythons_suffixes {27 34 35 36}

if {![variant_isset python34]} {
if {!([variant_isset python34] || [variant_isset python35] || [variant_isset python36])} {
default_variants +python27
}

@@ -58,16 +57,21 @@ foreach s ${pythons_suffixes} {
set i [lsearch -exact ${pythons_ports} ${p}]
set c [lreplace ${pythons_ports} ${i} ${i}]
set f ${frameworks_dir}/Python.framework/Versions/${v}
if {${s} == 27} {
set m ""
} else {
set m 3
}
variant ${p} description "Enable Python interface for Python ${v}" conflicts {*}${c} "
depends_lib-append port:${p}
require_active_variants boost ${p}
configure.args-append -DPython_ADDITIONAL_VERSIONS:STRING=\"${v}\" -DPYTHON_EXECUTABLE:FILEPATH=\"${f}/bin/python${v}\" -DC_PYTHONARCHLIB:PATH=\"${f}/lib/python${v}/site-packages\"
configure.args-append -DPython_ADDITIONAL_VERSIONS:STRING=\"${v}\" -DPYTHON_EXECUTABLE:FILEPATH=\"${f}/bin/python${v}\" -DBoost_PYTHON_LIBRARY:FILEPATH=\"${prefix}/lib/libboost_python${m}-mt.dylib\"
configure.args-replace -DWITH_PYTHON_BINDINGS:BOOL=\"0\" -DWITH_PYTHON_BINDINGS:BOOL=\"1\"
post-patch {
reinplace \"s|@prefix@|${prefix}|g\" ${worksrcpath}/src/condor_utils/condor_config.cpp
reinplace \"s|@python@|${f}/bin/python${v}|g\" ${worksrcpath}/build/cmake/CondorPackageConfig.cmake
reinplace \"s|@c_pythonarchlib@|Library/Frameworks/Python.framework/Versions/${v}/lib/python${v}/site-packages|g\" ${worksrcpath}/build/cmake/CondorPackageConfig.cmake
}
"
}
@@ -78,8 +82,8 @@ variant kerberos description {enable Kerberos5 support} {
}


checksums rmd160 84293176b8a3ffa9a09e1543295e1b1089126a3a \
sha256 3b8234ace974952a13c5f133c86fd6eb454924564ceb8665123bb7b5357cc820
checksums rmd160 8b29509fb553454f5d67f67cb59db1d80d50f43c \
sha256 65cb1b12f8cb972a3d245f6cea7ec0509cd86d07368dc3dc0dcd7679238cb3b4

depends_build-append port:fig2dev \
port:latex2html
@@ -91,7 +95,8 @@ depends_lib-append port:boost \

license_noconflict latex2html

patchfiles patch-src-classad-CMakeLists.txt.diff \
patchfiles patch-build-cmake-CondorPackageConfig.cmake.diff \
patch-src-classad-CMakeLists.txt.diff \
patch-src-condor_scripts-macosx_rewrite_libs.diff \
patch-src-condor_utils-CMakeLists.txt.diff \
patch-src-condor_utils-condor_config.cpp.diff \
@@ -0,0 +1,11 @@
--- build/cmake/CondorPackageConfig.cmake.orig 2018-04-08 15:08:04.000000000 -0400
+++ build/cmake/CondorPackageConfig.cmake 2018-04-08 15:08:19.000000000 -0400
@@ -125,7 +125,7 @@
set( C_LIBEXEC libexec )
set( C_SBIN sbin)

-set( C_PYTHONARCHLIB lib/python)
+set( C_PYTHONARCHLIB @c_pythonarchlib@)

set( C_INCLUDE include)
set( C_INCLUDE_PUBLIC include)
@@ -1,6 +1,6 @@
--- src/condor_scripts/macosx_rewrite_libs
+++ src/condor_scripts/macosx_rewrite_libs
@@ -9,36 +9,17 @@ if [ "$1" = "" ] ; then
--- src/condor_scripts/macosx_rewrite_libs.orig 2018-04-08 14:38:23.000000000 -0400
+++ src/condor_scripts/macosx_rewrite_libs 2018-04-08 14:39:35.000000000 -0400
@@ -9,35 +9,16 @@
echo "Usage:" `basename $0` "<executable/library> ..."
exit 1
fi
@@ -26,10 +26,10 @@
- external_resolver="@loader_path/../condor"
- internal_resolver="@loader_path/.."
- fi
-
+ libraries=`otool -L $filename | grep '^[[:space:]][^@]' | sed 's|^.\([^ ]*\) .*|\1|' | grep -v '^/usr/lib' | grep -v '^/System/' | grep -v '^@prefix@/Library/' | grep -v "$basefile "`
+
for lib in $libraries ; do
echo $lib
baselib=`basename $lib`
- if echo $baselib | grep -q -e 'classad' -e 'condor' ; then
- install_name_tool -change "$lib" "$internal_resolver/$baselib" $filename
@@ -1,9 +1,9 @@
--- src/python-bindings/CMakeLists.txt
+++ src/python-bindings/CMakeLists.txt
@@ -109,9 +109,9 @@ else()
--- src/python-bindings/CMakeLists.txt.orig 2018-04-08 14:41:22.000000000 -0400
+++ src/python-bindings/CMakeLists.txt 2018-04-08 14:43:09.000000000 -0400
@@ -130,9 +130,9 @@
set ( CMAKE_LIBRARY_PATH CMAKE_LIBRARY_PATH_ORIG)

if (PROPER AND "${PYTHON_VERSION_MAJOR}" MATCHES "3")
if ("${PYTHON_VERSION_MAJOR}" MATCHES "3")
- set ( PYTHON_BOOST_LIB boost_python3 )
+ set ( PYTHON_BOOST_LIB boost_python3-mt )
else()
@@ -12,7 +12,7 @@
endif()

include_directories(${PYTHON_INCLUDE_DIRS} ${BOOST_INCLUDE})
@@ -174,6 +174,7 @@ else()
@@ -195,6 +195,7 @@
if ( DARWIN )
set_target_properties( pyclassad PROPERTIES INSTALL_NAME_DIR ${CMAKE_CURRENT_BINARY_DIR} )
install( CODE "execute_process(COMMAND ${CMAKE_SOURCE_DIR}/src/condor_scripts/macosx_rewrite_libs \$ENV{DESTDIR}/${CMAKE_INSTALL_PREFIX}/${C_LIB}/lib${PYCLASSAD_LIB_NAME}.dylib)" )

0 comments on commit 6883f86

Please sign in to comment.
You can’t perform that action at this time.