pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/devel/pwlib Use SUBST framework. Readd some replacemen...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/6eecc9c63645
branches:  trunk
changeset: 505821:6eecc9c63645
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Sun Jan 08 04:57:55 2006 +0000

description:
Use SUBST framework. Readd some replacements in the mak files, since
they are installed and should work without the pkgsrc framework to
define e.g. LIBTOOL. Bump the revision for this.

Fix the inclusion in Makefiles by crudely faking the installation
directory layout. Remove some explicit casts which break with GCC 3.4
and OpenSSL 0.9.8, this might need to be conditionalized.
Add DraogonFly support and somewhat cleanup the FreeBSD sound includes.

diffstat:

 devel/pwlib/Makefile         |  26 +++++++++++++-----------
 devel/pwlib/distinfo         |  27 ++++++++++++++++++------
 devel/pwlib/patches/patch-aa |  13 ++++++++++-
 devel/pwlib/patches/patch-ab |  19 +++++++++++++----
 devel/pwlib/patches/patch-ad |  39 ++++++++++++++++++++++++++++++++---
 devel/pwlib/patches/patch-ae |  19 +++++++++++++++++
 devel/pwlib/patches/patch-ag |  24 ++++++++++++++++++++++
 devel/pwlib/patches/patch-ah |  18 ++++++++++++++++
 devel/pwlib/patches/patch-ai |  12 +++++-----
 devel/pwlib/patches/patch-ak |  18 ++++++++++++++++
 devel/pwlib/patches/patch-ao |  12 +++++++++++
 devel/pwlib/patches/patch-ap |  15 ++++++++++++++
 devel/pwlib/patches/patch-aq |  13 ++++++++++++
 devel/pwlib/patches/patch-ar |  15 ++++++++++++++
 devel/pwlib/patches/patch-as |  22 ++++++++++++++++++++
 devel/pwlib/patches/patch-at |  13 ++++++++++++
 devel/pwlib/patches/patch-au |  31 +++++++++++++++++++++++++++++
 devel/pwlib/patches/patch-av |  13 ++++++++++++
 devel/pwlib/patches/patch-aw |  13 ++++++++++++
 devel/pwlib/patches/patch-ba |  47 ++++++++++++++++++++++++++++++++++++++++++-
 devel/pwlib/patches/patch-bb |  37 ++++++++++++++++++++++++++++++---
 21 files changed, 404 insertions(+), 42 deletions(-)

diffs (truncated from 673 to 300 lines):

diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/Makefile
--- a/devel/pwlib/Makefile      Sun Jan 08 03:58:46 2006 +0000
+++ b/devel/pwlib/Makefile      Sun Jan 08 04:57:55 2006 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.48 2006/01/04 04:29:06 schmonz Exp $
+# $NetBSD: Makefile,v 1.49 2006/01/08 04:57:55 joerg Exp $
 
 DISTNAME=      pwlib-v1_8_3-src
 PKGNAME=       pwlib-1.8.3
-PKGREVISION=   1
+PKGREVISION=   2
 CATEGORIES=    devel
 MASTER_SITES+= http://www.voxgratia.org/releases/
 EXTRACT_SUFX=  -tar.gz
@@ -27,19 +27,20 @@
 BUILD_TARGET=          opt
 MAKE_ENV+=             PWLIBDIR=${WRKSRC:Q} CC=${CC:Q} CPLUS=${CXX:Q}
 
-FILES_SUBST+=          LIBTOOL=${LIBTOOL:Q}
-FILES_SUBST+=          PTHREADS_PREFIX="${BUILDLINK_PREFIX.pthread}"
+SUBST_CLASSES+=                paths
+SUBST_FILES.paths=     make/unix.mak make/lib.mak make/common.mak make/pwlib.mak
+SUBST_SED.paths+=      -e 's,@PREFIX@,${PREFIX},g'
+SUBST_SED.paths+=      -e 's,@LIBTOOL@,${LIBTOOL},g'
+SUBST_SED.paths+=      -e 's,@BSD_INSTALL_LIB@,${INSTALL_LIB},g'
+SUBST_SED.paths+=      -e 's,@BSD_INSTALL_PROGRAM@,${INSTALL_PROGRAM},g'
+SUBST_SED.paths+=      -e 's,@PTHREAD_FLAGS@,${PTHREAD_LDFLAGS} ${PTHREAD_LIBS},g'
+SUBST_SED.paths+=      -e 's,@LIBOSSAUDIO@,${LIBOSSAUDIO},g'
+SUBST_STAGE.paths=     post-patch
 
 post-extract:
        cd ${WRKDIR}; ${TAR} -xf ${DISTNAME:S/$/-tar/}
