Skip to content
Snippets Groups Projects
Commit 1606068f authored by Steve Lhomme's avatar Steve Lhomme
Browse files

contrib: modify the PKG_CONFIG pathes when running in mingw32 shells

The pkg-config of these shells only understands windows/hybrid pathes, not UNIX
pathes. The pure Msys2 shell doesn't.

And they force a PKG_CONFIG_LIBDIR unless specifically set, even exporting the
variable is not sufficient.
parent 277b45ef
No related branches found
No related tags found
No related merge requests found
......@@ -51,8 +51,12 @@ endif
ifdef HAVE_CROSS_COMPILE
need_pkg = 1
else
ifeq ($(findstring mingw32,$(BUILD)),mingw32)
need_pkg = $(shell PKG_CONFIG_LIBDIR="${PKG_CONFIG_PATH}" $(PKG_CONFIG) $(1) || echo 1)
else
need_pkg = $(shell $(PKG_CONFIG) $(1) || echo 1)
endif
endif
ifeq ($(findstring mingw32,$(BUILD)),mingw32)
MSYS_BUILD := 1
......@@ -228,6 +232,9 @@ PKG_CONFIG_LIBDIR := /usr/$(HOST)/lib/pkgconfig
export PKG_CONFIG_LIBDIR
endif
PKG_CONFIG_PATH := $(PREFIX)/lib/pkgconfig:$(PKG_CONFIG_PATH)
ifeq ($(findstring mingw32,$(BUILD)),mingw32)
PKG_CONFIG_PATH := $(shell cygpath -pm ${PKG_CONFIG_PATH})
endif
export PKG_CONFIG_PATH
ifndef GIT
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment