From a26875c549b4e4246963d1810e74e94943719703 Mon Sep 17 00:00:00 2001 From: Dominik Honnef Date: Sun, 20 Mar 2016 19:49:15 +0100 Subject: [PATCH] Split p7zip into p7zip and p7zip-unrar The RAR support in p7zip is based on unrar's code and unfree. --- srcpkgs/p7zip-unrar | 1 + srcpkgs/p7zip/template | 23 ++++++++++++++++++++--- 2 files changed, 21 insertions(+), 3 deletions(-) create mode 120000 srcpkgs/p7zip-unrar diff --git a/srcpkgs/p7zip-unrar b/srcpkgs/p7zip-unrar new file mode 120000 index 00000000000..bf5349ee666 --- /dev/null +++ b/srcpkgs/p7zip-unrar @@ -0,0 +1 @@ +p7zip \ No newline at end of file diff --git a/srcpkgs/p7zip/template b/srcpkgs/p7zip/template index 1fa26006824..98e9760399c 100644 --- a/srcpkgs/p7zip/template +++ b/srcpkgs/p7zip/template @@ -1,13 +1,13 @@ # Template file for 'p7zip' pkgname=p7zip version=15.09 +revision=2 wrksrc=${pkgname}_${version} -revision=1 patch_args="-Np1" hostmakedepends="yasm nasm" short_desc="Command-line version of the 7zip compressed file archive" homepage="http://p7zip.sourceforge.net/" -license="LGPL-2.1, unrar" +license="LGPL-2.1" maintainer="Juan RP " distfiles="${SOURCEFORGE_SITE}/${pkgname}/${pkgname}_${version}_src_all.tar.bz2" checksum=8783acf747e210e00150f7311cc06c4cd8ecf7b0c27b4adf2194284cc49b4d6f @@ -22,13 +22,30 @@ do_configure() { sed -e "s,g++,${CXX}," -i makefile.machine sed -e "s,gcc,${CC}," -i makefile.machine } + do_build() { make all3 OPTFLAGS="$CXXFLAGS" ${makejobs} } + do_install() { make install DEST_DIR="${DESTDIR}" DEST_HOME="/usr" \ DEST_MAN="/usr/share/man" \ DEST_SHARE_DOC="/usr/share/doc/${pkgname}" find ${DESTDIR}/usr/share/doc/$pkgname -type d -exec chmod 755 {} \; - vlicense DOC/License.txt + mkdir -p ${DESTDIR}/usr/share/licenses/p7zip/ + mv ${DESTDIR}/usr/share/doc/p7zip/DOC/copying.txt \ + ${DESTDIR}/usr/share/licenses/p7zip/LICENSE +} + +p7zip-unrar_package() { + short_desc+=" - RAR support" + license="unrar" + depends="${sourcepkg}-${version}_${revision}" + repository=nonfree + pkg_install() { + vmove usr/lib/p7zip/Codecs/Rar.so + mkdir -p ${PKGDESTDIR}/usr/share/licenses/p7zip-unrar + mv ${DESTDIR}/usr/share/doc/p7zip/DOC/License.txt \ + ${PKGDESTDIR}/usr/share/licenses/p7zip-unrar + } }