pkgsrc-Changes archive

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

CVS commit: pkgsrc/x11/motif



Module Name:    pkgsrc
Committed By:   riastradh
Date:           Sat Apr 16 10:39:51 UTC 2022

Modified Files:
        pkgsrc/x11/motif: Makefile distinfo
        pkgsrc/x11/motif/patches: patch-tools_wml_Makefile.in

Log Message:
x11/motif: Work around quirks in build-time tool-building.

See comments for details.  Tidy up variable definitions while here.
Use native ar/ranlib if available -- armv7--netbsdelf-eabihf-ranlib
doesn't seem to do anything on an archive of x86 objects to build a
tool library, so let's try using the native one instead for such a
cross-build.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 pkgsrc/x11/motif/Makefile
cvs rdiff -u -r1.13 -r1.14 pkgsrc/x11/motif/distinfo
cvs rdiff -u -r1.1 -r1.2 pkgsrc/x11/motif/patches/patch-tools_wml_Makefile.in

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/x11/motif/Makefile
diff -u pkgsrc/x11/motif/Makefile:1.20 pkgsrc/x11/motif/Makefile:1.21
--- pkgsrc/x11/motif/Makefile:1.20      Mon Apr 11 09:04:51 2022
+++ pkgsrc/x11/motif/Makefile   Sat Apr 16 10:39:50 2022
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.20 2022/04/11 09:04:51 nia Exp $
+# $NetBSD: Makefile,v 1.21 2022/04/16 10:39:50 riastradh Exp $
 
 DISTNAME=              motif-2.3.8
 PKGREVISION=           1
@@ -48,16 +48,41 @@ CONFIGURE_ARGS+=    --enable-xft
 CFLAGS.SunOS+=         -D_POSIX_PTHREAD_SEMANTICS
 
 MAKE_FLAGS+=           CC_FOR_BUILD=${NATIVE_CC:Q:U${CC:Q}}
+MAKE_FLAGS+=           AR_FOR_BUILD=${NATIVE_AR:Q:U${AR:Q}}
+MAKE_FLAGS+=           RANLIB_FOR_BUILD=${NATIVE_RANLIB:Q:U${RANLIB:Q}}
+MAKE_FLAGS+=           CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD:Q}
+MAKE_FLAGS+=           LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD:Q}
 MAKE_FLAGS+=           LIBS_FOR_BUILD=-lXt
 
+# wml.c has
+#
+#      #ifdef HAVE_CONFIG_H
+#      #include <config.h>
+#      #endif
+#      ...
+#      #ifdef HAVE_FCNTL_H
+#      #include <fcntl.h>
+#      #else
+#      #include <sys/file.h>
+#      #endif
+#
+# Using config.h doesn't make sense for cross-builds because it
+# describes the target system, not the native system.  But <fcntl.h> is
+# in POSIX and has been for a very long time.  If there are any systems
+# that _don't_ have it and really need <sys/file.h>, and still run
+# pkgsrc, we can make this conditional or find another way to do it.
+#
+CPPFLAGS_FOR_BUILD+=   -DHAVE_FCNTL_H
+
 .if empty(USE_CROSS_COMPILE:M[yY][eE][sS])
-MAKE_FLAGS+=   CPPFLAGS_FOR_BUILD=${BUILDLINK_CPPFLAGS:Q}
-MAKE_FLAGS+=   LDFLAGS_FOR_BUILD=${BUILDLINK_LDFLAGS:Q}
+CPPFLAGS_FOR_BUILD+=   ${BUILDLINK_CPPFLAGS}
+LDFLAGS_FOR_BUILD+=    ${BUILDLINK_LDFLAGS}
 .else
+MAKE_FLAGS+=           CROSS_COMPILING=yes
 # XXX should support independent cross PREFIX
-MAKE_FLAGS+=   CROSS_COMPILING=yes \
-               CPPFLAGS_FOR_BUILD=-I${PREFIX:Q}/include \
-               LDFLAGS_FOR_BUILD=-L${PREFIX:Q}/lib\ ${COMPILER_RPATH_FLAG:Q}${PREFIX:Q}/lib
+CPPFLAGS_FOR_BUILD+=   -I${PREFIX:Q}/include
+LDFLAGS_FOR_BUILD+=    -L${PREFIX:Q}/lib
+LDFLAGS_FOR_BUILD+=    ${COMPILER_RPATH_FLAG:Q}${PREFIX:Q}/lib
 CONFIGURE_ARGS.NetBSD+=        ac_cv_file__usr_X_include_X11_X_h=no
 CONFIGURE_ARGS.NetBSD+=        ac_cv_file__usr_X11R6_include_X11_X_h=no
 .  if ${X11_TYPE} != "native"

