pkgsrc/devel/pwlib/patches/patch-aa
joerg cd1ee1d986 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.
2006-01-08 04:57:55 +00:00

107 lines
2.5 KiB
Text

$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
@@ -128,13 +128,13 @@
#
ifndef PWLIBDIR
-PWLIBDIR = $(HOME)/pwlib
+PWLIBDIR = @PREFIX@
endif
####################################################
# include generated build options file, then include it
-include $(PWLIBDIR)/make/ptbuildopts.mak
+include $(PWLIBDIR)/share/pwlib/make/ptbuildopts.mak
###############################################################################
#
@@ -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)
-ifeq ($(MACHTYPE),x86)
-STDCCFLAGS += -m486
-endif
+# ifeq ($(MACHTYPE),x86)
+# STDCCFLAGS += -m486
+# endif
LDLIBS += -lossaudio
@@ -450,13 +450,9 @@ endif # OpenBSD
ifeq ($(OSTYPE),NetBSD)
-ifeq ($(MACHTYPE),x86)
-STDCCFLAGS += -m486
-endif
-
LDLIBS += -lossaudio
-STDCCFLAGS += -I$(UNIX_INC_DIR) -I$(PWLIBDIR)/include
+STDCCFLAGS += -I$(PWLIBDIR)/include
# enable the USE_PTH line to compile using pth
# enable the USE_NATIVE_THREADS line to compile using native threads
@@ -837,13 +833,14 @@ STATICLIBEXT = a
endif
ifeq ($(P_SHAREDLIB),1)
-LIB_SUFFIX = $(SHAREDLIBEXT)
+LIB_SUFFIX = la
LIB_TYPE =
else
LIB_SUFFIX = a
-LIB_TYPE = _s
+LIB_TYPE =
endif # P_SHAREDLIB
+INSTALL_DIR = ${PREFIX}
ifndef INSTALL_DIR
INSTALL_DIR = /usr/local
endif
@@ -870,11 +867,11 @@ SHELL := /bin/sh
# Directories
-ifdef PREFIX
-UNIX_INC_DIR = $(PREFIX)/include/ptlib/unix
-else
+#ifdef PREFIX
+#UNIX_INC_DIR = $(PREFIX)/include/ptlib/unix
+#else
UNIX_INC_DIR = $(PWLIBDIR)/include/ptlib/unix
-endif
+#endif
ifndef UNIX_SRC_DIR
UNIX_SRC_DIR = $(PWLIBDIR)/src/ptlib/unix
@@ -883,7 +880,7 @@ endif
PW_LIBDIR = $(PWLIBDIR)/lib
# set name of the PT library
-PTLIB_BASE = pt_$(PLATFORM_TYPE)_$(OBJ_SUFFIX)
+PTLIB_BASE = pt
PTLIB_FILE = lib$(PTLIB_BASE)$(LIB_TYPE).$(LIB_SUFFIX)
PT_OBJBASE = obj_$(PLATFORM_TYPE)_$(OBJDIR_SUFFIX)
PT_OBJDIR = $(PW_LIBDIR)/$(PT_OBJBASE)
@@ -951,6 +948,6 @@ endif
# add library directory to library path and include the library
LDFLAGS += -L$(PW_LIBDIR)
-LDLIBS += -l$(PTLIB_BASE)$(LIB_TYPE)
+LDLIBS += $(PW_LIBDIR)/$(PTLIB_FILE)
# End of unix.mak