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

View file

@ -2,7 +2,7 @@
# Contributer: Christian Hesse <mail@eworm.de>
pkgname=freecad-git
pkgver=0.17pre.r1771.gf944ab3
pkgver=0.17pre.r3401.g99fa203f3
pkgrel=1
epoch=1
pkgdesc='A general purpose 3D CAD modeler - git checkout'
@ -10,7 +10,7 @@ arch=('i686' 'x86_64')
url='http://www.freecadweb.org/'
license=('LGPL')
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')
makedepends=('git' 'boost' 'cmake' 'coin' 'python2-pyside-tools'
'desktop-file-utils' 'eigen' 'gcc-fortran' 'swig' 'patch')
@ -18,15 +18,12 @@ optdepends=('python2-matplotlib'
'pycollada-git: Create, edit and load COLLADA documents.')
provides=('freecad')
conflicts=('freecad')
install=freecad.install
source=("$pkgname::git+https://github.com/FreeCAD/FreeCAD.git"
"freecad.install"
"freecad.desktop"
"freecad.xml"
"fem-rpath.patch")
md5sums=('SKIP'
'2fad48203f96f1e7cb97934ea20ed848'
'0a4d0635dbd97d9f594ac8e927284316'
'7e781d41e90a1c137930e47672996a52'
'c2f4154c8e4678825411de8e7fa54c6b'
'99a41687a9ba980eea86aee4345d9a1d')
@ -69,6 +66,12 @@ package() {
ln -s "/opt/freecad/bin/FreeCADCmd" "$pkgdir/usr/bin/freecadcmd"
# 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 \
--dir="$pkgdir/usr/share/applications" "$srcdir/freecad.desktop"

View file

@ -8,7 +8,7 @@ Exec=/usr/bin/freecad %F
Path=/opt/freecad/lib
Terminal=false
Type=Application
Icon=/opt/freecad/data/freecad.xpm
Icon=freecad
Categories=Application;Science;Math;Education;
StartupNotify=true
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
}