pkgsrc/x11/wxGTK24/patches/patch-ac

79 lines
2.9 KiB
Text

$NetBSD: patch-ac,v 1.1.1.1 2005/08/07 11:27:29 wiz Exp $
--- src/makelib.env.in.orig 2003-09-21 13:31:38.000000000 +0200
+++ src/makelib.env.in
@@ -33,6 +33,7 @@ libdir = @libdir@
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
+INSTALL_DATA = @INSTALL_DATA_DIR@
TARGETLIB_STATIC = $(TARGET_LIBNAME).a
TARGETLIB_SHARED = $(TARGET_LIBNAME).so.$(LIBVERSION_CURRENT).$(LIBVERSION_REVISION).$(LIBVERSION_AGE)
@@ -47,13 +48,13 @@ LDFLAGS_VERSIONING = @LDFLAGS_VERSIONING
.SUFFIXES: .o .c .cpp .cxx
.c.o:
- $(CC) -c $(CFLAGS) $(PICFLAGS) -o $@ $<
+ ${LIBTOOL} --mode=compile $(CC) -c $(CFLAGS) -o $@ $<
.cpp.o:
- $(CXX) -c $(CXXFLAGS) $(PICFLAGS) -o $@ $<
+ ${LIBTOOL} --mode=compile $(CC) -c $(CXXFLAGS) $(CPPFLAGS) -o $@ $<
.cxx.o:
- $(CXX) -c $(CXXFLAGS) $(PICFLAGS) -o $@ $<
+ ${LIBTOOL} --mode=compile $(CC) -c $(CXXFLAGS) $(CPPFLAGS) -o $@ $<
# the comment at the end of the next line is needed because otherwise autoconf
# would remove this line completely - it contains a built-in hack to remove
@@ -62,40 +63,21 @@ VPATH = @PATH_IFS@$(top_srcdir)/$(libsrc
include $(top_builddir)/src/make.env
-all: libtype_@WX_TARGET_LIBRARY_TYPE@
+all: $(TARGET_LIBNAME).la
-libtype_so: $(top_builddir)/lib/$(TARGETLIB_SHARED)
-
-libtype_a: $(top_builddir)/lib/$(TARGETLIB_STATIC)
-
-$(top_builddir)/lib/$(TARGETLIB_SHARED): $(OBJECTS)
- @$(INSTALL) -d $(top_builddir)/lib
- $(SHARED_LD) $@ $(TARGETLIB_SONAME) $(OBJECTS) $(LDFLAGS_VERSIONING)
- cd $(top_builddir)/lib \
- && $(RM) $(TARGETLIB_LINK1) $(TARGETLIB_LINK2) \
- && $(LN_S) $(TARGETLIB_SHARED) $(TARGETLIB_LINK1) \
- && $(LN_S) $(TARGETLIB_SHARED) $(TARGETLIB_LINK2)
-
-$(top_builddir)/lib/$(TARGETLIB_STATIC): $(OBJECTS)
- @$(INSTALL) -d $(top_builddir)/lib
+$(TARGET_LIBNAME).la: $(OBJECTS)
+ @$(INSTALL_DATA_DIR) $(top_builddir)/lib
@$(RM) $@
- $(AR) $(AROPTIONS) $@ $(OBJECTS)
- $(RANLIB) $@
-
-install: install_@WX_TARGET_LIBRARY_TYPE@ install_headers
+ ${LIBTOOL} --mode=link cc -o ${.TARGET:.a=.la} ${OBJECTS:.o=.lo} \
+ -rpath ${PREFIX}/lib -version-info 0:1
-install_so:
- $(INSTALL_PROGRAM) $(top_builddir)/lib/$(TARGETLIB_SHARED) $(libdir)/$(TARGETLIB_SHARED)
- @$(RM) $(libdir)/$(TARGETLIB_LINK1) $(libdir)/$(TARGETLIB_LINK2)
- cd $(libdir) \
- && $(LN_S) $(TARGETLIB_SHARED) $(TARGETLIB_LINK1) \
- && $(LN_S) $(TARGETLIB_SHARED) $(TARGETLIB_LINK2)
+install: install_lib install_headers
-install_a:
- $(INSTALL_PROGRAM) $(top_builddir)/lib/$(TARGETLIB_STATIC) $(libdir)/$(TARGETLIB_STATIC)
+install_lib:
+ ${LIBTOOL} --mode=install ${BSD_INSTALL_DATA} ${TARGET_LIBNAME}.la ${PREFIX}/lib
install_headers:
- $(INSTALL) -d $(includedir)/wx/$(HEADER_SUBDIR)
+ $(INSTALL_DATA_DIR) $(includedir)/wx/$(HEADER_SUBDIR)
@for h in $(HEADERS); do \
$(INSTALL_DATA) $(HEADER_PATH)/$(HEADER_SUBDIR)/$$h $(includedir)/wx/$(HEADER_SUBDIR)/$$h; \
echo "installing $(includedir)/wx/$(HEADER_SUBDIR)/$$h"; \