blob: ed6e8599e19ed162b43082b19e622c3d6bf6c1f8 [file] [log] [blame]
Patrick Williams520786c2023-06-25 16:20:36 -05001Upstream-Status: Pending
2
Brad Bishop6e60e8b2018-02-01 10:27:11 -05003Check for argp_parse in libargp and then in libc before using internal version
4
5Index: wvstreams-4.6.1/configure.ac
6===================================================================
7--- wvstreams-4.6.1.orig/configure.ac
8+++ wvstreams-4.6.1/configure.ac
9@@ -142,20 +142,21 @@ CPPFLAGS="$CPPFLAGS_save"
10 # argp
11 USE_WVSTREAMS_ARGP=0
12 AC_CHECK_HEADERS(argp.h)
13-AC_CHECK_FUNC(argp_parse)
14-if test "$ac_cv_func_argp_parse" != yes \
15- -o "$ac_cv_header_argp_h" != yes ; then
16- (
17- echo
18+AC_SEARCH_LIBS([argp_parse], [argp c], [], [
19+
20+ if test "$ac_cv_func_argp_parse" != yes \
21+ -o "$ac_cv_header_argp_h" != yes ; then
22+ (
23+ echo
24 echo 'configuring argp...'
25 cd argp
26 ./configure --host=$host_cpu-$host_os || exit $?
27 echo 'argp configured.'
28 echo
29- ) || exit $?
30- USE_WVSTREAMS_ARGP=1
31-fi
32-
33+ ) || exit $?
34+ USE_WVSTREAMS_ARGP=1
35+ fi
36+])
37 # Function checks
38 AC_HEADER_DIRENT
39