Skip to content

Commit f9a1dde

Browse files
configure: Use modern way to set AR
This uses AM_PROG_AR to discover ar, which is the recommended way to do so. Among other advantages, it honors the AR environment variable (as set from the outside). The macro has been around since automake 1.11.2 (Dec 2011). This commit also removes code that discovers ranlib and strip. ranlib has been obsolete for decades (ar does its task now automatically), and anyway LT_INIT takes care of discovering it. The code we used to set STRIP was last mentioned in the automake 1.5 manual. Since automake 1.6 (Mar 2002), strip is discovered automatically when necessary (look for the *private* macro AM_PROG_INSTALL_STRIP in the automake manual).
1 parent ac83be3 commit f9a1dde

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

configure.ac

+1-4
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,14 @@ AH_TOP([#define LIBSECP256K1_CONFIG_H])
2727
AH_BOTTOM([#endif /*LIBSECP256K1_CONFIG_H*/])
2828
AM_INIT_AUTOMAKE([foreign subdir-objects])
2929

30+
AM_PROG_AR # must be called before LT_INIT
3031
LT_INIT([win32-dll])
3132

3233
# Make the compilation flags quiet unless V=1 is used.
3334
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
3435

3536
PKG_PROG_PKG_CONFIG
3637

37-
AC_PATH_TOOL(AR, ar)
38-
AC_PATH_TOOL(RANLIB, ranlib)
39-
AC_PATH_TOOL(STRIP, strip)
40-
4138
AC_PROG_CC
4239
if test x"$ac_cv_prog_cc_c89" = x"no"; then
4340
AC_MSG_ERROR([c89 compiler support required])

0 commit comments

Comments
 (0)