# Copyright 1999-2019 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI=6 inherit depend.apache webapp eutils subversion DESCRIPTION="SQL based, powerful small business accounting system" SRC_URI="http://www.sql-ledger.com/source/${P}.tar.gz" #https://www.sql-ledger.com/source/sql-ledger-3.2.8.tar.gz if [[ ${PV} != *9999* ]]; then SRC_URI="https://www.sql-ledger.com/source/${P}.tar.gz" #https://www.sql-ledger.com/source/sql-ledger-3.2.8.tar.gz KEYWORDS="amd64 hppa ppc ~sparc x86" WEBAPP_MANUAL_SLOT="yes" SLOT="3" else #ESVN_REPO_URI="svn://svn.code.sf.net/p/ledger-smb/code/trunk" ESVN_PROJECT="${PN}" KEYWORDS="~amd64 ~hppa ~ppc ~sparc ~x86" WEBAPP_MANUAL_SLOT="yes" SLOT="4" fi HOMEPAGE="http://www.sql-ledger.com/" # The sources should be put in /usr/portage/distfiles # This ebuild exists largely to allow Gentoo to pull in all # the needed dependencies. The rest of it is based on extracting # the necessary steps from SQL-Ledger's setup.pl and README. # THIS EBUILD IS NOT YET INTENDED TO UPGRADE AN EXISTING INSTALLATION. # However that is the next step. LICENSE="GPL" # Keywords are the same as apache KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-linux ~x64-macos ~x86-macos ~m68k-mint ~sparc64-solaris ~x64-solaris" IUSE="debug doc latex" RDEPEND="${DEPEND} dev-perl/libwww-perl >=dev-lang/perl-5.14.0 >=dev-db/postgresql-7.1 dev-perl/DBI dev-perl/DBD-Pg latex? ( dev-perl/Template-Plugin-Latex ) latex? ( dev-perl/Image-Size ) latex? ( virtual/latex-base ) latex? ( dev-texlive/texlive-latexextra )" need_apache S=${WORKDIR}/${PN} pkg_setup(){ webapp_pkg_setup } S="${WORKDIR}/sql-ledger" src_unpack() { unpack ${A} } src_compile() { # do we want to do something with sql-ledger.conf.default? echo } src_install() { webapp_src_preinst # handle documentation files # # NOTE that doc files go into /usr/share/doc as normal; they do NOT # get installed per vhost! einfo "Installing docs" dodoc -r doc/* einfo "Copying main files" cp sql-ledger.conf.default sql-ledger.conf cp -r . ${D}/${MY_HTDOCSDIR} rm -rf ${D}/${MY_HTDOCSDIR}/doc einfo "Setting Server Ownership" # Files which must be server owned for so in `find users css templates spool`; do webapp_serverowned ${MY_HTDOCSDIR}/${so} done einfo "Marking Config Files" #Config files webapp_configfile ${MY_HTDOCSDIR}/sql-ledger.conf keepdir ${MY_HTDOCSDIR}/spool #webapp_postinst_txt en ${FILESDIR}/postinstall-en.txt webapp_src_install }