Fixed crosscompilation
This commit is contained in:
parent
7af794ee17
commit
fc6c3f9157
5 changed files with 30 additions and 61 deletions
13
Makefile
13
Makefile
|
|
@ -2,6 +2,7 @@ PROGNAME=dump1090
|
|||
|
||||
RTLSDR ?= yes
|
||||
BLADERF ?= yes
|
||||
PKG_CONFIG ?= pkg-config
|
||||
|
||||
CPPFLAGS += -DMODES_DUMP1090_VERSION=\"$(DUMP1090_VERSION)\" -DMODES_DUMP1090_VARIANT=\"dump1090-fa\"
|
||||
|
||||
|
|
@ -21,13 +22,13 @@ ifeq ($(RTLSDR), yes)
|
|||
LIBS_SDR += -L$(RTLSDR_PREFIX)/lib -lrtlsdr -lusb-1.0
|
||||
endif
|
||||
else
|
||||
CFLAGS += $(shell pkg-config --cflags librtlsdr)
|
||||
CFLAGS += $(shell $(PKG_CONFIG) --cflags librtlsdr)
|
||||
# some packaged .pc files are massively broken, try to handle it
|
||||
RTLSDR_LFLAGS := $(shell pkg-config --libs-only-L librtlsdr)
|
||||
RTLSDR_LFLAGS := $(shell $(PKG_CONFIG) --libs-only-L librtlsdr)
|
||||
ifeq ($(RTLSDR_LFLAGS),-L)
|
||||
LIBS_SDR += $(shell pkg-config --libs-only-l --libs-only-other librtlsdr)
|
||||
LIBS_SDR += $(shell $(PKG_CONFIG) --libs-only-l --libs-only-other librtlsdr)
|
||||
else
|
||||
LIBS_SDR += $(shell pkg-config --libs librtlsdr)
|
||||
LIBS_SDR += $(shell $(PKG_CONFIG) --libs librtlsdr)
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
|
@ -35,8 +36,8 @@ endif
|
|||
ifeq ($(BLADERF), yes)
|
||||
SDR_OBJ += sdr_bladerf.o
|
||||
CPPFLAGS += -DENABLE_BLADERF
|
||||
CFLAGS += $(shell pkg-config --cflags libbladeRF)
|
||||
LIBS_SDR += $(shell pkg-config --libs libbladeRF)
|
||||
CFLAGS += $(shell $(PKG_CONFIG) --cflags libbladeRF)
|
||||
LIBS_SDR += $(shell $(PKG_CONFIG) --libs libbladeRF)
|
||||
endif
|
||||
|
||||
all: dump1090 view1090
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue