configure: Added a WINE_CHECK_LIB_FUNCS macro to check for functions
when linking with specific libraries.
This commit is contained in:
parent
6e27152c96
commit
2d1a6274ee
|
@ -94,6 +94,16 @@ AS_IF([test AS_VAR_GET(ac_var) = yes],
|
||||||
LINTFLAGS="$LINTFLAGS -D$1"])dnl
|
LINTFLAGS="$LINTFLAGS -D$1"])dnl
|
||||||
AS_VAR_POPDEF([ac_var])])
|
AS_VAR_POPDEF([ac_var])])
|
||||||
|
|
||||||
|
dnl **** Check for functions with some extra libraries ****
|
||||||
|
dnl
|
||||||
|
dnl Usage: WINE_CHECK_LIB_FUNCS(funcs,libs,[action-if-found,[action-if-not-found]])
|
||||||
|
dnl
|
||||||
|
AC_DEFUN([WINE_CHECK_LIB_FUNCS],
|
||||||
|
[ac_wine_check_funcs_save_LIBS="$LIBS"
|
||||||
|
LIBS="$LIBS $2"
|
||||||
|
AC_CHECK_FUNCS([$1],[$3],[$4])
|
||||||
|
LIBS="$ac_wine_check_funcs_save_LIBS"])
|
||||||
|
|
||||||
dnl **** Check for ln ****
|
dnl **** Check for ln ****
|
||||||
dnl
|
dnl
|
||||||
dnl Usage: WINE_PROG_LN
|
dnl Usage: WINE_PROG_LN
|
||||||
|
|
|
@ -9757,7 +9757,7 @@ fi
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ac_save_LIBS="$LIBS"
|
ac_wine_check_funcs_save_LIBS="$LIBS"
|
||||||
LIBS="$LIBS $LDAPLIBS $LIBPTHREAD"
|
LIBS="$LIBS $LDAPLIBS $LIBPTHREAD"
|
||||||
|
|
||||||
|
|
||||||
|
@ -9867,7 +9867,7 @@ _ACEOF
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
LIBS="$ac_save_LIBS"
|
LIBS="$ac_wine_check_funcs_save_LIBS"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
FREETYPELIBS=""
|
FREETYPELIBS=""
|
||||||
|
@ -10567,7 +10567,7 @@ _ACEOF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
ac_save_LIBS="$LIBS"
|
ac_wine_check_funcs_save_LIBS="$LIBS"
|
||||||
LIBS="$LIBS $LIBPTHREAD"
|
LIBS="$LIBS $LIBPTHREAD"
|
||||||
|
|
||||||
|
|
||||||
|
@ -10575,8 +10575,7 @@ LIBS="$LIBS $LIBPTHREAD"
|
||||||
for ac_func in \
|
for ac_func in \
|
||||||
pthread_getattr_np \
|
pthread_getattr_np \
|
||||||
pthread_get_stackaddr_np \
|
pthread_get_stackaddr_np \
|
||||||
pthread_get_stacksize_np \
|
pthread_get_stacksize_np
|
||||||
|
|
||||||
do
|
do
|
||||||
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
|
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
|
||||||
echo "$as_me:$LINENO: checking for $ac_func" >&5
|
echo "$as_me:$LINENO: checking for $ac_func" >&5
|
||||||
|
@ -10676,7 +10675,7 @@ _ACEOF
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
LIBS="$ac_save_LIBS"
|
LIBS="$ac_wine_check_funcs_save_LIBS"
|
||||||
|
|
||||||
# Extract the first word of "artsc-config", so it can be a program name with args.
|
# Extract the first word of "artsc-config", so it can be a program name with args.
|
||||||
set dummy artsc-config; ac_word=$2
|
set dummy artsc-config; ac_word=$2
|
||||||
|
|
17
configure.ac
17
configure.ac
|
@ -553,14 +553,12 @@ then
|
||||||
LDAPLIBS="-lldap_r -llber"],,
|
LDAPLIBS="-lldap_r -llber"],,
|
||||||
[$LIBPTHREAD])],,
|
[$LIBPTHREAD])],,
|
||||||
[$LIBPTHREAD])
|
[$LIBPTHREAD])
|
||||||
ac_save_LIBS="$LIBS"
|
WINE_CHECK_LIB_FUNCS(\
|
||||||
LIBS="$LIBS $LDAPLIBS $LIBPTHREAD"
|
|
||||||
AC_CHECK_FUNCS(\
|
|
||||||
ldap_count_references \
|
ldap_count_references \
|
||||||
ldap_first_reference \
|
ldap_first_reference \
|
||||||
ldap_next_reference \
|
ldap_next_reference \
|
||||||
ldap_parse_reference)
|
ldap_parse_reference,
|
||||||
LIBS="$ac_save_LIBS"
|
[$LDAPLIBS $LIBPTHREAD])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
dnl **** Check for FreeType 2 ****
|
dnl **** Check for FreeType 2 ****
|
||||||
|
@ -689,14 +687,11 @@ AC_CHECK_TYPES([pthread_rwlock_t, pthread_rwlockattr_t],,,[#define _GNU_SOURCE
|
||||||
#include <pthread.h>])
|
#include <pthread.h>])
|
||||||
|
|
||||||
dnl **** Check for pthread functions ****
|
dnl **** Check for pthread functions ****
|
||||||
ac_save_LIBS="$LIBS"
|
WINE_CHECK_LIB_FUNCS(\
|
||||||
LIBS="$LIBS $LIBPTHREAD"
|
|
||||||
AC_CHECK_FUNCS(\
|
|
||||||
pthread_getattr_np \
|
pthread_getattr_np \
|
||||||
pthread_get_stackaddr_np \
|
pthread_get_stackaddr_np \
|
||||||
pthread_get_stacksize_np \
|
pthread_get_stacksize_np,
|
||||||
)
|
[$LIBPTHREAD])
|
||||||
LIBS="$ac_save_LIBS"
|
|
||||||
|
|
||||||
dnl **** Check for aRts Sound Server ****
|
dnl **** Check for aRts Sound Server ****
|
||||||
AC_PATH_PROG(ARTSCCONFIG, artsc-config)
|
AC_PATH_PROG(ARTSCCONFIG, artsc-config)
|
||||||
|
|
Loading…
Reference in New Issue