From 989f09ca99a56cdb68f5f4b2dc65e9390b29289f Mon Sep 17 00:00:00 2001 From: Tony Theodore Date: Sun, 13 Sep 2015 23:08:31 +1000 Subject: [PATCH] mxe-conf: basic sanity checking of autotools in the spirit of ./configure, detect capabilities instead of versions --- src/mxe-conf.mk | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/mxe-conf.mk b/src/mxe-conf.mk index f1af447c..3e10a168 100644 --- a/src/mxe-conf.mk +++ b/src/mxe-conf.mk @@ -69,6 +69,18 @@ define $(PKG)_BUILD echo 'Description: OpenGL'; \ echo 'Libs: -lglu32';) \ > '$(PREFIX)/$(TARGET)/lib/pkgconfig/glu.pc' + + # fail early if autotools can't autoreconf + # 1. detect mismatches in installation locations + # 2. ??? + (echo 'AC_INIT([mxe.cc], [1])'; \ + $(foreach PROG, autoconf automake libtool, \ + echo 'AC_PATH_PROG([$(call uc,$(PROG))], [$(PROG)])';) \ + echo 'PKG_PROG_PKG_CONFIG(0.16)'; \ + echo 'AC_OUTPUT') \ + > '$(1)/configure.ac' + cd '$(1)' && autoreconf -fiv + cd '$(1)' && ./configure endef $(PKG)_BUILD_$(BUILD) = $($(PKG)_BUILD_COMMON)