diff options
6 files changed, 201 insertions, 0 deletions
diff --git a/dev-python/pythonmagick/Manifest b/dev-python/pythonmagick/Manifest new file mode 100644 index 0000000..8f0a35c --- /dev/null +++ b/dev-python/pythonmagick/Manifest @@ -0,0 +1,6 @@ +AUX pythonmagick-0.6-gentoo_misc_fixes.patch 745 RMD160 56e53df20162729f38bb30c3ec69982a5816e14b SHA1 cc0d60de95e38776ce5bc5a5ba7d98294f5116ba SHA256 15d60ffa62c39b5677b441fe6e918f2a0f215ed999b2cfdb57143fa7e27a9d68 +AUX pythonmagick_build.patch 346 RMD160 28825da77d9ad039b45c64edf31a8942157af3bc SHA1 beed8a966aad3dbb8255db9e12670e4145577203 SHA256 e946a85e6f89592058dfe88cb226295ffa645bbf790681dee9aa2bbd1ba1dce6 +DIST PythonMagick-0.7.tar.gz 361197 RMD160 540332a24829e4510e56220d61a66e4e1cad0370 SHA1 86c32774fbca30177cadd027fffcea4a174e1929 SHA256 e15354bdb3aeb371f483ec8f4b8536f5baca22d06fdd05b188517bd6be9fa394 +EBUILD pythonmagick-0.7.ebuild 993 RMD160 a922f9f7ab3bb82ffabd6915ec02e08ad840ec24 SHA1 5a526ff2ca544943193a2430cbfa3b3509f4fe64 SHA256 c4ff668cfb126cf3e90fd0eb0e474beef055a45554e1298d591cfb17b1759845 +MISC pythonmagick-0.7.ebuild.diff 1638 RMD160 3cc0552d02a7106aef362fc4467f7ec7f9e8e2ad SHA1 af730d82709a78226eaa44cb0574a88e5cf11f44 SHA256 13a19463e95310740322735274d07549c607db5136c9c14710a76132f08adfe2 +MISC pythonmagick-0.7.ebuild.old 1521 RMD160 667fbea62438cf7f87c6d9e03a2f242f63570c4e SHA1 1728f3dc83c52b069e55ebf34e9339f7e15fd9ce SHA256 2a50757de3e7ac34abe92755e601773502ac8912fb21eec6a01fa0228aa829ba diff --git a/dev-python/pythonmagick/files/pythonmagick-0.6-gentoo_misc_fixes.patch b/dev-python/pythonmagick/files/pythonmagick-0.6-gentoo_misc_fixes.patch new file mode 100644 index 0000000..9455110 --- /dev/null +++ b/dev-python/pythonmagick/files/pythonmagick-0.6-gentoo_misc_fixes.patch @@ -0,0 +1,23 @@ +--- SConstruct.orig 2006-10-18 00:57:28.000000000 +0200 ++++ SConstruct 2006-10-18 00:58:26.000000000 +0200 +@@ -20,16 +20,17 @@ + IM_LIB_PATH='/usr/lib/' + GD_LIBS=['Magick','Magick++','Wand'] + PYTHON_INCLUDE='/usr/include/python2.4' +- BOOST_PYTHON_LIB=['libboost_python-gcc'] +- CPP_FLAGS=['-DBOOST_PYTHON_STATIC_LIB','-O2'] ++ BOOST_PYTHON_LIB=['libboost_python'] ++ CPP_FLAGS=['-DBOOST_PYTHON_STATIC_LIB'] + + # setup the environment + env=Environment( + LIBPATH=['./',BOOSTLIBPATH, IM_LIB_PATH], + CPPPATH=[BOOST, PYTHON_INCLUDE] + IM_INCLUDE_PATH, +- RPATH=['./',BOOSTLIBPATH], ++ RPATH=[BOOSTLIBPATH], + CPPFLAGS=CPP_FLAGS + ) ++env.SConsignFile() + + def fix_includes(target,source,env): + for t in target: diff --git a/dev-python/pythonmagick/files/pythonmagick_build.patch b/dev-python/pythonmagick/files/pythonmagick_build.patch new file mode 100644 index 0000000..f06b92b --- /dev/null +++ b/dev-python/pythonmagick/files/pythonmagick_build.patch @@ -0,0 +1,10 @@ +--- SConstruct.old 2008-04-23 01:23:33.983934532 +0200 ++++ SConstruct 2008-04-23 01:24:04.783235908 +0200 +@@ -31,6 +31,7 @@ + CPPFLAGS='-march=prescott -O2 -pipe -fomit-frame-pointer'.split()+CPP_FLAGS + ) + env.SConsignFile() ++env.ParseConfig('pkg-config --cflags --libs Magick++') + + def fix_includes(target,source,env): + for t in target: diff --git a/dev-python/pythonmagick/pythonmagick-0.7.ebuild b/dev-python/pythonmagick/pythonmagick-0.7.ebuild new file mode 100644 index 0000000..fc7f3e2 --- /dev/null +++ b/dev-python/pythonmagick/pythonmagick-0.7.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-python/pythonmagick/pythonmagick-0.7.ebuild,v 1.1 2007/11/20 01:03:38 hawking Exp $ + +NEED_PYTHON="2.5" + +inherit python multilib flag-o-matic + +MY_PN=PythonMagick +MY_P=${MY_PN}-${PV} + +DESCRIPTION="Python bindings for ImageMagick" +HOMEPAGE="http://www.imagemagick.org/script/api.php" +SRC_URI="http://www.imagemagick.org/download/python/${MY_P}.tar.gz" + +SLOT="0" +LICENSE="as-is" +KEYWORDS="~x86" +IUSE="" + +DEPEND=">=media-gfx/imagemagick-6.2 + >=dev-libs/boost-1.34.0" + +S=${WORKDIR}/${MY_P} + +src_compile () { + filter-ldflags -Wl,--as-needed --as-needed + + econf || die "econf failed" + emake || die "emake failed" +} + +src_install() { + emake DESTDIR="${D}" install || die "emake install failed" +} + +pkg_postinst() { + python_version + python_mod_optimize "${ROOT}"usr/$(get_libdir)/python${PYVER}/site-packages/${MY_PN} +} + +pkg_postrm() { + python_mod_cleanup +} diff --git a/dev-python/pythonmagick/pythonmagick-0.7.ebuild.diff b/dev-python/pythonmagick/pythonmagick-0.7.ebuild.diff new file mode 100644 index 0000000..c306f68 --- /dev/null +++ b/dev-python/pythonmagick/pythonmagick-0.7.ebuild.diff @@ -0,0 +1,58 @@ +--- pythonmagick-0.7.ebuild.old 2008-04-23 03:51:10.000000000 +0200 ++++ pythonmagick-0.7.ebuild 2008-04-23 03:25:02.000000000 +0200 +@@ -2,7 +2,9 @@ + # Distributed under the terms of the GNU General Public License v2 + # $Header: /var/cvsroot/gentoo-x86/dev-python/pythonmagick/pythonmagick-0.7.ebuild,v 1.1 2007/11/20 01:03:38 hawking Exp $ + +-inherit eutils python multilib toolchain-funcs ++NEED_PYTHON="2.5" ++ ++inherit python multilib flag-o-matic + + MY_PN=PythonMagick + MY_P=${MY_PN}-${PV} +@@ -16,38 +18,20 @@ + KEYWORDS="~x86" + IUSE="" + +-RDEPEND=">=media-gfx/imagemagick-1.1.7 ++DEPEND=">=media-gfx/imagemagick-6.2 + >=dev-libs/boost-1.34.0" +-DEPEND="${RDEPEND} +- dev-util/scons" + + S=${WORKDIR}/${MY_P} + +-src_unpack() { +- unpack ${A} +- cd "${S}" +- epatch "${FILESDIR}/${PN}-0.6-gentoo_misc_fixes.patch" +-} +- +-src_compile() { +- python_version +- sed -i \ +- -e "s#\(BOOST\)=.*#\1='/usr/include/boost'#" \ +- -e "s#\(BOOSTLIBPATH\)=.*#\1='/usr/lib'#" \ +- -e "s#\(PYTHON_INCLUDE\)=.*#\1='/usr/include/python${PYVER}'#" \ +- -e "s#\(Environment(\)#\1 CXX='$(tc-getCXX)',#" \ +- -e "s#\(CPPFLAGS\)=#\1='${CXXFLAGS}'.split()+#" \ +- SConstruct || die "sed failed" +- +- # FIXME: Until we have a var or function for it +- numjobs=$(sed -e 's/.*\(\-j[ 0-9]\+\) .*/\1/' <<< ${MAKEOPTS}) ++src_compile () { ++ filter-ldflags -Wl,--as-needed --as-needed + +- scons mode=release ${numjobs} || die "scons failed" ++ econf || die "econf failed" ++ emake || die "emake failed" + } + + src_install() { +- insinto /usr/lib/python${PYVER}/site-packages +- doins -r PythonMagick ++ emake DESTDIR="${D}" install || die "emake install failed" + } + + pkg_postinst() { diff --git a/dev-python/pythonmagick/pythonmagick-0.7.ebuild.old b/dev-python/pythonmagick/pythonmagick-0.7.ebuild.old new file mode 100644 index 0000000..77042e3 --- /dev/null +++ b/dev-python/pythonmagick/pythonmagick-0.7.ebuild.old @@ -0,0 +1,60 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-python/pythonmagick/pythonmagick-0.7.ebuild,v 1.1 2007/11/20 01:03:38 hawking Exp $ + +inherit eutils python multilib toolchain-funcs + +MY_PN=PythonMagick +MY_P=${MY_PN}-${PV} + +DESCRIPTION="Python bindings for ImageMagick" +HOMEPAGE="http://www.imagemagick.org/script/api.php" +SRC_URI="http://www.imagemagick.org/download/python/${MY_P}.tar.gz" + +SLOT="0" +LICENSE="as-is" +KEYWORDS="~x86" +IUSE="" + +RDEPEND=">=media-gfx/imagemagick-1.1.7 + >=dev-libs/boost-1.34.0" +DEPEND="${RDEPEND} + dev-util/scons" + +S=${WORKDIR}/${MY_P} + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}/${PN}-0.6-gentoo_misc_fixes.patch" +} + +src_compile() { + python_version + sed -i \ + -e "s#\(BOOST\)=.*#\1='/usr/include/boost'#" \ + -e "s#\(BOOSTLIBPATH\)=.*#\1='/usr/lib'#" \ + -e "s#\(PYTHON_INCLUDE\)=.*#\1='/usr/include/python${PYVER}'#" \ + -e "s#\(Environment(\)#\1 CXX='$(tc-getCXX)',#" \ + -e "s#\(CPPFLAGS\)=#\1='${CXXFLAGS}'.split()+#" \ + SConstruct || die "sed failed" + + # FIXME: Until we have a var or function for it + numjobs=$(sed -e 's/.*\(\-j[ 0-9]\+\) .*/\1/' <<< ${MAKEOPTS}) + + scons mode=release ${numjobs} || die "scons failed" +} + +src_install() { + insinto /usr/lib/python${PYVER}/site-packages + doins -r PythonMagick +} + +pkg_postinst() { + python_version + python_mod_optimize "${ROOT}"usr/$(get_libdir)/python${PYVER}/site-packages/${MY_PN} +} + +pkg_postrm() { + python_mod_cleanup +} |