-
-post-patch:
-       ${_PKG_SILENT}cd ${WRKSRC}/make;                                \
-       for f in unix.mak lib.mak common.mak; do                        \
-               ${SED} ${FILES_SUBST_SED} $$f > $$f.sed;                \
-               ${MV} -f $$f.sed $$f;                                   \
-       done
-       ${LN} -sf ${WRKDIR} ${WRKSRC}/share
+       mkdir ${WRKSRC}/share
+       ${LN} -s ../../pwlib ${WRKSRC}/share/pwlib
 
 do-install:
        cd ${WRKSRC}/src/ptlib/unix && ${MAKE_ENV} ${GMAKE} install
@@ -57,5 +58,6 @@
        done
 
 .include "../../security/openssl/buildlink3.mk"
+.include "../../mk/ossaudio.buildlink3.mk"
 .include "../../mk/pthread.buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/distinfo
--- a/devel/pwlib/distinfo      Sun Jan 08 03:58:46 2006 +0000
+++ b/devel/pwlib/distinfo      Sun Jan 08 04:57:55 2006 +0000
@@ -1,18 +1,31 @@
-$NetBSD: distinfo,v 1.15 2005/09/06 08:10:57 abs Exp $
+$NetBSD: distinfo,v 1.16 2006/01/08 04:57:55 joerg Exp $
 
 SHA1 (pwlib-v1_8_3-src-tar.gz) = d3a6eff571ebfd37889e75cbaef75983e6119d2e
 RMD160 (pwlib-v1_8_3-src-tar.gz) = 1ce2544ef631c8344543e62988f97022c998bb05
 Size (pwlib-v1_8_3-src-tar.gz) = 1900922 bytes
-SHA1 (patch-aa) = f07517555dee8ba1a0b4ecad93aa36a57ae024b2
-SHA1 (patch-ab) = 7d7e09d5403a8b98c832e286eb8403d457164d0e
+SHA1 (patch-aa) = e8dc5e42fc758ec2a437caed47a29495b3017b5e
+SHA1 (patch-ab) = 597cbdcd050b4c0d20d8dee7358bbf5dbf3cf210
 SHA1 (patch-ac) = c0284e67ce689d774b715be4dc17214aa88c3d4a
-SHA1 (patch-ad) = 2d27b2485611f5e2ae304541d1b74a61d3498ffc
+SHA1 (patch-ad) = 37df314d226b8e5c420ac7d94fe6d700d7a9bda9
+SHA1 (patch-ae) = ebe340836c7456a355b4518789a49b7550766b06
 SHA1 (patch-af) = c38f646d75d57f17101ce42813f8e66232778447
-SHA1 (patch-ai) = 68e6b9ef55695a01193c1e77eb7960232311e695
+SHA1 (patch-ag) = bc08c8fc6d14021b1ebfab12d6ffb86404a588bb
+SHA1 (patch-ah) = fff6483f2a2f5864df57a6d90489846b5cc7ffdf
+SHA1 (patch-ai) = f0a9a80914dd4ae0f531c646001bce06c68e8e2f
 SHA1 (patch-aj) = 93e039bb60c5cb75abb916e2797c644b67a6b9b0
+SHA1 (patch-ak) = 74c9733c010c6620d7d6355afb8f482f7087a2b0
 SHA1 (patch-al) = 306d4e7882c1e717ae51f0eda70d08e89b40d20e
 SHA1 (patch-am) = 5b80fce03de136913dadfdbbdc161edef2f72919
 SHA1 (patch-an) = f79776e86d32bd15fd9f8fe1c0c02196ce4bcd3e
