summaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authortron <tron@pkgsrc.org>2003-03-13 07:01:01 +0000
committertron <tron@pkgsrc.org>2003-03-13 07:01:01 +0000
commit8ba42278c53eb139dfa99837b8afea33003fd249 (patch)
tree5a3e4aabeb88bb73ebd39ac5ded90cbd4f5a5c6c /graphics
parentbb3981365b86b2382ea5dffb129d4f94a595b33d (diff)
downloadpkgsrc-8ba42278c53eb139dfa99837b8afea33003fd249.tar.gz
Create fake libtool archives to fix build problems on XFree86 4.x system
when programs are supposed to be linked with the included Mesa libraries. These changes by Johnny C. Lam fix PR pkg/20649 by myself.
Diffstat (limited to 'graphics')
-rw-r--r--graphics/MesaLib/buildlink2.mk16
-rw-r--r--graphics/glu/buildlink2.mk16
2 files changed, 30 insertions, 2 deletions
diff --git a/graphics/MesaLib/buildlink2.mk b/graphics/MesaLib/buildlink2.mk
index c4958ccde95..c042a75e7da 100644
--- a/graphics/MesaLib/buildlink2.mk
+++ b/graphics/MesaLib/buildlink2.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink2.mk,v 1.8 2003/03/09 19:04:53 jschauma Exp $
+# $NetBSD: buildlink2.mk,v 1.9 2003/03/13 07:01:01 tron Exp $
.if !defined(MESALIB_BUILDLINK2_MK)
MESALIB_BUILDLINK2_MK= # defined
@@ -63,6 +63,13 @@ BUILDLINK_PREFIX.MesaLib_DEFAULT= ${LOCALBASE}
BUILDLINK_PREFIX.MesaLib= ${X11BASE}
.endif
+.if ${_NEED_MESALIB} == "NO"
+_BLNK_MESALIB_LDFLAGS= -L${BUILDLINK_PREFIX.MesaLib}/lib -lGL
+LIBTOOL_ARCHIVE_UNTRANSFORM_SED+= \
+ -e "s|${BUILDLINK_PREFIX.MesaLib}/lib/libGL.la|${_BLNK_MESALIB_LDFLAGS}|g" \
+ -e "s|${LOCALBASE}/lib/libGL.la|${_BLNK_MESALIB_LDFLAGS}|g"
+.endif
+
BUILDLINK_FILES.MesaLib+= include/GL/GL*.h
BUILDLINK_FILES.MesaLib+= include/GL/gl.h
BUILDLINK_FILES.MesaLib+= include/GL/glext.h
@@ -77,7 +84,14 @@ BUILDLINK_FILES.MesaLib+= lib/libGL.*
USE_X11= # defined
BUILDLINK_TARGETS+= MesaLib-buildlink
+BUILDLINK_TARGETS+= MesaLib-libGL-la
MesaLib-buildlink: _BUILDLINK_USE
+MesaLib-libGL-la:
+ ${_PKG_SILENT}${_PKG_DEBUG} \
+ lafile="${BUILDLINK_DIR}/lib/libGL.la"; \
+ libpattern="${BUILDLINK_PREFIX.MesaLib}/lib/libGL.*"; \
+ ${BUILDLINK_FAKE_LA}
+
.endif # MESALIB_BUILDLINK2_MK
diff --git a/graphics/glu/buildlink2.mk b/graphics/glu/buildlink2.mk
index 3c11dc57db4..1d1ae05ef72 100644
--- a/graphics/glu/buildlink2.mk
+++ b/graphics/glu/buildlink2.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink2.mk,v 1.8 2003/03/09 19:04:54 jschauma Exp $
+# $NetBSD: buildlink2.mk,v 1.9 2003/03/13 07:01:03 tron Exp $
.if !defined(GLU_BUILDLINK2_MK)
GLU_BUILDLINK2_MK= # defined
@@ -61,6 +61,13 @@ BUILDLINK_PREFIX.glu_DEFAULT= ${LOCALBASE}
BUILDLINK_PREFIX.glu= ${X11BASE}
.endif
+.if ${_NEED_GLU} == "NO"
+_BLNK_GLU_LDFLAGS= -L${BUILDLINK_PREFIX.glu}/lib -lGLU
+LIBTOOL_ARCHIVE_UNTRANSFORM_SED+= \
+ -e "s|${BUILDLINK_PREFIX.glu}/lib/libGLU.la|${_BLNK_GLU_LDFLAGS}|g" \
+ -e "s|${LOCALBASE}/lib/libGLU.la|${_BLNK_GLU_LDFLAGS}|g"
+.endif
+
BUILDLINK_FILES.glu= include/GL/glu.h
BUILDLINK_FILES.glu+= include/GL/glu_mangle.h
BUILDLINK_FILES.glu+= lib/libGLU.*
@@ -70,7 +77,14 @@ USE_X11= # defined
.include "../../graphics/MesaLib/buildlink2.mk"
BUILDLINK_TARGETS+= glu-buildlink
+BUILDLINK_TARGETS+= glu-libGLU-la
glu-buildlink: _BUILDLINK_USE
+glu-libGLU-la:
+ ${_PKG_SILENT}${_PKG_DEBUG} \
+ lafile="${BUILDLINK_DIR}/lib/libGLU.la"; \
+ libpattern="${BUILDLINK_PREFIX.glu}/lib/libGLU.*"; \
+ ${BUILDLINK_FAKE_LA}
+
.endif # GLU_BUILDLINK2_MK