Source-Changes-HG archive

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

[src/trunk]: src Redo xz vs. gzip selection via conditional make expressions, ...



details:   https://anonhg.NetBSD.org/src/rev/b41cea0940eb
branches:  trunk
changeset: 836189:b41cea0940eb
user:      martin <martin%NetBSD.org@localhost>
date:      Mon Oct 01 09:47:34 2018 +0000

description:
Redo xz vs. gzip selection via conditional make expressions, suggested
by joerg.

diffstat:

 distrib/sets/Makefile |  15 +++++----------
 etc/Makefile          |  11 +++--------
 2 files changed, 8 insertions(+), 18 deletions(-)

diffs (55 lines):

diff -r 101cbd4c9533 -r b41cea0940eb distrib/sets/Makefile
--- a/distrib/sets/Makefile     Mon Oct 01 09:39:20 2018 +0000
+++ b/distrib/sets/Makefile     Mon Oct 01 09:47:34 2018 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.105 2018/09/29 06:36:29 kre Exp $
+#      $NetBSD: Makefile,v 1.106 2018/10/01 09:47:34 martin Exp $
 
 # Experimental RCS METALOG versioning
 # (Needs host's rcs(1) commands)
@@ -15,15 +15,10 @@
 .include <bsd.own.mk>
 .include "${NETBSDSRCDIR}/distrib/common/Makefile.distrib"
 
-.if defined(USE_XZ_SETS) && ${USE_XZ_SETS} != "no"
-COMPRESS_PROGRAM=${TOOL_XZ}
-XZ_OPT=-9
-TAR_SUFF=tar.xz
-.else
-COMPRESS_PROGRAM=${TOOL_GZIP}
-GZIP_FLAGS= ${GZIP_N_FLAG}
-TAR_SUFF=tgz
-.endif
+COMPRESS_PROGRAM=${"${USE_XZ_SETS:Uno}"!="no":?${TOOL_XZ}:${TOOL_GZIP}}
+TAR_SUFF=${"${USE_XZ_SETS:Uno}"!="no":?tar.xz:tgz}
+XZ_OPT=                -9
+GZIP_FLAGS=    ${GZIP_N_FLAG}
 
 SETSENV=       DESTDIR=${DESTDIR:Q} \
                MACHINE=${MACHINE:Q} \
diff -r 101cbd4c9533 -r b41cea0940eb etc/Makefile
--- a/etc/Makefile      Mon Oct 01 09:39:20 2018 +0000
+++ b/etc/Makefile      Mon Oct 01 09:47:34 2018 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.436 2018/09/29 06:10:01 martin Exp $
+#      $NetBSD: Makefile,v 1.437 2018/10/01 09:47:34 martin Exp $
 #      from: @(#)Makefile      8.7 (Berkeley) 5/25/95
 
 # Environment variables without default values:
@@ -410,14 +410,9 @@
 distrib-dirs: .PHONY check_DESTDIR
        cd ${NETBSDSRCDIR}/etc/mtree && ${MAKE} distrib-dirs
 
-.if defined(USE_XZ_SETS) && ${USE_XZ_SETS} != "no"
-COMPRESS_PROGRAM=${TOOL_XZ}
+COMPRESS_PROGRAM=${"${USE_XZ_SETS:Uno}"!="no":?${TOOL_XZ}:${TOOL_GZIP}}
 XZ_OPT=-9
-TAR_SUFF=tar.xz
-.else
-COMPRESS_PROGRAM=${TOOL_GZIP}
-TAR_SUFF=tgz
-.endif
+TAR_SUFF=${"${USE_XZ_SETS:Uno}"!="no":?tar.xz:tgz}
 
 # release, snapshot --
 #      Build a full distribution including kernels & install media.



Home | Main Index | Thread Index | Old Index