-SHA1 (patch-ba) = 4fb25dba8dc9143d7e655194894db1ee4221a1cf
-SHA1 (patch-bb) = b8ec2bb8616de4a7374604006aee4b79c7a0c716
+SHA1 (patch-ao) = 665d7c87476b8bb7afe3bdb1a892cf98f7bff8d2
+SHA1 (patch-ap) = 5f7d299cdd15e5c773ffdc4085be4466d70ca412
+SHA1 (patch-aq) = f590dad7d36d3926586f5158d3ae599fda38f554
+SHA1 (patch-ar) = f4c8b0141758613506a95e2fe0ce328c49898144
+SHA1 (patch-as) = 2764ccc5876bc15a7d56e4416742e951f418945a
+SHA1 (patch-at) = 87bbff9a5426c18c3e8407406b244eef2413cdbd
+SHA1 (patch-au) = 4947ee29e91c84f39a370ebc128c1e67737234d1
+SHA1 (patch-av) = 2bb533f6a29f10d357aed1b12c0bfc43af8a4f3b
+SHA1 (patch-aw) = 236cb19fc7f0b78055b0634b3821c099318abb9f
+SHA1 (patch-ba) = de2f2b6267a561e59951b4787d683c346953fe26
+SHA1 (patch-bb) = 03345fade582539c3b7332f14f1956686ad15289
 SHA1 (patch-bd) = 2d2fb1c6772a1e015cc1bceeb27fda39f57f5acc
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/patches/patch-aa
--- a/devel/pwlib/patches/patch-aa      Sun Jan 08 03:58:46 2006 +0000
+++ b/devel/pwlib/patches/patch-aa      Sun Jan 08 04:57:55 2006 +0000
@@ -1,4 +1,4 @@
-$NetBSD: patch-aa,v 1.7 2004/11/30 16:44:47 adam Exp $
+$NetBSD: patch-aa,v 1.8 2006/01/08 04:57:55 joerg Exp $
 
 --- make/unix.mak.orig 2004-11-16 00:32:34.000000000 +0000
 +++ make/unix.mak
@@ -7,7 +7,7 @@
  
  ifndef PWLIBDIR
 -PWLIBDIR = $(HOME)/pwlib
-+PWLIBDIR = /usr/pkg
++PWLIBDIR = @PREFIX@
  endif
  
  ####################################################
@@ -18,6 +18,15 @@
  
  ###############################################################################
  #
+@@ -309,7 +309,7 @@ release tagbuild
+ .PHONY: all $(STANDARD_TARGETS)
+ 
+ 
+-ifeq (,$(findstring $(OSTYPE),linux FreeBSD OpenBSD NetBSD solaris beos Darwin Carbon AIX Nucleus VxWorks rtems QNX cygwin))
++ifeq (,$(findstring $(OSTYPE),linux DragonFly FreeBSD OpenBSD NetBSD solaris beos Darwin Carbon AIX Nucleus VxWorks rtems QNX cygwin))
+ 
+ default_target :
+       @echo
 @@ -433,9 +433,9 @@ endif # FreeBSD
  
  ifeq ($(OSTYPE),OpenBSD)
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/patches/patch-ab
--- a/devel/pwlib/patches/patch-ab      Sun Jan 08 03:58:46 2006 +0000
+++ b/devel/pwlib/patches/patch-ab      Sun Jan 08 04:57:55 2006 +0000
@@ -1,8 +1,17 @@
-$NetBSD: patch-ab,v 1.7 2004/10/09 14:01:03 mjl Exp $
+$NetBSD: patch-ab,v 1.8 2006/01/08 04:57:55 joerg Exp $
 
 --- make/lib.mak.orig  2004-06-17 08:33:07.000000000 +0200
 +++ make/lib.mak       2004-10-09 14:49:04.000000000 +0200
-@@ -200,22 +200,18 @@
+@@ -175,7 +175,7 @@ ifeq ($(P_SHAREDLIB),1)
+   endif
+ 
+   ifneq ($(OSTYPE), QNX)
+-    ifneq (,$(findstring $(OSTYPE),FreeBSD OpenBSDs))
++    ifneq (,$(findstring $(OSTYPE),FreeBSD OpenBSD DragonFly))
+       ifdef P_PTHREADS
+         EXTLIBS += -pthread
+       endif
+@@ -200,22 +200,18 @@ ifeq ($(P_SHAREDLIB),1)
      LD = $(CPLUS)
    endif
  
