# # Makefile for pwlib Slackware package # Copyright (c) 2003 by Robert Stan # PROGNAME = pwlib VERSION = 1.6.6 ARCH = i486 BUILD = 1rob SOURCE = http://heanet.dl.sourceforge.net/sourceforge/openh323/pwlib-v1_6_6-1-src.tar.gz DOCS = *.txt *.htm CUSTNAME = $(PROGNAME) PKGNAME = $(CUSTNAME)-$(VERSION)-$(ARCH)-$(BUILD) MAINTAINER = Robert Stan CFLAGS = "-O2 -pipe -march=$(ARCH) -mcpu=i686" CXXFLAGS = $(CFLAGS) STRIPLIB = y STRIPBIN = y TMP = /var/tmp PKG = $(TMP)/package-$(PROGNAME)-$(VERSION) ren: ln -sf pwlib-v1_6_6-1-src.tar.gz pwlib-1.6.6.tar.gz || true conf: ren prep mv $(PROGNAME) $(PROGNAME)-$(VERSION) cd $(PROGNAME)-$(VERSION); \ patch -p1 < ../pwlib-1.6.3-libname.patch; \ patch -p1 < ../pwlib-1.6.3-make_j.patch; \ patch -p1 < ../pwlib-1.4.7-bison.patch; \ cp -f ../config.guess . ;\ autoconf; \ CFLAGS=$(CFLAGS) CXXFLAGS=$(CXXFLAGS) \ ./configure --prefix=/usr \ --libdir=/usr/lib \ --sysconfdir=/etc \ --enable-plugins \ --enable-shared \ --disable-static build: conf cd $(PROGNAME)-$(VERSION); \ make -j10 OPTCCFLAGS=$(CFLAGS) package: build mkdir -p $(PKG)/usr/{bin,lib} mkdir -p $(PKG)/usr/doc/$(PROGNAME)-$(VERSION) cd $(PROGNAME)-$(VERSION); \ cp -a $(DOCS) $(PKG)/usr/doc/$(PROGNAME)-$(VERSION); \ make PREFIX=$(PKG)/usr LIBDIR=$(PKG)/usr/lib install #ln -s /usr/bin/ptlib-config $(PKG)/usr/share/pwlib/make/ rm -rf $(PKG)/usr/include/CVS rm -rf $(PKG)/usr/include/ptclib/CVS rm -rf $(PKG)/usr/include/ptlib/CVS rm -rf $(PKG)/usr/include/ptlib/msos/CVS rm -rf $(PKG)/usr/include/ptlib/wince/CVS rm -rf $(PKG)/usr/include/ptlib/wince/sys/CVS rm -rf $(PKG)/usr/include/ptlib/unix/CVS rm -rf $(PKG)/usr/include/ptlib/unix/ptlib/CVS rm -rf $(PKG)/usr/share/pwlib/make/CVS perl -pi -e 's@PWLIBDIR.*=.*@PWLIBDIR = /usr/share/pwlib@' $(PKG)/usr/share/pwlib/make/ptbuildopts.mak STRIPLIB=$(STRIPLIB) STRIPBIN=$(STRIPBIN) ../../preparepkg $(PKG) cat slack-desc > ../$(PKGNAME).txt cat slack-desc > $(PKG)/install/slack-desc cat slack-required > $(PKG)/install/slack-required cd $(PKG) ; makepkg -l y -c n $(PKGNAME).tgz mv $(PKG)/$(PKGNAME).tgz .. include ../../Makefile.global