Skip to content

Commit

Permalink
Check PREFIX/lib/pkgconfig for SDL3 if LIBDIR=.
Browse files Browse the repository at this point in the history
  • Loading branch information
AliceLR committed Nov 7, 2024
1 parent cdcd356 commit c3f693b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,17 @@ ifeq (${BUILD_SDL},3)
ifneq ($(and ${SDL_PKG_CONFIG_PATH},$(wildcard ${SDL_PKG_CONFIG_PATH}/sdl3.pc)),)
# nop
else
ifneq (${LIBDIR},.)
# Check LIBDIR for SDL3 first, if it is set.
ifneq ($(wildcard ${LIBDIR}/pkgconfig/sdl3.pc),)
SDL_PKG_CONFIG_PATH ?= ${LIBDIR}/pkgconfig
endif
else
# Check dependencies prefix instead for LIBDIR=. platforms.
ifneq ($(wildcard ${PREFIX}/lib/pkgconfig/sdl3.pc),)
SDL_PKG_CONFIG_PATH ?= ${PREFIX}/lib/pkgconfig
endif
endif # LIBDIR=.
endif
ifneq (${SDL_PKG_CONFIG_PATH},)
SDL_PKG_CONFIG_FLAGS = --with-path=${SDL_PKG_CONFIG_PATH}
Expand Down

0 comments on commit c3f693b

Please sign in to comment.