Fix icon install & remove .install

Icons are now installed into /usr/share/icons and the desktop file now
specifies an icon file without a path.

The .install file is no longer needed since pacman 5.0.0 because it
introducted hooks (see /usr/share/libalpm/hooks) which take care of
updating all kinds of databases.
This commit is contained in:
Markus Hovorka 2017-02-16 23:24:27 +01:00
parent f02d6beca1
commit 8081f4b1fc
4 changed files with 13 additions and 29 deletions

View file

@ -1,10 +1,9 @@
pkgbase = freecad-git pkgbase = freecad-git
pkgdesc = A general purpose 3D CAD modeler - git checkout pkgdesc = A general purpose 3D CAD modeler - git checkout
pkgver = 0.17pre.r1771.gf944ab3 pkgver = 0.17pre.r3401.g99fa203f3
pkgrel = 1 pkgrel = 1
epoch = 1 epoch = 1
url = http://www.freecadweb.org/ url = http://www.freecadweb.org/
install = freecad.install
arch = i686 arch = i686
arch = x86_64 arch = x86_64
license = LGPL license = LGPL
@ -27,7 +26,6 @@ pkgbase = freecad-git
depends = xerces-c depends = xerces-c
depends = python2-pivy depends = python2-pivy
depends = python2-pyside depends = python2-pyside
depends = qtwebkit
depends = libtheora depends = libtheora
depends = shared-mime-info depends = shared-mime-info
depends = vtk-qt4 depends = vtk-qt4
@ -37,13 +35,11 @@ pkgbase = freecad-git
provides = freecad provides = freecad
conflicts = freecad conflicts = freecad
source = freecad-git::git+https://github.com/FreeCAD/FreeCAD.git source = freecad-git::git+https://github.com/FreeCAD/FreeCAD.git
source = freecad.install
source = freecad.desktop source = freecad.desktop
source = freecad.xml source = freecad.xml
source = fem-rpath.patch source = fem-rpath.patch
md5sums = SKIP md5sums = SKIP
md5sums = 2fad48203f96f1e7cb97934ea20ed848 md5sums = 7e781d41e90a1c137930e47672996a52
md5sums = 0a4d0635dbd97d9f594ac8e927284316
md5sums = c2f4154c8e4678825411de8e7fa54c6b md5sums = c2f4154c8e4678825411de8e7fa54c6b
md5sums = 99a41687a9ba980eea86aee4345d9a1d md5sums = 99a41687a9ba980eea86aee4345d9a1d

View file

@ -2,7 +2,7 @@
# Contributer: Christian Hesse <mail@eworm.de> # Contributer: Christian Hesse <mail@eworm.de>
pkgname=freecad-git pkgname=freecad-git
pkgver=0.17pre.r1771.gf944ab3 pkgver=0.17pre.r3401.g99fa203f3
pkgrel=1 pkgrel=1
epoch=1 epoch=1
pkgdesc='A general purpose 3D CAD modeler - git checkout' pkgdesc='A general purpose 3D CAD modeler - git checkout'
@ -10,7 +10,7 @@ arch=('i686' 'x86_64')
url='http://www.freecadweb.org/' url='http://www.freecadweb.org/'
license=('LGPL') license=('LGPL')
depends=('boost-libs' 'curl' 'hicolor-icon-theme' 'libspnav' 'opencascade' depends=('boost-libs' 'curl' 'hicolor-icon-theme' 'libspnav' 'opencascade'
'med' 'xerces-c' 'python2-pivy' 'python2-pyside' 'qtwebkit' 'med' 'xerces-c' 'python2-pivy' 'python2-pyside'
'libtheora' 'shared-mime-info' 'vtk-qt4' 'jsoncpp') 'libtheora' 'shared-mime-info' 'vtk-qt4' 'jsoncpp')
makedepends=('git' 'boost' 'cmake' 'coin' 'python2-pyside-tools' makedepends=('git' 'boost' 'cmake' 'coin' 'python2-pyside-tools'
'desktop-file-utils' 'eigen' 'gcc-fortran' 'swig' 'patch') 'desktop-file-utils' 'eigen' 'gcc-fortran' 'swig' 'patch')
@ -18,15 +18,12 @@ optdepends=('python2-matplotlib'
'pycollada-git: Create, edit and load COLLADA documents.') 'pycollada-git: Create, edit and load COLLADA documents.')
provides=('freecad') provides=('freecad')
conflicts=('freecad') conflicts=('freecad')
install=freecad.install
source=("$pkgname::git+https://github.com/FreeCAD/FreeCAD.git" source=("$pkgname::git+https://github.com/FreeCAD/FreeCAD.git"
"freecad.install"
"freecad.desktop" "freecad.desktop"
"freecad.xml" "freecad.xml"
"fem-rpath.patch") "fem-rpath.patch")
md5sums=('SKIP' md5sums=('SKIP'
'2fad48203f96f1e7cb97934ea20ed848' '7e781d41e90a1c137930e47672996a52'
'0a4d0635dbd97d9f594ac8e927284316'
'c2f4154c8e4678825411de8e7fa54c6b' 'c2f4154c8e4678825411de8e7fa54c6b'
'99a41687a9ba980eea86aee4345d9a1d') '99a41687a9ba980eea86aee4345d9a1d')
@ -69,6 +66,12 @@ package() {
ln -s "/opt/freecad/bin/FreeCADCmd" "$pkgdir/usr/bin/freecadcmd" ln -s "/opt/freecad/bin/FreeCADCmd" "$pkgdir/usr/bin/freecadcmd"
# Install pixmaps and desktop shortcut. # Install pixmaps and desktop shortcut.
for i in 16 32 48 64; do
install -Dm644 "src/Gui/Icons/freecad-icon-${i}.png" \
"$pkgdir/usr/share/icons/hicolor/${i}x${i}/apps/freecad.png"
done
install -Dm644 "src/Gui/Icons/freecad.svg" \
"$pkgdir/usr/share/icons/hicolor/scalable/apps/freecad.svg"
desktop-file-install \ desktop-file-install \
--dir="$pkgdir/usr/share/applications" "$srcdir/freecad.desktop" --dir="$pkgdir/usr/share/applications" "$srcdir/freecad.desktop"

View file

@ -8,7 +8,7 @@ Exec=/usr/bin/freecad %F
Path=/opt/freecad/lib Path=/opt/freecad/lib
Terminal=false Terminal=false
Type=Application Type=Application
Icon=/opt/freecad/data/freecad.xpm Icon=freecad
Categories=Application;Science;Math;Education; Categories=Application;Science;Math;Education;
StartupNotify=true StartupNotify=true
MimeType=application/x-extension-fcstd; MimeType=application/x-extension-fcstd;

View file

@ -1,15 +0,0 @@
post_install() {
xdg-icon-resource forceupdate --theme hicolor &> /dev/null
update-desktop-database -q
update-mime-database usr/share/mime
}
post_upgrade() {
post_install
}
post_remove() {
xdg-icon-resource forceupdate --theme hicolor &> /dev/null
update-desktop-database -q
update-mime-database usr/share/mime
}