Merge pull request #513 from errordeveloper/misc_fix/modffi_pkg_config

modffi: Fix how we call `pkg-config`
This commit is contained in:
Damien George 2014-04-21 01:22:27 +01:00
commit c7d2b10b85
1 changed files with 4 additions and 2 deletions

View File

@ -45,8 +45,10 @@ CFLAGS_MOD += -DMICROPY_MOD_TIME=1
SRC_MOD += modtime.c
endif
ifeq ($(MICROPY_MOD_FFI),1)
CFLAGS_MOD += `pkg-config --cflags libffi` -DMICROPY_MOD_FFI=1
LDFLAGS_MOD += -ldl -lffi
LIBFFI_LDFLAGS_MOD := $(shell pkg-config --libs libffi)
LIBFFI_CFLAGS_MOD := $(shell pkg-config --cflags libffi)
CFLAGS_MOD += $(LIBFFI_CFLAGS_MOD) -DMICROPY_MOD_FFI=1
LDFLAGS_MOD += -ldl $(LIBFFI_LDFLAGS_MOD)
SRC_MOD += modffi.c
endif