summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkwm <kwm@df743ca5-7f9a-e211-a948-0013205c9059>2013-11-13 06:27:59 +0800
committerkwm <kwm@df743ca5-7f9a-e211-a948-0013205c9059>2013-11-13 06:27:59 +0800
commit8778a2c3a9f10dc9f1aa01523b2fda8b788985d1 (patch)
treea8f4a23bd01804b447753b738275f99d93b16eef
parenta5e6ac38a256fb28986ec9b5a5f7fb2b898b644d (diff)
downloadmarcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.tar
marcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.tar.gz
marcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.tar.bz2
marcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.tar.lz
marcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.tar.xz
marcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.tar.zst
marcuscom-ports-8778a2c3a9f10dc9f1aa01523b2fda8b788985d1.zip
Remove ltverhack's hard depend on USE_AUTOTOOLS=libtool. If
USE_AUTOTOOLS=libtool is defined it will restore the old behaviour. The problem with the old situation was that it used libtool from LOCALBASE and that libtool is configured to look in LOCALBASE first for linking. This causes problems if the port you working on as API additions [1] which don't exists in the installed version. The new method is to apply our library version hack to the shipped ltmain.sh which will renerate a correct libtool for us. [1] This happend while trying to build the introspection files for the Gstreamer 1.2 update, where libtool would link in the old installed libraries and causing the build to fail with unresolved symbols. This problem has been around for a long time but now I managed to track it now. By actualy goofing up, and stumbeling into this :) git-svn-id: svn://creme-brulee.marcuscom.com/ports/trunk@18886 df743ca5-7f9a-e211-a948-0013205c9059
-rw-r--r--Mk/bsd.gnome.mk23
1 files changed, 16 insertions, 7 deletions
diff --git a/Mk/bsd.gnome.mk b/Mk/bsd.gnome.mk
index e6fcbcc7f..2c4de4b70 100644
--- a/Mk/bsd.gnome.mk
+++ b/Mk/bsd.gnome.mk
@@ -734,12 +734,12 @@ lthacks_PRE_PATCH= \
for file in ${LIBTOOLFILES}; do \
${REINPLACE_CMD} -e \
'/^ltmain=/!s|$$ac_aux_dir/ltmain\.sh|${LIBTOOLFLAGS} ${WRKDIR}/gnome-ltmain.sh|g; \
- /^LIBTOOL=/s|$$(top_builddir)/libtool|${WRKDIR}/gnome-libtool|g' \
+ /^LIBTOOL=/s|$$(top_builddir)/libtool|${WRKDIR}/gnome-libtool|g' \
${PATCH_WRKSRC}/$$file; \
done;
.else
-. if ${USE_GNOME:Mltverhack*}!="" || ${USE_GNOME:Mltasneededhack}!=""
-IGNORE= cannot install: ${PORTNAME} uses the ltverhack and/or ltasneededhack GNOME components but does not use libtool
+. if ${USE_GNOME:Mltasneededhack}!=""
+IGNORE= cannot install: ${PORTNAME} uses the ltasneededhack GNOME component but does not use libtool
. endif
.endif
@@ -748,14 +748,21 @@ ltverhack_LIB_VERSION= major=.`expr $$current - $$age`
.else
ltverhack_LIB_VERSION= major=".${USE_GNOME:Mltverhack\:*:C/^[^:]+:([^:]+).*/\1/}"
.endif
+
+.if defined(USE_AUTOTOOLS) && ${USE_AUTOTOOLS:Mlibtool*}
ltverhack_PATCH_DEPENDS=${LIBTOOL_DEPENDS}
+ltverhack_PATCH_FILES= ../gnome-ltmain.sh ../gnome-libtool
+.else
+ltverhack_PATCH_FILES= ltmain.sh libtool
+.endif
+
ltverhack_PRE_PATCH= \
- for file in gnome-ltmain.sh gnome-libtool; do \
- if [ -f ${WRKDIR}/$$file ]; then \
+ for file in ${ltverhack_PATCH_FILES}; do \
+ if [ -f ${WRKSRC}/$$file ]; then \
${REINPLACE_CMD} -e \
'/freebsd-elf)/,/;;/ s|major="\.$$current"|${ltverhack_LIB_VERSION}|; \
/freebsd-elf)/,/;;/ s|versuffix="\.$$current"|versuffix="$$major"|' \
- ${WRKDIR}/$$file; \
+ ${WRKSRC}/$$file; \
fi; \
done
@@ -776,7 +783,9 @@ USE_CSTD= gnu89
# Then traverse through all components, check which of them
# exist in ${_USE_GNOME} and set variables accordingly
.ifdef _USE_GNOME
-. if ${USE_GNOME:Mltverhack*}!= "" || ${USE_GNOME:Mltasneededhack}!= ""
+
+. if ${USE_GNOME:Mltasneededhack}!= "" || (${USE_GNOME:Mltverhack*}!= "" && \
+ defined(USE_AUTOTOOLS) && ${USE_AUTOTOOLS:Mlibtool*})
GNOME_PRE_PATCH+= ${lthacks_PRE_PATCH}
CONFIGURE_ENV+= ${lthacks_CONFIGURE_ENV}
. endif