mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-02-23 20:21:20 +00:00
[build] Batch-report missing packages
Very debian-centric and the reported packages rely on package dependencies, but it's better than getting part-way through a build only to find something is missing and having to restart..
This commit is contained in:
parent
1545480ecb
commit
49667b439d
6 changed files with 55 additions and 14 deletions
|
@ -26,9 +26,7 @@ BISON_VER=`$YACC --version | sed -n '1s/^.*) //p'`
|
|||
AS_VERSION_COMPARE([$BISON_VER], [2.6],
|
||||
[AC_MSG_RESULT([no])
|
||||
LOC=`which ${YACC}`
|
||||
AC_MSG_ERROR(
|
||||
[GNU bison >= 2.6 is required. $BISON_VER found in $LOC]
|
||||
)],
|
||||
AC_MSG_ERROR([GNU bison >= 2.6 is required. $BISON_VER found in $LOC])],
|
||||
AC_MSG_RESULT([yes]),
|
||||
AC_MSG_RESULT([yes])
|
||||
)
|
||||
|
@ -44,7 +42,5 @@ else
|
|||
fi
|
||||
|
||||
|
||||
|
||||
|
||||
AC_CHECK_LIB(l, main, LEXLIB="-ll", AC_CHECK_LIB(fl, main, LEXLIB="-lfl"))
|
||||
AC_SUBST(LEXLIB)
|
||||
|
|
|
@ -26,12 +26,6 @@ if test "x$enable_samplerate" != "xno"; then
|
|||
fi
|
||||
fi
|
||||
AC_SUBST(SAMPLERATE_LIBS)
|
||||
dnl AM_CONDITIONAL(HAVE_SAMPLERATE, test "$HAVE_SAMPLERATE" = "yes")
|
||||
if test "x$HAVE_SAMPLERATE" = "xno"; then
|
||||
AC_MSG_WARN([libsamplerate is required but was not found.]
|
||||
[Sound will be disabled.])
|
||||
enable_sound=no
|
||||
fi
|
||||
|
||||
if test "x$enable_sound" != "xno"; then
|
||||
AC_CHECK_LIB(mme, waveOutOpen, HAVE_LIBMME=yes)
|
||||
|
|
|
@ -7,8 +7,14 @@ if test "x$HAVE_VULKAN" != xno; then
|
|||
AS_IF([test x"$VULKAN_SDK" != x], [
|
||||
CPPFLAGS="$CPPFLAGS -I$VULKAN_SDK/include"
|
||||
LDFLAGS="$LDFLAGS -L$VULKAN_SDK/lib"
|
||||
glslangvalidator="$VULKAN_SDK/bin/glslangValidator"
|
||||
], [glslangvalidator="glslangValidator"])
|
||||
AC_CHECK_PROG([glslangvalidator], [glslangValidator],
|
||||
[$VULKAN_SDK/bin/glslangValidator],
|
||||
[$VULKAN_SDK/bin], [])
|
||||
],
|
||||
[AC_CHECK_PROG([glslangvalidator], [glslangValidator],
|
||||
[glslangValidator],, [])
|
||||
]
|
||||
)
|
||||
AC_CHECK_HEADER([vulkan/vulkan.h], [
|
||||
HAVE_VULKAN=yes
|
||||
AS_IF([test x"$VULKAN_SDK" != x], [
|
||||
|
@ -24,6 +30,9 @@ fi
|
|||
if test "x$HAVE_VULKAN" = xyes; then
|
||||
AC_DEFINE([HAVE_VULKAN], [1], [Define if yhou have the Vulkan libs])
|
||||
fi
|
||||
if test "x$glslangvalidator" != x; then
|
||||
HAVE_GLSLANG=yes
|
||||
fi
|
||||
AC_SUBST(VULKAN_LIBS)
|
||||
AC_SUBST(VULKAN_CPPFLAGS)
|
||||
AC_SUBST(VULKAN_QCFLAGS)
|
||||
|
|
|
@ -24,6 +24,7 @@ if test "x$HAVE_VIDMODE" != xno; then
|
|||
dnl Make sure the library works
|
||||
[AC_CHECK_LIB(Xxf86vm, XF86VidModeSwitchToMode,
|
||||
AC_DEFINE(HAVE_VIDMODE, 1, [Define if you have the XFree86 VIDMODE extension])
|
||||
HAVE_VIDMODE=yes
|
||||
VIDMODE_LIBS="-lXxf86vm",,
|
||||
[$X_LIBS -lXext -lX11 $X_EXTRA_LIBS]
|
||||
)],
|
||||
|
@ -45,6 +46,7 @@ if test "x$HAVE_XI2" != xno; then
|
|||
dnl Make sure the library works
|
||||
[AC_CHECK_LIB(Xi, XIQueryVersion,
|
||||
AC_DEFINE(HAVE_XI2, 1, [Define if you have the Xorg XInput2 extension])
|
||||
HAVE_XI2=yes
|
||||
XI2_LIBS="-lXi",,
|
||||
[$X_LIBS -lXext -lX11 $X_EXTRA_LIBS]
|
||||
)],,
|
||||
|
@ -63,8 +65,9 @@ if test "x$HAVE_XFIXES" != xno; then
|
|||
CPPFLAGS="$X_CFLAGS $CPPFLAGS"
|
||||
AC_CHECK_HEADER(X11/extensions/Xfixes.h,
|
||||
dnl Make sure the library works
|
||||
[AC_CHECK_LIB(Xi, XIQueryVersion,
|
||||
[AC_CHECK_LIB(Xfixes, XFixesQueryVersion,
|
||||
AC_DEFINE(HAVE_XFIXES, 1, [Define if you have the Xorg Xfixes extension])
|
||||
HAVE_XFIXES=yes
|
||||
XFIXES_LIBS="-lXfixes",,
|
||||
[$X_LIBS -lXext -lX11 $X_EXTRA_LIBS]
|
||||
)],,
|
||||
|
@ -85,6 +88,7 @@ if test "x$HAVE_DGA" != xno; then
|
|||
dnl Make sure the library works
|
||||
[AC_CHECK_LIB(Xxf86dga, XF86DGAQueryVersion,
|
||||
AC_DEFINE(HAVE_DGA, 1, [Define if you have the XFree86 DGA extension])
|
||||
HAVE_DGA=yes
|
||||
DGA_LIBS="-lXxf86dga",,
|
||||
[$X_LIBS -lXext -lX11 $X_EXTRA_LIBS]
|
||||
)],
|
||||
|
@ -93,6 +97,7 @@ if test "x$HAVE_DGA" != xno; then
|
|||
[AC_CHECK_LIB(Xxf86dga, XF86DGAQueryVersion,
|
||||
AC_DEFINE(HAVE_DGA, 1, [Define if you have the XFree86 DGA extension])
|
||||
AC_DEFINE(DGA_OLD_HEADERS, 1, [Define if DGA uses old headers])
|
||||
HAVE_DGA=yes
|
||||
DGA_LIBS="-lXxf86dga",,
|
||||
[$X_LIBS -lXext -lX11 $X_EXTRA_LIBS]
|
||||
)],
|
||||
|
|
24
configure.ac
24
configure.ac
|
@ -164,6 +164,30 @@ fi
|
|||
TOPSRC=`readlink -f ${srcdir}`
|
||||
AC_SUBST(TOPSRC)
|
||||
|
||||
QF_REQUIRES([
|
||||
[libasound2-dev, HAVE_ALSA],
|
||||
[libjack-jackd2-dev, HAVE_JACK],
|
||||
[libsamplerate0-dev, HAVE_SAMPLERATE],
|
||||
[libflac-dev, HAVE_FLAC],
|
||||
[libogg-dev, HAVE_OGG],
|
||||
[libvorbis-dev, HAVE_VORBIS],
|
||||
[libpng-dev, HAVE_PNG],
|
||||
[zlib1g-dev, HAVE_ZLIB],
|
||||
[libcurl4-openssl-dev, HAVE_LIBCURL],
|
||||
[libncurses5-dev, HAVE_NCURSES],
|
||||
[libxext-dev, HAVE_X],
|
||||
[libxxf86dga-dev, HAVE_DGA],
|
||||
[libxxf86vm-dev, HAVE_VIDMODE],
|
||||
[libxi-dev, HAVE_XI2],
|
||||
[libxfixes-dev, HAVE_XFIXES],
|
||||
[libvulkan-dev, HAVE_VULKAN],
|
||||
[glslang-tools, HAVE_GLSLANG],
|
||||
[libfontconfig-dev, HAVE_FONTCONFIG],
|
||||
[libfreetype-dev, HAVE_FREETYPE],
|
||||
[libharfbuzz-dev, HAVE_HARFBUZZ],
|
||||
])
|
||||
dnl[vulkan-validationlayers, HAVE_],
|
||||
|
||||
dnl Output files
|
||||
m4_include(config.d/rpm.m4)
|
||||
AC_CONFIG_FILES(m4_include(config.d/ac_config_files.m4))
|
||||
|
|
|
@ -183,3 +183,16 @@ fi
|
|||
AC_DEFUN([QF_CC_OPTION], [
|
||||
QF_CC_OPTION_TEST([$1], [CFLAGS="$CFLAGS $1"])
|
||||
])
|
||||
|
||||
AC_DEFUN([QF_REQUIRES], [
|
||||
qf_req=ok
|
||||
m4_foreach([pkgvar], [$1], [
|
||||
m4_ifnblank(m4_argn(1, pkgvar), [
|
||||
if test "x[$]m4_argn(2, pkgvar)" != "xyes"; then
|
||||
qf_req=missing
|
||||
echo m4_argn(1, pkgvar)
|
||||
fi])])
|
||||
if test "x$qf_req" != "xok"; then
|
||||
AC_MSG_ERROR(The above required packages are missing)
|
||||
fi
|
||||
])
|
||||
|
|
Loading…
Reference in a new issue