aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUnia <jthidskes@live.nl>2013-04-10 14:08:18 +0200
committerUnia <jthidskes@live.nl>2013-04-10 14:08:18 +0200
commit6f96fd211d59d69fd47ff84c6b6e046cd3d57c59 (patch)
tree4065d1af09f606be8a20c794e6991cea95b08d17
parentefca1d1c3b92594a673f350028554ed1c829050f (diff)
new pkgbuild conform pacman 4.1
-rw-r--r--Makefile5
-rw-r--r--PKGBUILD47
2 files changed, 20 insertions, 32 deletions
diff --git a/Makefile b/Makefile
index 0033ed9..4b951c6 100644
--- a/Makefile
+++ b/Makefile
@@ -2,20 +2,19 @@ PROG = gstopwatch
CC = gcc
LIBS = `pkg-config --cflags --libs gtk+-3.0`
-CFLAGS = -std=c99 -Wall -Wextra -Wno-deprecated-declarations
+CFLAGS = -std=c99 -Wall -Wextra
PREFIX ?= /usr/local
BINPREFIX = $(PREFIX)/bin
all: CFLAGS += -Os
-all: LDFLAGS += -s
all: $(PROG)
debug: CFLAGS += -O0 -g -pedantic
debug: all
$(PROG): $(PROG).c
- gcc $(PROG).c -o $(PROG) $(CFLAGS) $(LIBS)
+ $(CC) $(PROG).c -o $(PROG) $(CFLAGS) $(LIBS)
install:
mkdir -p $(DESTDIR)/$(BINPREFIX)
diff --git a/PKGBUILD b/PKGBUILD
index f0da0a8..5dc6fb9 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,40 +1,29 @@
+# Maintainer: Unia <jthidskes@outlook.com>
+
pkgname=gstopwatch-git
-pkgbase=gstopwatch
-pkgver=2013.03.28
+_gitname=gstopwatch
+pkgver=2013.04.10
pkgrel=1
-pkgdesc="A simple stopwatch, written in GTK3."
-arch=(any)
+pkgdesc="A simple stopwatch, written in GTK3"
+arch=('i686' 'x86_64')
url="https://github.com/Unia/gstopwatch"
-license=(GPL)
+license=('GPL2')
depends=('gtk3')
+makedepends=('git')
+source=('git://github.com/Unia/gstopwatch.git')
+md5sums=('SKIP')
-_gitroot="https://github.com/Unia/$pkgbase"
-_gitname="$pkgbase"
-
-build() {
- cd "$srcdir"
- msg "Connecting to GIT server..."
-
- if [ -d ${_gitname} ] ; then
- cd ${_gitname}/
- git pull
- msg "The local files are updated."
- else
- git clone ${_gitroot} ${_gitname}
- cd ${_gitname}/
- fi
- msg "GIT checkout done or server timeout"
-
- make
+pkgver() {
+ cd $_gitname
+ git log -1 --format="%cd" --date=short | sed 's|-|.|g'
}
-pkgver() {
- cd "$srcdir/$_gitname"
- git log -1 --format="%cd" --date=short | sed 's\-\.\g'
+build() {
+ cd $_gitname
+ make
}
package() {
- cd "$srcdir/$pkgbase/"
-
- make DESTDIR="$pkgdir" install
+ cd $_gitname
+ make PREFIX=/usr DESTDIR="$pkgdir" install
}