Browse Source

[dev-libs/Ice] less python hackery, switch to ruby22 in release ebuild instead, more test fixes

master
Robert Förster 5 years ago
parent
commit
c25e034592
  1. 45
      dev-libs/Ice/Ice-3.6.3.ebuild
  2. 27
      dev-libs/Ice/Ice-3.6.9999.ebuild

45
dev-libs/Ice/Ice-3.6.3.ebuild

@ -7,7 +7,7 @@ EAPI=5
PYTHON_COMPAT=( python{2_7,3_4,3_5} pypy )
RUBY_OPTIONAL="yes"
USE_RUBY="ruby23"
USE_RUBY="ruby22"
PHP_EXT_NAME="IcePHP"
PHP_EXT_INI="yes"
@ -38,7 +38,7 @@ RDEPEND=">=dev-libs/expat-2.0.1
)
dev-cpp/libmcpp
python? ( ${PYTHON_DEPS} )
ruby? ( $(ruby_implementation_depend ruby23) )
ruby? ( $(ruby_implementation_depend ruby22) )
mono? ( dev-lang/mono )
php? ( dev-lang/php:7.0 )
php_namespaces? ( dev-lang/php:7.0 )
@ -54,7 +54,7 @@ DEPEND="${RDEPEND}
REQUIRED_USE="php_namespaces? ( php )"
# Maintainer notes:
# TODO: java bindings
# TODO: java bindings, multiple ruby versions (supports 2.{1,2,3})
S="${WORKDIR}/${P/I/i}"
PHP_EXT_S="${S}/php"
@ -103,11 +103,12 @@ src_prepare() {
-e '/SUBDIRS/s|\ test||' \
csharp/Makefile || die "sed failed"
# IceUtil/stacktrace fails with USE=debug
# skip udp test due to multicast
# skip IceSSL tests due to requirement of internet connection
# IceUtil/stacktrace fails
# IceStorm/stress fails without USE=debug
sed -i \
-e 's|allTests.py|allTests.py --rfilter=IceUtil\/stacktrace --rfilter=udp --rfilter=IceSSL|' \
-e 's|allTests.py|allTests.py --rfilter=udp --rfilter=IceSSL --rfilter=IceStorm\/stress|' \
cpp/Makefile || die "sed failed"
# mainly broken .ice files
@ -158,28 +159,25 @@ src_configure() {
if use python ; then
S=${S}/python python_copy_sources
# make a place for the build hackery
rm -r "${WORKDIR}/${P/I/i}"/python || die
fi
if use ruby ; then
SITERUBY="$(ruby23 -r rbconfig -e 'print RbConfig::CONFIG["sitelibdir"]')"
SITERUBY="$(ruby22 -r rbconfig -e 'print RbConfig::CONFIG["sitelibdir"]')"
MAKE_RULES_RB="install_rubydir=\"${ED}/${SITERUBY}\"
install_libdir=\"${ED}/${SITERUBY}\""
# make it use ruby23 only
# make it use ruby22 only
sed -i \
-e 's|RUBY = ruby|\023|' \
-e 's|RUBY = ruby|\022|' \
ruby/config/Make.rules || die "sed failed"
sed -i \
-e 's|env ruby|\023|' \
-e 's|env ruby|\022|' \
ruby/config/s2rb.rb || die "sed failed"
sed -i \
-e 's|env ruby|\023|' \
-e 's|env ruby|\022|' \
ruby/scripts/slice2rb || die "sed failed"
sed -i \
-e 's|output.write("ruby|\023|' \
-e 's|output.write("ruby|\022|' \
scripts/TestUtil.py || die "sed failed"
fi
@ -220,12 +218,9 @@ src_compile() {
if use python ; then
building() {
# build requires that the directory is named 'python'
mv "${BUILD_DIR}" "${S}"/python || die
emake -C python ${MAKE_RULES} PYTHON=${EPYTHON} || die "emake python-${EPYTHON} failed"
mv "${S}"/python "${BUILD_DIR}"
emake -C ${BUILD_DIR} ${MAKE_RULES} PYTHON=${EPYTHON} || die "emake python-${EPYTHON} failed"
}
BUILD_DIR=python python_foreach_impl building
S=${S}/python python_foreach_impl building
fi
if use ruby ; then
@ -245,14 +240,12 @@ src_test() {
if use python ; then
testing() {
mv "${BUILD_DIR}" "${S}"/python || die
emake -C python ${MAKE_RULES} PYTHON=${EPYTHON} \
emake -C ${BUILD_DIR} ${MAKE_RULES} PYTHON=${EPYTHON} \
install_pythondir="\"${D}/$(python_get_sitedir)\"" \
install_libdir="\"${D}/$(python_get_sitedir)\"" \
test || die "emake python-${EPYTHON} test failed"
mv "${S}"/python "${BUILD_DIR}"
}
BUILD_DIR=python python_foreach_impl testing
S=${S}/python python_foreach_impl testing
fi
if use ruby ; then
@ -306,14 +299,12 @@ src_install() {
installation() {
mkdir -p "${D}/$(python_get_sitedir)" || die
mv "${BUILD_DIR}" "${S}"/python || die
emake -C python ${MAKE_RULES} \
emake -C ${BUILD_DIR} ${MAKE_RULES} \
install_pythondir="\"${D}/$(python_get_sitedir)\"" \
install_libdir="\"${D}/$(python_get_sitedir)\"" \
install || die "emake python-${EPYTHON} install failed"
mv "${S}"/python "${BUILD_DIR}"
}
BUILD_DIR=python python_foreach_impl installation
S=${S}/python python_foreach_impl installation
fi
if use ruby ; then

27
dev-libs/Ice/Ice-3.6.9999.ebuild

@ -108,11 +108,12 @@ src_prepare() {
-e '/SUBDIRS/s|\ test||' \
csharp/Makefile || die "sed failed"
# IceUtil/stacktrace fails with USE=debug
# skip udp test due to multicast
# skip IceSSL tests due to requirement of internet connection
# IceUtil/stacktrace fails
# IceStorm/stress fails without USE=debug
sed -i \
-e 's|allTests.py|allTests.py --rfilter=IceUtil\/stacktrace --rfilter=udp --rfilter=IceSSL|' \
-e 's|allTests.py|allTests.py --rfilter=udp --rfilter=IceSSL --rfilter=IceStorm\/stress|' \
cpp/Makefile || die "sed failed"
# mainly broken .ice files
@ -163,9 +164,6 @@ src_configure() {
if use python ; then
S=${S}/python python_copy_sources
# make a place for the build hackery
rm -r "${WORKDIR}/${PN}"/python || die
fi
if use ruby ; then
@ -225,12 +223,9 @@ src_compile() {
if use python ; then
building() {
# build requires that the directory is named 'python'
mv "${BUILD_DIR}" "${S}"/python || die
emake -C python ${MAKE_RULES} PYTHON=${EPYTHON} || die "emake python-${EPYTHON} failed"
mv "${S}"/python "${BUILD_DIR}"
emake -C ${BUILD_DIR} ${MAKE_RULES} PYTHON=${EPYTHON} || die "emake python-${EPYTHON} failed"
}
BUILD_DIR=python python_foreach_impl building
S=${S}/python python_foreach_impl building
fi
if use ruby ; then
@ -250,14 +245,12 @@ src_test() {
if use python ; then
testing() {
mv "${BUILD_DIR}" "${S}"/python || die
emake -C python ${MAKE_RULES} PYTHON=${EPYTHON} \
emake -C ${BUILD_DIR} ${MAKE_RULES} PYTHON=${EPYTHON} \
install_pythondir="\"${D}/$(python_get_sitedir)\"" \
install_libdir="\"${D}/$(python_get_sitedir)\"" \
test || die "emake python-${EPYTHON} test failed"
mv "${S}"/python "${BUILD_DIR}"
}
BUILD_DIR=python python_foreach_impl testing
S=${S}/python python_foreach_impl testing
fi
if use ruby ; then
@ -307,14 +300,12 @@ src_install() {
installation() {
mkdir -p "${D}/$(python_get_sitedir)" || die
mv "${BUILD_DIR}" "${S}"/python || die
emake -C python ${MAKE_RULES} \
emake -C ${BUILD_DIR} ${MAKE_RULES} \
install_pythondir="\"${D}/$(python_get_sitedir)\"" \
install_libdir="\"${D}/$(python_get_sitedir)\"" \
install || die "emake python-${EPYTHON} install failed"
mv "${S}"/python "${BUILD_DIR}"
}
BUILD_DIR=python python_foreach_impl installation
S=${S}/python python_foreach_impl installation
fi
if use ruby ; then

Loading…
Cancel
Save