shithub: sox

Download patch

ref: 8f6aaf97498ff7edc0dcb30192542b4d5924411c
parent: 85fe52b1ef225112e9021958f56182a6d50325b8
author: Mans Rullgard <mans@mansr.com>
date: Sat Aug 15 16:05:41 EDT 2020

build: simplify DISTRO definition

--- a/configure.ac
+++ b/configure.ac
@@ -166,16 +166,9 @@
 fi
 AC_SUBST(APP_LDFLAGS)
 
-AC_ARG_WITH(distro, AS_HELP_STRING([--with-distro=distro], [Provide distribution name]))
-if test "x$with_distro" != "x"; then
-  DISTRO="$with_distro"
-  AC_SUBST(DISTRO)
-  AC_DEFINE(HAVE_DISTRO, 1, [1 if DISTRO is defined])
-  have_distro=yes
-else
-  DISTRO="not specified!"
-fi
-AM_CONDITIONAL(HAVE_DISTRO, test x$have_distro = xyes)
+AC_ARG_WITH(distro,
+    AS_HELP_STRING([--with-distro=name], [Provide distribution name]),
+    AC_DEFINE_UNQUOTED(DISTRO, ["$with_distro"], [Distribution name]))
 
 dnl Check for system dependent features.
 AC_C_BIGENDIAN
@@ -599,7 +592,7 @@
 echo
 echo "BUILD OPTIONS"
 echo "Debugging build............$enable_debug"
-echo "Distro name ...............$DISTRO"
+echo "Distro name ...............${with_distro:-unspecified}"
 echo "Dynamic loading support....$using_libltdl"
 echo "Pkg-config location........$pkgconfigdir"
 echo "Symlinks enabled...........${SYMLINKS:-no}"
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -18,10 +18,6 @@
 # Pass flags from --enable-silent-libtool
 LIBTOOL = @LIBTOOL@ @LIBTOOLFLAGS@
 
-if HAVE_DISTRO
-AM_CPPFLAGS += -DDISTRO="\"@DISTRO@\""
-endif
-
 
 
 #########################