summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Reynolds <fauno@kiwwwi.com.ar>2011-09-08 13:42:12 -0300
committerNicolas Reynolds <fauno@kiwwwi.com.ar>2011-09-08 13:42:12 -0300
commit3a6c3cea10ba48ea00beb2423e67011159f800b8 (patch)
tree626ea1643d25cc1425fe808b6a359fe9e3deeee1
parent1eb44cdc16d2ce4e40d42cacea7456ad245994f1 (diff)
parenta7b0a0b362d0535cd86b575a45ec70cc2332fa62 (diff)
Merge branch 'master' of ssh://vparabola/home/parabola/abslibre-pre-mips64el
Conflicts: libre/p7zip-libre/PKGBUILD
-rw-r--r--libre/p7zip-libre/PKGBUILD100
1 files changed, 65 insertions, 35 deletions
diff --git a/libre/p7zip-libre/PKGBUILD b/libre/p7zip-libre/PKGBUILD
index 28a900957..d0cb7ac26 100644
--- a/libre/p7zip-libre/PKGBUILD
+++ b/libre/p7zip-libre/PKGBUILD
@@ -7,49 +7,79 @@
pkgname=p7zip-libre
_pkgname=${pkgname%-libre}
-pkgver=9.20
-pkgrel=1
+pkgver=9.20.1
+pkgrel=4
pkgdesc='Command-line version of the 7zip compressed file archiver without Rar'
-arch=('i686' 'x86_64' 'mips64el')
-license=('GPL')
url='http://p7zip.sourceforge.net/'
-makedepends=('yasm' 'nasm')
-source=("http://downloads.sourceforge.net/sourceforge/${_pkgname}/${_pkgname}_${pkgver}_src_all.tar.bz2"
- 9.04-makefile.patch)
-provides=("p7zip=$pkgver")
-conflicts=('p7zip')
-replaces=('p7zip')
-sha1sums=('c976df4543ea946a65bc3f5e3d4e9baa417e5f12'
- '3a3333d4703955664fdd4023c624ab4828af0ab1')
+license=('GPL')
+arch=('i686' 'x86_64' 'mips64el')
+provides=("p7zip=$pkgver" 'unzip')
+conflicts=('p7zip' 'unzip')
+replaces=('p7zip' 'unzip')
+optdepends=('wxgtk: GUI'
+ 'desktop-file-utils: desktop entries')
+makedepends=('yasm' 'nasm' 'wxgtk')
+source=("http://repo.parabolagnulinux.org/other/${pkgname}_${pkgver}.tar.bz2"
+ 'p7zip-libre.patch'
+ 'unzip' # unzip replacement
+ '7zFM.desktop')
+md5sums=('c1eaf537e382b93adaa64713c96089fb'
+ '5b938c94cf80179137ea560dde510951'
+ '371af657bfb81a97bbeb5439896c814a'
+ '5b1c13139c42024d73abb67708ab6864')
+install=install
+
+mksource() {
+ if [ ! -d "${_pkgname}_${pkgver}" ]; then
+ wget -O - "http://downloads.sourceforge.net/project/${_pkgname}/${_pkgname}/${pkgver}/${_pkgname}_${pkgver}_src_all.tar.bz2" | \
+ tar xjf -
+ fi
+
+ pushd "${_pkgname}_${pkgver}"
+
+ msg "Removing unRar"
+# Generate patch
+# sed -e '/Rar/d' -i makefile*
+# find -name '*Rar*' -print0 | xargs -0 rm -rvf
+# Remove Rar mentions in CPP/7zip/Bundles/Format7zFree/makefile
+ patch -Np1 -i ../p7zip-libre.patch
+
+ popd
+
+ tar czvf "${pkgname}_${pkgver}.tar.bz2" "${_pkgname}_${pkgver}"
+}
+
build() {
- cd "${srcdir}/${_pkgname}_${pkgver}"
+ cd "${srcdir}/${_pkgname}_${pkgver}"
- msg "Removing unRar"
- sed -e '/Rar/d' -i makefile*
- rm -rf CPP/7zip/Compress/Rar
- patch -p1 -i $startdir/src/9.04-makefile.patch
-
- if [[ $CARCH = x86_64 ]] ; then
- cp makefile.linux_amd64_asm makefile.machine
- elif [ $CARCH = mips64el ]; then
- cp makefile.linux_any_cpu_gcc_4.X makefile.machine
- else
- cp makefile.linux_x86_asm_gcc_4.X makefile.machine
- fi
- sed -i "s|usr/local|usr|g" makefile
-
- make all3 OPTFLAGS="${CXXFLAGS}"
+ [[ $CARCH = x86_64 ]] \
+ && cp makefile.linux_amd64_asm makefile.machine \
+ || cp makefile.linux_x86_asm_gcc_4.X makefile.machine
+
+ make all4 OPTFLAGS="${CXXFLAGS}"
}
package() {
cd "${srcdir}/${_pkgname}_${pkgver}"
- make install \
- DEST_HOME="${pkgdir}/usr" \
- DEST_MAN="${pkgdir}/usr/share/man" \
- DEST_SHARE_DOC="http://www.bugaco.com/7zip"
+ make install \
+ DEST_DIR="${pkgdir}" \
+ DEST_HOME="/usr" \
+ DEST_MAN="/usr/share/man"
+
+ # Integration with stuff...
+ install -D contrib/VirtualFileSystemForMidnightCommander/u7z "${pkgdir}"/usr/lib/mc/extfs.d/u7z
+ install -D GUI/p7zip_32.png "${pkgdir}"/usr/share/icons/hicolor/32x32/apps/p7zip.png
+ install -d "${pkgdir}"/usr/share/{applications,kde4/services/ServiceMenus}
+ cp GUI/kde4/* "${pkgdir}"/usr/share/kde4/services/ServiceMenus/
+ cp ../7zFM.desktop "${pkgdir}"/usr/share/applications/
+ ln -s 7zCon.sfx "${pkgdir}"/usr/lib/p7zip/7z.sfx
+
+ find GUI/help -type d -exec chmod 755 {} \;
+ cp -r GUI/help "${pkgdir}"/usr/lib/p7zip/
+
+ chmod -R u+w "${pkgdir}/usr"
- install -m555 bin/7z.so ${pkgdir}/usr/lib/p7zip/
- sed "s|${pkgdir}/usr|/usr|g" -i "${pkgdir}"/usr/bin/7z{,a,r}
- install -Dm755 contrib/VirtualFileSystemForMidnightCommander/u7z "${pkgdir}"/usr/lib/mc/extfs.d/u7z
+# Install unzip replacement script
+ install -D -m755 "${srcdir}/unzip" "${pkgdir}/usr/bin/unzip"
}