diff options
Diffstat (limited to 'sci-chemistry/raster3d')
-rw-r--r-- | sci-chemistry/raster3d/Manifest | 9 | ||||
-rw-r--r-- | sci-chemistry/raster3d/files/3.0.2-as-needed.patch | 50 | ||||
-rw-r--r-- | sci-chemistry/raster3d/files/3.0.2-gentoo-prefix.patch | 24 | ||||
-rw-r--r-- | sci-chemistry/raster3d/metadata.xml | 14 | ||||
-rw-r--r-- | sci-chemistry/raster3d/raster3d-3.0.2.ebuild | 106 | ||||
-rw-r--r-- | sci-chemistry/raster3d/raster3d-3.0.3.ebuild | 106 |
6 files changed, 309 insertions, 0 deletions
diff --git a/sci-chemistry/raster3d/Manifest b/sci-chemistry/raster3d/Manifest new file mode 100644 index 000000000000..e3a841c1f33f --- /dev/null +++ b/sci-chemistry/raster3d/Manifest @@ -0,0 +1,9 @@ +AUX 3.0.2-as-needed.patch 1579 SHA256 9348541ca30f28466690e53e3fc94efdcbb4f9dec4cb25d5e959ea1c2c4722f4 SHA512 2898b55dca4e8d8d353922c36f44a9bb1dece19fa4c1de3f13ea5a09202004c10fbab6c2df2a39b71a65de3f30c19cd2724703b22b7ef978f366c69894761ce9 WHIRLPOOL e0205f149fd224e0164b51ea81b0c25700bbf915e77cca20510a76035c32a48301f4ac2552983b8608bff407b9997c77994ecf628a1df178329fa13ba73f0c69 +AUX 3.0.2-gentoo-prefix.patch 738 SHA256 4d7f94ad57280254177cfecec0f0a6f5610f1d3b4c7c4b7439ab68262e285515 SHA512 5cb22fdff116c6a84a9f570af99062c08463d391cb0460d06e64990eaab2c945e86f0b3f5a378144c49014c0c41dc70cafb102c5feba500c43c8555ce41612a0 WHIRLPOOL 32c239f5704ad67e87ca24313e15d70d1b5a395637f64191deb597787596ae47172373c78b5310ce1bb08aad5384c466a713f0738676e50deb1f0140a1165613 +DIST Raster3D_3.0-2.tar 1743034 SHA256 a89bdfda61fae8d189820941f1b5685b40743b817128f57bc1225f983a47d984 SHA512 f8f73cc91eae521839a9db8ee1a7a9d8727ed510cb574116d89e918480700d844691a6fc3c4a28cb54312b0133cc610422e55d99716803cf3e8bb5d9d934e37f WHIRLPOOL 58fc31cc438538715b1f0ea17a28b44294d78db32e40fa16f8ab5a5781e26198227c534f06b8d25072e6c6101a4c9255fa906b9fee57b128d0e767bc0e04db83 +DIST Raster3D_3.0-3.tar 1729356 SHA256 1e7d02cf17f2d14855b8d241269948b37ed4d3ae6395914b66ff9f95c3a7fecf SHA512 bd372c4ba8d40db38e19f520883ca71ab7c5ef7a451b67150894e229b45167dfe00b77c19e118afc6abdb9ac07800cc16de5d2dc82c3ef9baa751200490e40fa WHIRLPOOL ad7c11cfd42543845420dcffbc87024c60b3058a51663076ace63b2e2fc0fec81a342f7b4e54f535e03de14fb9e76eace65259cdd2e83a6e0e83810ac8280c10 +EBUILD raster3d-3.0.2.ebuild 2465 SHA256 660b7fcd0ffec71b3ae85a89624e67a8894df802149ac9864baa7c229ca861b8 SHA512 4e8a30469d18f14da0b8258622adaa17c8ac6ff06229dfa59efdf1ec4ba5386c23a594317d059a53d21160d229c17b2fb0db8b8cfc02c36d257230ec641ba9db WHIRLPOOL 0c4af280676e8f020a78313373fb8b7a9ec0ce10d22167c8e20dcd9384fbce4c692dc8e0a4d09b2db1ade579ee9e4e1486bb4c8eea4122e71b1c0235ec711773 +EBUILD raster3d-3.0.3.ebuild 2468 SHA256 bfee09542d343481da0f70a09281408af0fd1cc59eed0b8a16755640cf9180e7 SHA512 3cb278b220520dec632ed9c15c33df8774e4c99b327cd0e895307f9b61c427a8da31d321e27df04985b780957470b739d5202d4d8544c8864ebaeaa50dd0df38 WHIRLPOOL 10167f2c5dcaeebfe38c346b7a9ff5deb2f3233490e0e747384b4cba47214533bac0270879adb4e2b25d19abaaa80b14f5efa97092ccff6d21ed8b416853a70b +MISC ChangeLog 2625 SHA256 c63500406a45299d211690fedfb6a20193d6b195d72dde2d361d7067f93a1c3f SHA512 f87516d6a6fad91d6af0eab2b10c603a349298a45f1a7f96981fbe35e8674a58bc2733a06f98bfdd7518c8ccb85339fcbc7ff1e0224824137b7615bbb5af0439 WHIRLPOOL 870b5dc25e5911a568d9566421d7e8985808aaaac323bc90525c0e38798e3f13b6f054c234b78cc07ea985d55a0edd8386cae5651f543ff6280cc2c3582e9266 +MISC ChangeLog-2015 5814 SHA256 5b0aeacb31004d6b68ec8011ee2c27fd2253b24f6fd84930fbeeb795f6ce873b SHA512 6ab7c5d962850530fe8dda285150811a186b79993fcf400fd34fb2fb7fc9f0ff5c3d72ed99825f1b38fdf4ac2de627c8ff9672eee43ef6374277e7bc94c1926b WHIRLPOOL 7b92093a1660ba87306253e5c2bf499a5bc71e80b86376491ecb6252e6faf417a2e758d626c9427dd118bd878775ad02ed2f21f59f14d7704cb5f8c5e205ffd7 +MISC metadata.xml 459 SHA256 93bb5dee2c50eafdebc0d48e755eaedaeb86ca16d72e757fa1b79f9fecc4e66c SHA512 fe5bb2f873ea63f4c7185601842757cb0f791cecd8651fb4e15ea4992898ae60508e4a4c7bc161bddcfa3cf4125577da029b04cf06c900d6269af3f5b63bd916 WHIRLPOOL ae59b378f1fd7399922b683977d8669c1660ad6fed887c5088b69f3dc75863a6d6ab587d76d6187622b95e05dbdf38451f6ef1871df252496676b19c4c0bc4b9 diff --git a/sci-chemistry/raster3d/files/3.0.2-as-needed.patch b/sci-chemistry/raster3d/files/3.0.2-as-needed.patch new file mode 100644 index 000000000000..9e0961952535 --- /dev/null +++ b/sci-chemistry/raster3d/files/3.0.2-as-needed.patch @@ -0,0 +1,50 @@ +diff --git a/Makefile b/Makefile +index 1a1c549..4d74dd0 100644 +--- a/Makefile ++++ b/Makefile +@@ -58,7 +58,7 @@ linux: + @echo OSDEFS = -DLINUX -DNETWORKBYTEORDER >> Makefile.incl + @echo include Makefile.package >> Makefile.incl + @echo >> Makefile.incl +- @echo qinp.o: qinp.f >> Makefile.incl ++ @echo qinp.o: qinp.f normal3d.o render.o >> Makefile.incl + @echo " \$$(FC) -g -O0 -Wall -Wtabs -c -o qinp.o qinp.f" >> Makefile.incl + @echo >> Makefile.incl + +@@ -214,20 +214,20 @@ ribbon: ribbon.f ribbon1.f modsubs.f + ribbon.f ribbon1.f modsubs.f -o ribbon + + rastep: rastep.f quadric.o suv.o +- $(FC) $(FFLAGS) \ +- rastep.f quadric.o suv.o $(LDFLAGS) \ ++ $(FC) $(FFLAGS) $(LDFLAGS) \ ++ rastep.f quadric.o suv.o \ + -o rastep + + render: render.o local.o quadric.o parse.o r3dtogd.o ungz.o qinp.o +- $(FC) $(FFLAGS) \ ++ $(FC) $(FFLAGS) $(LDFLAGS) \ + render.o local.o quadric.o parse.o r3dtogd.o ungz.o \ + qinp.o \ +- $(LIBS) $(LDFLAGS) \ +- -o render ++ -o render \ ++ $(LIBS) + + normal3d: normal3d.o quadric.o qinp.o ungz.o parameters.incl +- $(FC) $(FFLAGS) \ +- normal3d.o quadric.o ungz.o qinp.o $(LDFLAGS) \ ++ $(FC) $(FFLAGS) $(LDFLAGS) \ ++ normal3d.o quadric.o ungz.o qinp.o \ + -o normal3d + + stereo3d: +@@ -264,7 +264,7 @@ example1.png: render_small + ./render_small + + render_small: render_small.o local.o quadric.o parse_small.o r3dtogd.o ungz.o qinp_small.o +- $(FC) $(FFLAGS) $^ $(LIBS) $(LDFLAGS) -o $@ ++ $(FC) $(FFLAGS) $(LDFLAGS) -o $@ $^ $(LIBS) + + .SUFFIXES: .incl + SMALL=10 diff --git a/sci-chemistry/raster3d/files/3.0.2-gentoo-prefix.patch b/sci-chemistry/raster3d/files/3.0.2-gentoo-prefix.patch new file mode 100644 index 000000000000..19b6cac3a6fe --- /dev/null +++ b/sci-chemistry/raster3d/files/3.0.2-gentoo-prefix.patch @@ -0,0 +1,24 @@ +diff --git a/Makefile.template b/Makefile.template +index 59de553..0ed283d 100644 +--- a/Makefile.template ++++ b/Makefile.template +@@ -8,15 +8,15 @@ include VERSION + # + # Where to install the program, data files, and manuals + # +-prefix = /usr/local ++prefix = @GENTOO_PORTAGE_EPREFIX@/usr/ + bindir = $(prefix)/bin + datadir = $(prefix)/share/Raster3D/materials + mandir = $(prefix)/man/manl +-htmldir = $(prefix)/share/Raster3D/html ++htmldir = $(prefix)/share/doc/MYPF/html + examdir = $(prefix)/share/Raster3D/examples + +-INCDIRS = -I/usr/include -I/usr/local/include +-LIBDIRS = -L/usr/local/lib ++INCDIRS = -I@GENTOO_PORTAGE_EPREFIX@/usr/include ++LIBDIRS = -L@GENTOO_PORTAGE_EPREFIX@/usr/MYLIB + + # + # TIFF support (enabled by default) diff --git a/sci-chemistry/raster3d/metadata.xml b/sci-chemistry/raster3d/metadata.xml new file mode 100644 index 000000000000..59d8b8360b0f --- /dev/null +++ b/sci-chemistry/raster3d/metadata.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>sci-chemistry@gentoo.org</email> + <name>Gentoo Chemistry Project</name> + </maintainer> + <upstream> + <changelog>http://skuld.bmsc.washington.edu/raster3d/CHANGELOG</changelog> + </upstream> + <use> + <flag name="gd">libgd support for PNG and JPEG output</flag> + </use> +</pkgmetadata> diff --git a/sci-chemistry/raster3d/raster3d-3.0.2.ebuild b/sci-chemistry/raster3d/raster3d-3.0.2.ebuild new file mode 100644 index 000000000000..a83e43ba57cf --- /dev/null +++ b/sci-chemistry/raster3d/raster3d-3.0.2.ebuild @@ -0,0 +1,106 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +inherit eutils fortran-2 flag-o-matic multilib toolchain-funcs versionator prefix + +MY_PN="Raster3D" +MY_PV=$(replace_version_separator 2 -) +MY_P="${MY_PN}_${MY_PV}" + +DESCRIPTION="Generation high quality raster images of proteins or other molecules" +HOMEPAGE="http://www.bmsc.washington.edu/raster3d/raster3d.html" +SRC_URI="http://www.bmsc.washington.edu/${PN}/${MY_P}.tar.gz -> ${MY_P}.tar" + +LICENSE="Artistic-2" +SLOT="0" +KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux" +IUSE="gd tiff" + +RDEPEND=" + tiff? ( media-libs/tiff:0 ) + gd? ( media-libs/gd[jpeg,png] )" +DEPEND="${RDEPEND}" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + epatch \ + "${FILESDIR}"/${PV}-as-needed.patch \ + "${FILESDIR}"/${PV}-gentoo-prefix.patch + + sed \ + -e "s:MYPF:${PF}:" \ + -e "s:MYLIB:$(get_libdir):g" \ + -i Makefile.template || \ + die "Failed to patch makefile.template" + + if ! use gd; then + sed \ + -e "/GDLIBS/s:^:#:g" \ + -e "/GDDEFS/s:^:#:g" \ + -i Makefile.template || die + fi + + if ! use tiff; then + sed \ + -e "/TLIBS/s:^:#:g" \ + -e "/TDEFS/s:^:#:g" \ + -i Makefile.template || die + fi + + if [[ $(tc-getFC) =~ gfortran ]]; then + append-cflags -Dgfortran + fi + + append-fflags -ffixed-line-length-132 + + eprefixify Makefile.template + cp Makefile.template Makefile.incl || die +} + +src_compile() { + local target + local i + + if [[ $(tc-getFC) =~ gfortran ]]; then + target="linux" + else + target="linux-$(tc-getFC)" + fi + + for i in render.o ${target} all; do + emake \ + CFLAGS="${CFLAGS}" \ + LDFLAGS="${LDFLAGS}" \ + FFLAGS="${FFLAGS}" \ + CC="$(tc-getCC)"\ + FC="$(tc-getFC)" \ + INCDIRS="-I${EPREFIX}/usr/include" \ + LIBDIRS="-L${EPREFIX}/usr/$(get_libdir)" \ + ${i} + done +} + +src_install() { + emake prefix="${ED}"/usr \ + bindir="${ED}"/usr/bin \ + datadir="${ED}"/usr/share/Raster3D/materials \ + mandir="${ED}"/usr/share/man/man1 \ + htmldir="${ED}"/usr/share/doc/${PF}/html \ + examdir="${ED}"/usr/share/Raster3D/examples \ + install + + dodir /etc/env.d + echo -e "R3D_LIB=${EPREFIX}/usr/share/${NAME}/materials" > \ + "${ED}"/etc/env.d/10raster3d || \ + die "Failed to install env file." +} + +pkg_postinst() { + elog "Add following line:" + elog "<delegate decode=\"r3d\" command='\"render\" < \"%i\" > \"%o\"' />" + elog "to ${EPREFIX}/usr/$(get_libdir)/ImageMagick-6.5.8/config/delegates.xml" + elog "to make imagemagick use raster3d for .r3d files" +} diff --git a/sci-chemistry/raster3d/raster3d-3.0.3.ebuild b/sci-chemistry/raster3d/raster3d-3.0.3.ebuild new file mode 100644 index 000000000000..309e0dfc1ba5 --- /dev/null +++ b/sci-chemistry/raster3d/raster3d-3.0.3.ebuild @@ -0,0 +1,106 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils fortran-2 flag-o-matic multilib toolchain-funcs versionator prefix + +MY_PN="Raster3D" +MY_PV=$(replace_version_separator 2 -) +MY_P="${MY_PN}_${MY_PV}" + +DESCRIPTION="Generation high quality raster images of proteins or other molecules" +HOMEPAGE="http://www.bmsc.washington.edu/raster3d/raster3d.html" +SRC_URI="http://www.bmsc.washington.edu/${PN}/${MY_P}.tar.gz -> ${MY_P}.tar" + +LICENSE="Artistic-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux" +IUSE="gd tiff" + +RDEPEND=" + tiff? ( media-libs/tiff:0 ) + gd? ( media-libs/gd[jpeg,png] )" +DEPEND="${RDEPEND}" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + epatch \ + "${FILESDIR}"/3.0.2-as-needed.patch \ + "${FILESDIR}"/3.0.2-gentoo-prefix.patch + + sed \ + -e "s:MYPF:${PF}:" \ + -e "s:MYLIB:$(get_libdir):g" \ + -i Makefile.template || \ + die "Failed to patch makefile.template" + + if ! use gd; then + sed \ + -e "/GDLIBS/s:^:#:g" \ + -e "/GDDEFS/s:^:#:g" \ + -i Makefile.template || die + fi + + if ! use tiff; then + sed \ + -e "/TLIBS/s:^:#:g" \ + -e "/TDEFS/s:^:#:g" \ + -i Makefile.template || die + fi + + if [[ $(tc-getFC) =~ gfortran ]]; then + append-cflags -Dgfortran + fi + + append-fflags -ffixed-line-length-132 + + eprefixify Makefile.template + cp Makefile.template Makefile.incl || die +} + +src_compile() { + local target + local i + + if [[ $(tc-getFC) =~ gfortran ]]; then + target="linux" + else + target="linux-$(tc-getFC)" + fi + + for i in render.o ${target} all; do + emake \ + CFLAGS="${CFLAGS}" \ + LDFLAGS="${LDFLAGS}" \ + FFLAGS="${FFLAGS}" \ + CC="$(tc-getCC)"\ + FC="$(tc-getFC)" \ + INCDIRS="-I${EPREFIX}/usr/include" \ + LIBDIRS="-L${EPREFIX}/usr/$(get_libdir)" \ + ${i} + done +} + +src_install() { + emake prefix="${ED}"/usr \ + bindir="${ED}"/usr/bin \ + datadir="${ED}"/usr/share/Raster3D/materials \ + mandir="${ED}"/usr/share/man/man1 \ + htmldir="${ED}"/usr/share/doc/${PF}/html \ + examdir="${ED}"/usr/share/Raster3D/examples \ + install + + dodir /etc/env.d + echo -e "R3D_LIB=${EPREFIX}/usr/share/${NAME}/materials" > \ + "${ED}"/etc/env.d/10raster3d || \ + die "Failed to install env file." +} + +pkg_postinst() { + elog "Add following line:" + elog "<delegate decode=\"r3d\" command='\"render\" < \"%i\" > \"%o\"' />" + elog "to ${EPREFIX}/usr/$(get_libdir)/ImageMagick-6.5.8/config/delegates.xml" + elog "to make imagemagick use raster3d for .r3d files" +} |