Skip to content

Commit fcc5489

Browse files
committed
More adjustments to Makefile.macosx, now successfully compiles
- Re-work logic to determine if make should build gps tracking support. gpsd support can now be tested. - Temporarily remove the output file of unit test 'atest'. Make was erroring out when completing that target for an unknown reason. - Direwolf now compiles sucessfully on OS X 10.11
1 parent 9dac67b commit fcc5489

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

Makefile.macosx

+9-6
Original file line numberDiff line numberDiff line change
@@ -151,12 +151,14 @@ LDLIBS += -framework Foundation -framework CoreServices
151151

152152
CFLAGS += -DUSE_PORTAUDIO -I/opt/local/include
153153

154-
# Uncomment following lines to enable GPS interface & tracker function.
155-
# Not available for MacOSX.
156-
# Although MacPorts has gpsd, wonder if it's the same thing.
157154

158-
#CFLAGS += -DENABLE_GPSD
159-
#LDLIBS += -lgps
155+
# Enable GPS interface and tracker function if the gpsd package is installed.
156+
157+
ifeq ($(shell which -s gpsd),)
158+
CFLAGS += -DENABLE_GPSD
159+
LDLIBS += -lgps
160+
endif
161+
160162

161163
# Name of current directory.
162164
# Used to generate zip file name for distribution.
@@ -401,7 +403,7 @@ testagc : atest.c demod.c dsp.c demod_afsk.c demod_9600.c hdlc_rec.c hdlc_rec2.o
401403

402404
atest : atest.c fsk_fast_filter.h demod.c dsp.c demod_afsk.c demod_9600.c hdlc_rec.c hdlc_rec2.o multi_modem.o rrbb.o \
403405
fcs_calc.c ax25_pad.c decode_aprs.c dwgpsnmea.o dwgps.o serial_port.o telemetry.c latlong.c symbols.c textcolor.c tt_text.c
404-
$(CC) $(CFLAGS) -o $@ $^ -lm
406+
$(CC) $(CFLAGS) $^ -lm
405407

406408
# Unit test for inner digipeater algorithm
407409

@@ -461,6 +463,7 @@ depend : $(wildcard *.c)
461463
clean :
462464
rm -f direwolf decode_aprs text2tt tt2text ll2utm utm2ll aclients atest log2gpx gen_fff gen_packets ttcalc \
463465
fsk_fast_filter.h *.o *.a
466+
rm -rf aclients.dSYM
464467
echo " " > tune.h
465468

466469

0 commit comments

Comments
 (0)