@@ -10,7 +19,7 @@
 -      cd $(LIBDIR) ; rm -f $(LIB_FILENAME) ; ln -sf $(LIBNAME_PAT) $(LIB_FILENAME)
 -      cd $(LIBDIR) ; rm -f $(LIBNAME_MAJ) ;  ln -sf $(LIBNAME_PAT) $(LIBNAME_MAJ)
 -      cd $(LIBDIR) ; rm -f $(LIBNAME_MIN) ;  ln -sf $(LIBNAME_PAT) $(LIBNAME_MIN)
-+  ENDLDLIBS += -L$(PREFIX)/lib -lpthread -lossaudio
++  ENDLDLIBS += -L$(PREFIX)/lib @PTHREAD_FLAGS@ @LIBOSSAUDIO@
  
 -  $(LIBDIR)/$(LIBNAME_PAT): $(STATIC_LIB_FILE)
 +  $(LIBDIR)/$(LIB_FILENAME): $(OBJS)
@@ -18,7 +27,7 @@
        @echo SYSLIBS = $(SYSLIBS)
        @if [ ! -d $(LIBDIR) ] ; then mkdir $(LIBDIR) ; fi
 -      $(LD) $(LDSOOPTS) -o $(LIBDIR)/$(LIBNAME_PAT) $(LDFLAGS) $(EXTLIBS) $(OBJS) $(ENDLDLIBS)
-+      $(LIBTOOL) --tag=CXX --mode=link $(CPLUS) -o $(LIBDIR)/$(LIB_FILENAME) \
++      @LIBTOOL@ --tag=CXX --mode=link $(CPLUS) -o $(LIBDIR)/$(LIB_FILENAME) \
 +              $(OBJS:.o=.lo) $(EXTLIBS) $(ENDLDLIBS) -rpath $(INSTALLLIB_DIR) \
 +              -release $(MAJOR_VERSION).$(MINOR_VERSION).$(BUILD_NUMBER)
  
@@ -28,7 +37,7 @@
 -      ln -sf $(LIBNAME_PAT) $(INSTALLLIB_DIR)/$(LIBNAME_MAJ)
 -      ln -sf $(LIBNAME_PAT) $(INSTALLLIB_DIR)/$(LIBNAME_MIN)
 +  install: $(LIBDIR)/$(LIB_FILENAME)
-+      $(LIBTOOL) --mode=install install $(LIBDIR)/$(LIB_FILENAME) $(INSTALLLIB_DIR)/$(LIB_FILENAME)
++      @LIBTOOL@ --mode=install @BSD_INSTALL_LIB@ $(LIBDIR)/$(LIB_FILENAME) $(INSTALLLIB_DIR)/$(LIB_FILENAME)
  
  endif # P_SHAREDLIB
  
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/patches/patch-ad
--- a/devel/pwlib/patches/patch-ad      Sun Jan 08 03:58:46 2006 +0000
+++ b/devel/pwlib/patches/patch-ad      Sun Jan 08 04:57:55 2006 +0000
@@ -1,9 +1,13 @@
-$NetBSD: patch-ad,v 1.5 2005/09/06 08:10:57 abs Exp $
+$NetBSD: patch-ad,v 1.6 2006/01/08 04:57:55 joerg Exp $
 
---- src/ptlib/unix/osutil.cxx.orig     2004-09-23 07:00:10.000000000 +0200
+--- src/ptlib/unix/osutil.cxx.orig     2004-09-23 05:00:10.000000000 +0000
 +++ src/ptlib/unix/osutil.cxx
-@@ -243,8 +243,13 @@
- #elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS)
+@@ -240,11 +240,16 @@
+ #define P_USE_LANGINFO
+ #endif
+ 
+-#elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS)
++#elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS) || defined(P_DRAGONFLY)
  #define P_USE_STRFTIME
  
 +#if defined(__NetBSD__) && __NetBSD_Version__ > 299000900
@@ -16,3 +20,30 @@
  
  #elif defined(P_HPUX9) 
  #define P_USE_LANGINFO
