pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/x11/libXp Allow using libXp with xsrc for NetBSD/current.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/86527f8b38a8
branches:  trunk
changeset: 397920:86527f8b38a8
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Thu Aug 20 17:59:10 2009 +0000

description:
Allow using libXp with xsrc for NetBSD/current.

diffstat:

 x11/libXp/Makefile      |  10 +++++++++-
 x11/libXp/buildlink3.mk |  10 +---------
 x11/libXp/builtin.mk    |  41 +++++++++++++++++++++++++++++++++++++++++
 3 files changed, 51 insertions(+), 10 deletions(-)

diffs (90 lines):

diff -r 06402e8d9188 -r 86527f8b38a8 x11/libXp/Makefile
--- a/x11/libXp/Makefile        Thu Aug 20 17:52:40 2009 +0000
+++ b/x11/libXp/Makefile        Thu Aug 20 17:59:10 2009 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 2008/05/24 21:45:15 tnn Exp $
+# $NetBSD: Makefile,v 1.4 2009/08/20 17:59:10 joerg Exp $
 #
 
 DISTNAME=              libXp-1.0.0
@@ -25,6 +25,14 @@
 CONFIGURE_ARGS+=       --disable-malloc0returnsnull
 .endif
 
+.if ${X11_TYPE} == "native"
+XPRINT_CFLAGS= -I${X11BASE}/include
+XPRINT_LIBS=   -Wl,-rpath,${X11BASE}/lib -L${X11BASE}/lib -lX11 -lXext -lXau
+
+CONFIGURE_ARGS+=       XPRINT_CFLAGS=${XPRINT_CFLAGS:Q} \
+                       XPRINT_LIBS=${XPRINT_LIBS:Q}
+.endif
+
 .include "../../x11/libX11/buildlink3.mk"
 .include "../../x11/libXext/buildlink3.mk"
 .include "../../x11/printproto/buildlink3.mk"
diff -r 06402e8d9188 -r 86527f8b38a8 x11/libXp/buildlink3.mk
--- a/x11/libXp/buildlink3.mk   Thu Aug 20 17:52:40 2009 +0000
+++ b/x11/libXp/buildlink3.mk   Thu Aug 20 17:59:10 2009 +0000
@@ -1,10 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.3 2009/03/20 19:25:45 joerg Exp $
-
-.include "../../mk/bsd.fast.prefs.mk"
-
-.if ${X11_TYPE} != "modular"
-.include "../../mk/x11.buildlink3.mk"
-.else
+# $NetBSD: buildlink3.mk,v 1.4 2009/08/20 17:59:10 joerg Exp $
 
 BUILDLINK_TREE+=       libXp
 
@@ -20,5 +14,3 @@
 .endif # LIBXP_BUILDLINK3_MK
 
 BUILDLINK_TREE+=       -libXp
-
-.endif
diff -r 06402e8d9188 -r 86527f8b38a8 x11/libXp/builtin.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/x11/libXp/builtin.mk      Thu Aug 20 17:59:10 2009 +0000
@@ -0,0 +1,41 @@
+# $NetBSD: builtin.mk,v 1.1 2009/08/20 17:59:10 joerg Exp $
+
+BUILTIN_PKG:=  libXp
+
+BUILTIN_FIND_FILES_VAR:=       H_PRINTPROTO
+BUILTIN_FIND_FILES.H_PRINTPROTO= ${X11BASE}/include/X11/extensions/Print.h
+
+.include "../../mk/buildlink3/bsd.builtin.mk"
+
+###
+### Determine if there is a built-in implementation of the package and
+### set IS_BUILTIN.<pkg> appropriately ("yes" or "no").
+###
+.if ${X11BASE} == ${LOCALBASE}
+IS_BUILTIN.libXp=      no
+.elif !defined(IS_BUILTIN.libXp)
+IS_BUILTIN.libXp=      no
+.  if empty(H_PRINTPROTO:M__nonexistent__)
+IS_BUILTIN.libXp=      yes
+.  endif
+.endif
+MAKEVARS+=     IS_BUILTIN.libXp
+
+###
+### Determine whether we should use the built-in implementation if it
+### exists, and set USE_BUILTIN.<pkg> appropriate ("yes" or "no").
+###
+.if !defined(USE_BUILTIN.libXp)
+.  if ${PREFER.libXp} == "pkgsrc"
+USE_BUILTIN.libXp=     no
+.  else
+USE_BUILTIN.libXp=     ${IS_BUILTIN.libXp}
+.    if defined(BUILTIN_PKG.libXp) && \
+        !empty(IS_BUILTIN.libXp:M[yY][eE][sS])
+USE_BUILTIN.libX11=    yes
+.    endif
+.  endif  # PREFER.libXp
+.endif
+MAKEVARS+=     USE_BUILTIN.libXp
+
+.include "../../mk/x11.builtin.mk"



Home | Main Index | Thread Index | Old Index