summaryrefslogtreecommitdiff
path: root/community/libfaketime
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2013-07-19 01:10:32 -0700
committerroot <root@rshg054.dnsready.net>2013-07-19 01:10:32 -0700
commit8fbc0076a4827ddc6af92e0b9daa4c4c31450808 (patch)
tree03fd0e2921ebd53228d9a93e32ed3976b636cbea /community/libfaketime
parente445a313723389ba9ee1fded025c567dae5b21ea (diff)
Fri Jul 19 01:09:18 PDT 2013
Diffstat (limited to 'community/libfaketime')
-rw-r--r--community/libfaketime/PKGBUILD32
-rw-r--r--community/libfaketime/libfaketime-0.9.1-fix-README-NEWS.patch29
-rw-r--r--community/libfaketime/libfaketime-0.9.1-fix-as-needed.patch39
3 files changed, 100 insertions, 0 deletions
diff --git a/community/libfaketime/PKGBUILD b/community/libfaketime/PKGBUILD
new file mode 100644
index 000000000..447f4b364
--- /dev/null
+++ b/community/libfaketime/PKGBUILD
@@ -0,0 +1,32 @@
+# $Id: PKGBUILD 62627 2012-01-22 21:34:26Z lfleischer $
+# Maintainer: Lukas Fleischer <archlinux at cryptocrack dot de>
+# Contributor: Dan Serban
+# Contributor: Ross Melin <rdmelin@gmail.com>
+
+pkgname=libfaketime
+pkgver=0.9.1
+pkgrel=1
+pkgdesc='Report fake dates and times to programs without having to change the system-wide time.'
+arch=('i686' 'x86_64')
+url='http://www.code-wizards.com/projects/libfaketime/'
+license=('GPL2')
+source=("http://www.code-wizards.com/projects/${pkgname}/${pkgname}-${pkgver}.tar.gz"
+ 'libfaketime-0.9.1-fix-as-needed.patch'
+ 'libfaketime-0.9.1-fix-README-NEWS.patch')
+md5sums=('ce3f996dfd5826b4ac62f1a7cc36ea27'
+ '90873e4df35283463ef54b159c318686'
+ 'b1b641a8e2298aa1646982e3bde96117')
+
+build() {
+ cd "${pkgname}-${pkgver}"
+
+ patch -p1 -i ../libfaketime-0.9.1-fix-as-needed.patch
+ patch -p1 -i ../libfaketime-0.9.1-fix-README-NEWS.patch
+
+ make
+}
+
+package() {
+ cd "${pkgname}-${pkgver}"
+ make PREFIX=/usr DESTDIR="${pkgdir}" install
+}
diff --git a/community/libfaketime/libfaketime-0.9.1-fix-README-NEWS.patch b/community/libfaketime/libfaketime-0.9.1-fix-README-NEWS.patch
new file mode 100644
index 000000000..3d47c5404
--- /dev/null
+++ b/community/libfaketime/libfaketime-0.9.1-fix-README-NEWS.patch
@@ -0,0 +1,29 @@
+From c0c19a71c5481f3082afee2ac7962bd7abfcf134 Mon Sep 17 00:00:00 2001
+From: Lukas Fleischer <info@cryptocrack.de>
+Date: Sun, 22 Jan 2012 22:19:50 +0100
+Subject: [PATCH] Makefile: Fix installation of "README" and "NEWS"
+
+Initialize "INSTALL" in the top-level Makefile in order to avoid broken
+install(1) invocations such as:
+
+ dm0755 "/build/pkg/usr/share/doc/faketime/"
+ /bin/sh: dm0755: command not found
+
+Signed-off-by: Lukas Fleischer <info@cryptocrack.de>
+---
+ Makefile | 2 ++
+ 1 files changed, 2 insertions(+), 0 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index f90e18e..d0225ba 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,3 +1,5 @@
++INSTALL = install
++
+ all:
+ $(MAKE) -C src all
+ $(MAKE) -C test all
+--
+1.7.8.4
+
diff --git a/community/libfaketime/libfaketime-0.9.1-fix-as-needed.patch b/community/libfaketime/libfaketime-0.9.1-fix-as-needed.patch
new file mode 100644
index 000000000..870349145
--- /dev/null
+++ b/community/libfaketime/libfaketime-0.9.1-fix-as-needed.patch
@@ -0,0 +1,39 @@
+From f0ee2ee1e0a2fa5f11614a55ab8543380faa9695 Mon Sep 17 00:00:00 2001
+From: Lukas Fleischer <info@cryptocrack.de>
+Date: Sun, 22 Jan 2012 21:47:52 +0100
+Subject: [PATCH] Fix linking with "-Wl,--as-needed"
+
+Reorder linker flags in order to ensure proper linking when using
+"--Wl,--as-needed". Read http://www.gentoo.org/proj/en/qa/asneeded.xml,
+especially "Importance of linking order" for details:
+
+ Basically, what the linker does is look for the symbols missing in a
+ given file (either an object file, a static archive or a library)
+ only in the files coming after it. When using the normal linking,
+ without --as-needed, this is not a problem, although there might be
+ some internal drawbacks on the linking stage, the files are linked
+ together without considering ordering. But with the flag, the
+ libraries that aren't used for resolving symbols are discarded and
+ thus not linked.
+
+Signed-off-by: Lukas Fleischer <info@cryptocrack.de>
+---
+ src/Makefile | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 9118815..d4a04b5 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -69,7 +69,7 @@ ${OBJ}: faketime.c
+ ${CC} -o $@ -c ${CFLAGS} ${EXTRA_FLAGS} $<
+
+ lib%.so.${SONAME}: %.o
+- ${CC} -o $@ -Wl,-soname,$@ ${LDFLAGS} $<
++ ${CC} -o $@ -Wl,-soname,$@ $< ${LDFLAGS}
+
+ clean:
+ @rm -f ${OBJ} ${LIBS}
+--
+1.7.8.4
+