+@@ -685,7 +690,7 @@ PString PDirectory::GetVolume() const
+     }
+     fclose(fp);
+ 
+-#elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS)
++#elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS) || defined(P_DRAGONFLY)
+ 
+     struct statfs * mnt;
+     int count = getmntinfo(&mnt, MNT_NOWAIT);
+@@ -725,7 +730,7 @@ PString PDirectory::GetVolume() const
+ 
+ BOOL PDirectory::GetVolumeSpace(PInt64 & total, PInt64 & free, DWORD & clusterSize) const
+ {
+-#if defined(P_LINUX) || defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS)
++#if defined(P_LINUX) || defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS) || defined(P_DRAGONFLY)
+ 
+   struct statfs fs;
+ 
+@@ -1588,7 +1593,7 @@ int PTime::GetTimeZone(PTime::TimeZoneTy
+     return tz;
+   else
+     return tz + ::daylight*60;
+-#elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS) || defined(__BEOS__) || defined(P_QNX)
++#elif defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_MACOSX) || defined(P_MACOS) || defined(__BEOS__) || defined(P_QNX) || defined(P_DRAGONFLY)
+   time_t t;
+   time(&t);
+   struct tm ts;
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/patches/patch-ae
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/pwlib/patches/patch-ae      Sun Jan 08 04:57:55 2006 +0000
@@ -0,0 +1,19 @@
+$NetBSD: patch-ae,v 1.4 2006/01/08 04:57:55 joerg Exp $
+
+--- configure.orig     2006-01-08 03:13:16.000000000 +0000
++++ configure
+@@ -2059,6 +2059,14 @@ case "$target_os" in
+                    need_pragma=yes ;
+                  ;;
+ 
++  dragonfly* )     OSTYPE=DragonFly ;
++                 OS_TAG="P_DRAGONFLY" ;
++                   if test "x$OSRELEASE" = "x"; then
++                     OSRELEASE="`sysctl -n kern.osreldate`" ;
++                   fi
++                   need_pragma=yes ;
++                 ;;
++
+   openbsd* )       OSTYPE=OpenBSD ;
+                  OS_TAG="P_OPENBSD" ;
+                    OSRELEASE="`sysctl -n kern.osrevision`" ;
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/patches/patch-ag
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/pwlib/patches/patch-ag      Sun Jan 08 04:57:55 2006 +0000
@@ -0,0 +1,24 @@
+$NetBSD: patch-ag,v 1.5 2006/01/08 04:57:55 joerg Exp $
+
+--- include/ptlib/unix/ptlib/videoio.h.orig    2006-01-08 03:14:38.000000000 +0000
++++ include/ptlib/unix/ptlib/videoio.h
+@@ -110,6 +110,10 @@
+ #include <machine/ioctl_meteor.h>
+ #endif
+ 
++#if defined(P_DRAGONFLY)
++#include <dev/video/meteor/ioctl_meteor.h>
++#endif
++
+ #if defined(P_OPENBSD) || defined(P_NETBSD)
+ #if P_OPENBSD >= 200105
+ #include <dev/ic/bt8xx.h> 
+@@ -178,7 +182,7 @@
+     struct video_mmap frameBuffer[2];
+ #endif
+ 
+-#if defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD)
++#if defined(P_FREEBSD) || defined(P_OPENBSD) || defined(P_NETBSD) || defined(P_DRAGONFLY)
+     struct video_capability
+     {
+         int channels;   /* Num channels */
diff -r 4fcc4712c0f9 -r 6eecc9c63645 devel/pwlib/patches/patch-ah
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/pwlib/patches/patch-ah      Sun Jan 08 04:57:55 2006 +0000
@@ -0,0 +1,18 @@
+$NetBSD: patch-ah,v 1.3 2006/01/08 04:57:55 joerg Exp $
+
+--- plugins/sound_oss/sound_oss.h.orig 2006-01-08 03:46:00.000000000 +0000
++++ plugins/sound_oss/sound_oss.h
+@@ -11,12 +11,8 @@
+ #include <sys/soundcard.h>
+ #endif
+ 
+-#ifdef P_FREEBSD
+-#if P_FREEBSD >= 500000
++#if defined(P_FREEBSD) || defined(P_DRAGONFLY)
+ #include <sys/soundcard.h>
+-#else
+-#include <machine/soundcard.h>
+-#endif



Home | Main Index | Thread Index | Old Index