diff options
Diffstat (limited to 'extra/compface')
-rw-r--r-- | extra/compface/PKGBUILD | 26 | ||||
-rw-r--r-- | extra/compface/compface-1.5.2-build.patch | 82 |
2 files changed, 100 insertions, 8 deletions
diff --git a/extra/compface/PKGBUILD b/extra/compface/PKGBUILD index 98f83cb2c..dc2285f2c 100644 --- a/extra/compface/PKGBUILD +++ b/extra/compface/PKGBUILD @@ -1,28 +1,38 @@ -# $Id: PKGBUILD 137677 2011-09-10 11:50:26Z pierre $ -# Maintainer: simo <simo@archlinux.org> +# $Id: PKGBUILD 197085 2013-10-21 18:34:54Z andyrtr $ +# Maintainer: AndyRTR <andyrtr@archlinux.org> +# Contributor: simo <simo@archlinux.org> # Contributor: Manolis Tzanidakis pkgname=compface pkgver=1.5.2 -pkgrel=3 +pkgrel=4 pkgdesc="Utils & libs to convert from/to X-Face format." arch=('i686' 'x86_64') url="http://ftp.xemacs.org/pub/xemacs/aux/" license=('custom') depends=('glibc') -source=("$url/$pkgname-$pkgver.tar.gz" 'LICENSE') +source=($url/$pkgname-$pkgver.tar.gz + compface-1.5.2-build.patch + LICENSE) md5sums=('62f4f79c0861ad292ba3cf77b4c48319' + '25874b31f97a53f66ceed54f6b422515' '27a0d5a4d695e68b4d3eebe17db77189') +prepare() { + cd $pkgname-$pkgver + patch -Np0 -i ${srcdir}/compface-1.5.2-build.patch +} + build() { - cd $srcdir/$pkgname-$pkgver + cd $pkgname-$pkgver + CFLAGS="$CFLAGS -fPIC" ./configure --prefix=/usr make } package() { - cd $srcdir/$pkgname-$pkgver - make BINDIR=$pkgdir/usr/bin LIBDIR=$pkgdir/usr/lib MANDIR=$pkgdir/usr/share/man \ - INCLUDEDIR=$pkgdir/usr/include install + cd $pkgname-$pkgver + make DESTDIR="$pkgdir" STRIP=/bin/true install + install -D -m644 ../LICENSE $pkgdir/usr/share/licenses/$pkgname/LICENSE } diff --git a/extra/compface/compface-1.5.2-build.patch b/extra/compface/compface-1.5.2-build.patch new file mode 100644 index 000000000..b86cdb881 --- /dev/null +++ b/extra/compface/compface-1.5.2-build.patch @@ -0,0 +1,82 @@ +o Build shared library, link tools against it +o Make it possible to prevent stripping +o Add DESTDIR support + +--- Makefile.in~ 2005-10-04 15:59:49.000000000 +0300 ++++ Makefile.in 2006-08-02 22:23:07.000000000 +0300 +@@ -15,6 +15,7 @@ + INSTALL_PROGRAM = @INSTALL_PROGRAM@ + INSTALL_DATA = @INSTALL_DATA@ + SHELL = /bin/sh ++STRIP = strip + + NAME = compface + UNNAME = uncompface +@@ -25,6 +26,7 @@ + UNEXECUTABLE = $(BINDIR)/$(UNNAMEEXE) + LIBNAME = lib$(NAME).a + LIBRARY = $(LIBDIR)/$(LIBNAME) ++SHLIBNAME = lib$(NAME).so + MAN1DIR = $(MANDIR)/man1 + MAN3DIR = $(MANDIR)/man3 + OBJECTS = arith.o file.o compress.o gen.o uncompface.o +@@ -45,11 +47,11 @@ + + all: $(NAMEEXE) $(UNNAMEEXE) + +-$(NAMEEXE) : cmain.o compface.o $(LIBNAME) +- $(CC) $(LDFLAGS) -o $@ cmain.o compface.o $(LIBNAME) ++$(NAMEEXE) : cmain.o compface.o $(SHLIBNAME) ++ $(CC) $(LDFLAGS) -o $@ cmain.o compface.o -L. -l$(NAME) + +-$(UNNAMEEXE) : uncmain.o $(LIBNAME) +- $(CC) $(LDFLAGS) -o $@ uncmain.o $(LIBNAME) ++$(UNNAMEEXE) : uncmain.o $(SHLIBNAME) ++ $(CC) $(LDFLAGS) -o $@ uncmain.o -L. -l$(NAME) + + $(LIBNAME) : $(OBJECTS) + ar rc $(LIBNAME) $(OBJECTS) +@@ -73,25 +75,28 @@ + tar chzf `cat .fname`.tar.gz `cat .fname` + $(RM) -rf `cat .fname` .fname + +-install: $(NAMEEXE) $(UNNAMEEXE) $(LIBNAME) +- $(INSTALL_PROGRAM) -d $(BINDIR) $(LIBDIR) $(MAN1DIR) $(MAN3DIR) $(INCLUDEDIR) +- $(INSTALL_PROGRAM) $(srcdir)/$(NAMEEXE) $(EXECUTABLE) +- -chmod 0755 $(EXECUTABLE) +- -strip $(EXECUTABLE) +- $(INSTALL_PROGRAM) $(srcdir)/$(UNNAMEEXE) $(UNEXECUTABLE) +- -chmod 0755 $(UNEXECUTABLE) +- -strip $(UNEXECUTABLE) +- $(INSTALL_DATA) $(srcdir)/$(NAME).1 $(MAN1DIR)/$(NAME).1 +- cd $(MAN1DIR) && $(RM) ./$(UNNAME).1 && $(LN_S) $(NAME).1 $(UNNAME).1 +- $(INSTALL_DATA) $(srcdir)/$(NAME).3 $(MAN3DIR)/$(NAME).3 +- cd $(MAN3DIR) && $(RM) ./$(UNNAME).3 && $(LN_S) $(NAME).3 $(UNNAME).3 +- for hdr in $(INSTALLHEADERS); do $(INSTALL_DATA) $(srcdir)/$${hdr} $(INCLUDEDIR)/$${hdr}; done +- $(INSTALL_DATA) $(srcdir)/$(LIBNAME) $(LIBRARY) ++install: $(NAMEEXE) $(UNNAMEEXE) $(SHLIBNAME) ++ $(INSTALL_PROGRAM) -d $(DESTDIR)$(BINDIR) $(DESTDIR)$(LIBDIR) $(DESTDIR)$(MAN1DIR) $(DESTDIR)$(MAN3DIR) $(DESTDIR)$(INCLUDEDIR) ++ $(INSTALL_PROGRAM) $(srcdir)/$(NAMEEXE) $(DESTDIR)$(EXECUTABLE) ++ -$(STRIP) $(DESTDIR)$(EXECUTABLE) ++ $(INSTALL_PROGRAM) $(srcdir)/$(UNNAMEEXE) $(DESTDIR)$(UNEXECUTABLE) ++ -$(STRIP) $(DESTDIR)$(UNEXECUTABLE) ++ $(INSTALL_DATA) $(srcdir)/$(NAME).1 $(DESTDIR)$(MAN1DIR)/$(NAME).1 ++ cd $(DESTDIR)$(MAN1DIR) && $(RM) ./$(UNNAME).1 && $(LN_S) $(NAME).1 $(UNNAME).1 ++ $(INSTALL_DATA) $(srcdir)/$(NAME).3 $(DESTDIR)$(MAN3DIR)/$(NAME).3 ++ cd $(DESTDIR)$(MAN3DIR) && $(RM) ./$(UNNAME).3 && $(LN_S) $(NAME).3 $(UNNAME).3 ++ for hdr in $(INSTALLHEADERS); do $(INSTALL_DATA) $(srcdir)/$${hdr} $(DESTDIR)$(INCLUDEDIR)/$${hdr}; done ++ $(INSTALL_PROGRAM) $(srcdir)/$(SHLIBNAME) $(DESTDIR)$(LIBDIR)/$(SHLIBNAME).1.0.0 ++ $(LN_S) $(SHLIBNAME).1.0.0 $(DESTDIR)$(LIBDIR)/$(SHLIBNAME).1 ++ $(LN_S) $(SHLIBNAME).1 $(DESTDIR)$(LIBDIR)/$(SHLIBNAME) + + shar : + shar.script $(OTHERS) $(HDRS) $(SOURCES) > $(NAME).sh + compress $(NAME).sh + ++$(SHLIBNAME): $(OBJECTS) ++ $(CC) -shared -Wl,-soname,$(SHLIBNAME).1 $(LDFLAGS) -o $(SHLIBNAME) $(OBJECTS) ++ + .c.o: + $(CC) -c $(CPPFLAGS) $(DEFS) $(CFLAGS) $< + + |