Add PKGBUILD to build Pacman package

This commit is contained in:
Mario Hüttel 2018-07-25 11:19:15 +02:00
parent 7c47d7207f
commit 6f9b23301e
3 changed files with 51 additions and 0 deletions

41
AUR/PKGBUILD Normal file
View File

@ -0,0 +1,41 @@
# Maintainer: Mario Hüttel <mario (dot) huettel (!) gmx (dot) net>
pkgname=gds-render
pkgver=20180725.001
pkgrel=1
pkgdesc="Conversion tool for converting GDS layout files into TikZ Code and PDF"
arch=('i686', 'x86_64')
url="https://git.shimatta.de/mhu/gds-render"
licence=('GPLv2')
depends=('glib2' 'gtk3' 'cairo')
makedepends=('cmake' 'git')
privides=('gds-render')
source=("$pkgname"::"git+https://git.shimatta.de/mhu/gds-render.git")
sha1sums=('SKIP')
pkgver () {
_date=`date +"%Y%m%d"`
cd "${srcdir}/${pkgname}"
echo "$_date.$(git rev-list --count master).$(git rev-parse --short master)"
}
prepare () {
}
build () {
cd "$srcdir/$pkgname"
cmake .
make
}
package () {
cd "$srcdir/$pkgname"
make DESTDIR="${pkgdir}" install
install -D -m664 "$srcdir/$pkgname/AUR/gds-render.desktop" \
"$pkgdir/usr/share/applications/gds-render.desktop"
install -D -m664 "$srcdir/$pkgname/icon/gds-render.svg" \
"$pkgdir/usr/share/icons/hicolor/scalable/apps/gds-render.svg"
install -D -m664 "$srcdir/$pkgname/icon/128x128/gds-render.png" \
"$pkgdir/usr/share/icons/hicolor/128x128/apps/gds-render.png"
}

9
AUR/gds-render.desktop Normal file
View File

@ -0,0 +1,9 @@
[Desktop Entry]
Version=1.0
Type=Application
Name=GDS-Render
Comment=Converter for GDS layout files
Icon=gds-render
Exec=gds-render
Categories=Graphics

View File

@ -35,4 +35,5 @@ add_executable(${PROJECT_NAME} ${SOURCE} ${CMAKE_CURRENT_BINARY_DIR}/glade/resou
add_dependencies(${PROJECT_NAME} glib-resources) add_dependencies(${PROJECT_NAME} glib-resources)
SET_SOURCE_FILES_PROPERTIES(${CMAKE_CURRENT_BINARY_DIR}/glade/resources.c PROPERTIES GENERATED 1) SET_SOURCE_FILES_PROPERTIES(${CMAKE_CURRENT_BINARY_DIR}/glade/resources.c PROPERTIES GENERATED 1)
target_link_libraries(${PROJECT_NAME} ${GLIB_LDFLAGS} ${GTK3_LDFLAGS} ${CAIRO_LDFLAGS} m) target_link_libraries(${PROJECT_NAME} ${GLIB_LDFLAGS} ${GTK3_LDFLAGS} ${CAIRO_LDFLAGS} m)
install (TARGETS ${PROJECT_NAME} DESTINATION bin)