Index: pkgsrc/x11/motif/distinfo
diff -u pkgsrc/x11/motif/distinfo:1.13 pkgsrc/x11/motif/distinfo:1.14
--- pkgsrc/x11/motif/distinfo:1.13      Tue Apr  5 10:01:06 2022
+++ pkgsrc/x11/motif/distinfo   Sat Apr 16 10:39:50 2022
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.13 2022/04/05 10:01:06 riastradh Exp $
+$NetBSD: distinfo,v 1.14 2022/04/16 10:39:50 riastradh Exp $
 
 BLAKE2s (motif-2.3.8.tar.gz) = b82ee8dac7a840aaa0f364e5b5c018d053a1eb42433e52e5b54f7742d34cbb23
 SHA512 (motif-2.3.8.tar.gz) = 1ab8e8eece25ef97e948592b5fa3e19d98e932695290a18b7a8e90f1aa2766bc4f082bdbc3999dff5660e684821178a149040f76bb477163e53ca06474d02b55
@@ -28,6 +28,6 @@ SHA1 (patch-lib_Xm_Xmos.c) = 88af3627fad
 SHA1 (patch-lib_Xm_XpmI.h) = b27e0156bc2dd990a4d9642186b1638276054314
 SHA1 (patch-lib_Xm_Xpmparse.c) = 95eb0d2d59fcd8c3dd4c9622e17568b35ffbe133
 SHA1 (patch-lib_Xm_Xpmrgb.c) = 494506830c6e96bffe691b511ebe52dd0a1ac2ab
-SHA1 (patch-tools_wml_Makefile.in) = 766b58839ff92efc926e9aedac57c8da5f291933
+SHA1 (patch-tools_wml_Makefile.in) = 73229e1a0e16b754419c73455fabbd6d96d55444
 SHA1 (patch-tools_wml_wmldbcreate.c) = 72c7b768d960a41b6a3b9b4639f1fc042e3e9282
 SHA1 (patch-tools_wml_wmluiltok.l) = 1e79df5605ad8b25a55fbb617a707d27d27e3f2a

Index: pkgsrc/x11/motif/patches/patch-tools_wml_Makefile.in
diff -u pkgsrc/x11/motif/patches/patch-tools_wml_Makefile.in:1.1 pkgsrc/x11/motif/patches/patch-tools_wml_Makefile.in:1.2
--- pkgsrc/x11/motif/patches/patch-tools_wml_Makefile.in:1.1    Tue Apr  5 10:00:21 2022
+++ pkgsrc/x11/motif/patches/patch-tools_wml_Makefile.in        Sat Apr 16 10:39:51 2022
@@ -1,9 +1,27 @@
-$NetBSD: patch-tools_wml_Makefile.in,v 1.1 2022/04/05 10:00:21 riastradh Exp $
+$NetBSD: patch-tools_wml_Makefile.in,v 1.2 2022/04/16 10:39:51 riastradh Exp $
 
 Build wml, wmldbcreate, and wmluitok as tools to run at build-time.
 
 --- tools/wml/Makefile.in.orig 2017-12-05 12:49:59.000000000 +0000
 +++ tools/wml/Makefile.in
+@@ -114,7 +114,7 @@ AM_V_AR = $(am__v_AR_@AM_V@)
+ am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
+ am__v_AR_0 = @echo "  AR      " $@;
+ am__v_AR_1 = 
+-libwml_a_AR = $(AR) $(ARFLAGS)
++libwml_a_AR = $(AR_FOR_BUILD) $(ARFLAGS)
+ libwml_a_LIBADD =
+ am_libwml_a_OBJECTS = wmlparse.$(OBJEXT) wml.$(OBJEXT) \
+       wmloutkey.$(OBJEXT) wmlouth.$(OBJEXT) wmloutmm.$(OBJEXT) \
+@@ -471,7 +471,7 @@ wmlparse.h: wmlparse.c
+ libwml.a: $(libwml_a_OBJECTS) $(libwml_a_DEPENDENCIES) $(EXTRA_libwml_a_DEPENDENCIES) 
+       $(AM_V_at)-rm -f libwml.a
+       $(AM_V_AR)$(libwml_a_AR) libwml.a $(libwml_a_OBJECTS) $(libwml_a_LIBADD)
+-      $(AM_V_at)$(RANLIB) libwml.a
++      $(AM_V_at)$(RANLIB_FOR_BUILD) libwml.a
+ 
+ clean-noinstPROGRAMS:
+       @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
 @@ -484,15 +484,15 @@ clean-noinstPROGRAMS:
  
  wml$(EXEEXT): $(wml_OBJECTS) $(wml_DEPENDENCIES) $(EXTRA_wml_DEPENDENCIES) 



Home | Main Index | Thread Index | Old Index