commit: b1b9d3a6a59a5af4c81e7b74b655d07bc62757e9 Author: Martin Mokrejš <mmokrejs <AT> fold <DOT> natur <DOT> cuni <DOT> cz> AuthorDate: Fri Mar 28 14:06:16 2014 +0000 Commit: Nicolas Bock <nicolasbock <AT> gmail <DOT> com> CommitDate: Mon Mar 31 15:27:34 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=b1b9d3a6
sci-biology/tablet: skeleton for a new package eventually to replace current tablet-bin package Package-Manager: portage-2.2.7 --- sci-biology/tablet/ChangeLog | 12 ++++ sci-biology/tablet/files/response.varfile | 11 +++ sci-biology/tablet/metadata.xml | 9 +++ sci-biology/tablet/tablet-1.13.12.17.ebuild | 90 +++++++++++++++++++++++++ sci-biology/tablet/tablet-9999.ebuild | 100 ++++++++++++++++++++++++++++ 5 files changed, 222 insertions(+) diff --git a/sci-biology/tablet/ChangeLog b/sci-biology/tablet/ChangeLog new file mode 100644 index 0000000..0080ef2 --- /dev/null +++ b/sci-biology/tablet/ChangeLog @@ -0,0 +1,12 @@ +# ChangeLog for sci-biology/tablet +# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 +# $Header: $ + +*tablet-1.13.12.17 (28 Mar 2014) +*tablet-9999 (28 Mar 2014) + + 28 Mar 2014; Martin Mokrejs <mmokr...@fold.natur.cuni.cz> + +files/response.varfile, +metadata.xml, +tablet-1.13.12.17.ebuild, + +tablet-9999.ebuild: + sci-biology/tablet: skeleton for a new package eventually to replace current + tablet-bin package diff --git a/sci-biology/tablet/files/response.varfile b/sci-biology/tablet/files/response.varfile new file mode 100644 index 0000000..cfa2e68 --- /dev/null +++ b/sci-biology/tablet/files/response.varfile @@ -0,0 +1,11 @@ +#install4j response file for Tablet x.xx.xx.xx +#Mon Jan 24 11:35:29 GMT 2011 +executeLauncherAction$Boolean=false +sys.programGroupDisabled$Boolean=true +# somehow, this happens: ln -s /scratch/var/tmp/portage/sci-biology/tablet-bin-1.11.02.18/image/opt/Tablet/tablet /usr/local/bin/tablet +# # that happens because /scratch/var/tmp/portage/sci-biology/tablet-bin-1.11.02.18/image/opt/Tablet/.install4j/response.varfile does not reflect our values +sys.symlinkDir="${D}"usr/bin +#sys.symlinkDir=/scratch/var/tmp/portage/sci-biology/tablet-bin-1.11.02.18/image/usr/bin +sys.languageId=en +sys.userHome="${D}"/../temp +sys.installationDir="${D}"opt/Tablet diff --git a/sci-biology/tablet/metadata.xml b/sci-biology/tablet/metadata.xml new file mode 100644 index 0000000..2bc8930 --- /dev/null +++ b/sci-biology/tablet/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>sci-biology</herd> + <maintainer> + <email>mmokr...@fold.natur.cuni.cz</email> + <name>Martin Mokrejs</name> + </maintainer> +</pkgmetadata> diff --git a/sci-biology/tablet/tablet-1.13.12.17.ebuild b/sci-biology/tablet/tablet-1.13.12.17.ebuild new file mode 100644 index 0000000..112709b --- /dev/null +++ b/sci-biology/tablet/tablet-1.13.12.17.ebuild @@ -0,0 +1,90 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 + +PYTHON_COMPAT=( python{2_6,2_7} ) + +inherit java-pkg-2 python-r1 + +DESCRIPTION="Viewer of next generation sequence assemblies and alignments." +HOMEPAGE="http://bioinf.scri.ac.uk/tablet/" +SRC_URI=" + x86? ( http://bioinf.scri.ac.uk/tablet/installers/tablet_linux_x86_$(replace_all_version_separators _).sh -> ${P}.sh ) + amd64? ( http://bioinf.scri.ac.uk/tablet/installers/tablet_linux_x64_$(replace_all_version_separators _).sh -> ${P}.sh ) + http://bioinf.scri.ac.uk/tablet/additional/coveragestats.py" + +# Upstream says regarding source code unavailability: +# Tablet uses a modified version of the BSD License which has been edited to +# remove references to distribution and use in source forms. This means that +# we are happy for you to distribute and use Tablet however you please, but we +# do not (yet) want to make the source code publicly available. + +# The licence file itself is in the installer, and ends up on disk after +# installation at /opt/Tablet/docs/tablet.html +# The original BSD licence was modified to remove references to distribution +# and use in source forms, because we cannot make the source code available +# for Tablet. + +LICENSE="Tablet" +SLOT="0" +KEYWORDS="" +IUSE="" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +DEPEND="${PYTHON_DEPS}" +RDEPEND="${DEPEND} + virtual/jre" + +S="${WORKDIR}" + +src_unpack() { + local file + for file in ${A}; do + cp "${DISTDIR}"/${file} "${WORKDIR}" || die + done +} + +src_install() { + # In theory it seems this binary package could be installed through ant + # instead of the install4j package which is not easy to be forced + # non-interactive. The below approach via install4j is not ideal but works. + sed "s#\"\${D}\"#\"${D}\"#g" "${FILESDIR}"/response.varfile > "${WORKDIR}"/response.varfile || die "sed failed" + + # the intallation script somehow does not pickup + # -varfile="${DISTDIR}"/response.varfile from the commandline and therefore + # we place the file rather directly into the place where it should reside. + # In the file you can read details how the variables were mangled. For + # example, the trick with sys.symlinkDir in the response.varfile is to + # disable the installation process to symlink from /usr/local/bin/table to + # /opt/Tablet/tablet. That was logged in that file with the following line: + # + # /var/tmp/portage/sci-biology/tablet-bin-1.11.02.18/image/opt/Tablet/.install4j/installation.log: + # Variable changed: sys.symlinkDir=/usr/local/bin[class java.lang.String] + # + # The file is then left on the installed system in "${D}"/opt/Tablet/.install4j/response.varfile + dodir /opt/Tablet/.install4j + cat "${WORKDIR}"/response.varfile > "${ED}"/opt/Tablet/.install4j/response.varfile || die + + # make sure we force java to point a to $HOME which is inside our sanbox + # directory area. We force -Duser.home . It seems also -Dinstall4j.userHome + # could be done based on the figure shown at http://resources.ej-technologies.com/install4j/help/doc/ + sed \ + -e "s#/bin/java\" -Dinstall4j.jvmDir#/bin/java\" -Duser.home="${TMPDIR}" -Dinstall4j.jvmDir#" \ + -i "${WORKDIR}"/${P}.sh || die + sh \ + "${WORKDIR}"/${P}.sh \ + -q -overwrite \ + -varfile="${DISTDIR}"/response.varfile \ + --destination="${ED}"/opt/Tablet \ + -dir "${ED}"/opt/Tablet || die + + rm -rf "${ED}"/opt/Tablet/jre || die + + python_foreach_impl python_doscript "${WORKDIR}"/coveragestats.py + + echo "PATH=${EPREFIX}/opt/Tablet" > 99Tablet + doenvd 99Tablet || die +} diff --git a/sci-biology/tablet/tablet-9999.ebuild b/sci-biology/tablet/tablet-9999.ebuild new file mode 100644 index 0000000..40472c7 --- /dev/null +++ b/sci-biology/tablet/tablet-9999.ebuild @@ -0,0 +1,100 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 + +PYTHON_COMPAT=( python{2_6,2_7} ) + +inherit java-pkg-2 java-ant-2 python-r1 eutils + +[ "$PV" == "9999" ] && inherit subversion + +DESCRIPTION="Viewer of next generation sequence assemblies and alignments." +HOMEPAGE="http://bioinf.scri.ac.uk/tablet/" +if [ "$PV" == "9999" ]; then + ESVN_REPO_URI="http://ics.hutton.ac.uk/svn/tablet/trunk/" + KEYWORDS="" +else + ESVN_REPO_URI="http://ics.hutton.ac.uk/svn/tablet/tags/${PV}" + KEYWORDS="" +fi + +#SRC_URI=" +# x86? ( http://bioinf.scri.ac.uk/tablet/installers/tablet_linux_x86_$(replace_all_version_separators _).sh -> ${P}.sh ) +# amd64? ( http://bioinf.scri.ac.uk/tablet/installers/tablet_linux_x64_$(replace_all_version_separators _).sh -> ${P}.sh ) +# http://bioinf.scri.ac.uk/tablet/additional/coveragestats.py" + +# Upstream says regarding source code unavailability: +# Tablet uses a modified version of the BSD License which has been edited to +# remove references to distribution and use in source forms. This means that +# we are happy for you to distribute and use Tablet however you please, but we +# do not (yet) want to make the source code publicly available. + +# The licence file itself is in the installer, and ends up on disk after +# installation at /opt/Tablet/docs/tablet.html +# The original BSD licence was modified to remove references to distribution +# and use in source forms, because we cannot make the source code available +# for Tablet. + +LICENSE="Tablet" +SLOT="0" +IUSE="" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +DEPEND="${PYTHON_DEPS} + virtual/jdk" +RDEPEND="${DEPEND} + virtual/jre" + +S="${WORKDIR}" + +src_unpack() { + local file + for file in ${A}; do + cp "${DISTDIR}"/${file} "${WORKDIR}" || die + done +} + +src_install() { + # In theory it seems this binary package could be installed through ant + # instead of the install4j package which is not easy to be forced + # non-interactive. The below approach via install4j is not ideal but works. + sed "s#\"\${D}\"#\"${D}\"#g" "${FILESDIR}"/response.varfile > "${WORKDIR}"/response.varfile || die "sed failed" + + # the intallation script somehow does not pickup + # -varfile="${DISTDIR}"/response.varfile from the commandline and therefore + # we place the file rather directly into the place where it should reside. + # In the file you can read details how the variables were mangled. For + # example, the trick with sys.symlinkDir in the response.varfile is to + # disable the installation process to symlink from /usr/local/bin/table to + # /opt/Tablet/tablet. That was logged in that file with the following line: + # + # /var/tmp/portage/sci-biology/tablet-bin-1.11.02.18/image/opt/Tablet/.install4j/installation.log: + # Variable changed: sys.symlinkDir=/usr/local/bin[class java.lang.String] + # + # The file is then left on the installed system in "${D}"/opt/Tablet/.install4j/response.varfile + dodir /opt/Tablet/.install4j + cat "${WORKDIR}"/response.varfile > "${ED}"/opt/Tablet/.install4j/response.varfile || die + + # make sure we force java to point a to $HOME which is inside our sanbox + # directory area. We force -Duser.home . It seems also -Dinstall4j.userHome + # could be done based on the figure shown at http://resources.ej-technologies.com/install4j/help/doc/ + sed \ + -e "s#/bin/java\" -Dinstall4j.jvmDir#/bin/java\" -Duser.home="${TMPDIR}" -Dinstall4j.jvmDir#" \ + -i "${WORKDIR}"/${P}.sh || die + sh \ + "${WORKDIR}"/${P}.sh \ + -q -overwrite \ + -varfile="${DISTDIR}"/response.varfile \ + --destination="${ED}"/opt/Tablet \ + -dir "${ED}"/opt/Tablet || die + + rm -rf "${ED}"/opt/Tablet/jre || die + + python_foreach_impl python_doscript "${WORKDIR}"/coveragestats.py + + echo "PATH=${EPREFIX}/opt/Tablet" > 99Tablet + doenvd 99Tablet || die +}