diff --git a/Makefile.am b/Makefile.am index 290bdcf2..dab3c1c6 100644 --- a/Makefile.am +++ b/Makefile.am @@ -72,7 +72,7 @@ libvkd3d_la_SOURCES = \ libs/vkd3d/vkd3d_main.c \ libs/vkd3d/vkd3d_private.h \ libs/vkd3d/vulkan_procs.h -libvkd3d_la_LIBADD = libvkd3d-common.la @PTHREAD_LIBS@ +libvkd3d_la_LIBADD = libvkd3d-common.la @PTHREAD_LIBS@ @VULKAN_LIBS@ libvkd3d_utils_la_SOURCES = \ libs/vkd3d-utils/vkd3d_utils_main.c \ diff --git a/configure.ac b/configure.ac index 6f99963e..be2f7329 100644 --- a/configure.ac +++ b/configure.ac @@ -54,10 +54,13 @@ m4_ifdef([PKG_PROG_PKG_CONFIG], [PKG_PROG_PKG_CONFIG], [m4_fatal([pkg-config aut AC_ARG_VAR([PTHREAD_LIBS], [linker flags for pthreads]) AC_CHECK_LIB([pthread], [pthread_create], - [AC_SUBST(PTHREAD_LIBS, "-lpthread")], - [AC_MSG_ERROR(libpthread not found.)]) + [AC_SUBST([PTHREAD_LIBS], ["-lpthread"])], + [AC_MSG_ERROR([libpthread not found.])]) -AC_CHECK_LIB([vulkan], [vkGetInstanceProcAddr], [], [AC_MSG_ERROR([libvulkan not found.])]) +AC_SUBST([VULKAN_LIBS]) +AC_CHECK_LIB([vulkan], [vkGetInstanceProcAddr], + [VULKAN_LIBS="-lvulkan"], + [AC_MSG_ERROR([libvulkan not found.])]) PKG_CHECK_MODULES([XCB], [xcb xcb-keysyms])