Ticket #66078: patch-01-Makefile-20221023.diff

File patch-01-Makefile-20221023.diff, 1.8 KB (added by johnrosshunt, 2 years ago)
  • Makefile

    a b  
    66CC    := $(CROSS_COMPILE)gcc
    77STRIP := $(CROSS_COMPILE)strip
    88
    9 CFLAGS += -O2 -Wall -Wextra -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wno-unused-parameter
     9override CFLAGS += -Wall -Wextra -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wno-unused-parameter
    1010LDFLAGS += -lpthread
    1111SHARED = -shared -Wl,-soname,libhdhomerun$(LIBEXT)
    1212
     
    4242
    4343ifeq ($(OS),Darwin)
    4444
    45 TARGET_X64 := -target x86_64-apple-macos10.11
    46 TARGET_ARM64 := -target arm64-apple-macos11
     45LIBEXT := .dylib
     46TARGET := -arch x86_64
    4747
    4848all : hdhomerun_config libhdhomerun.dylib
    4949
    50 hdhomerun_config_x64 : hdhomerun_config.c $(LIBSRCS)
    51         $(CC) $(TARGET_X64) $(CFLAGS) $+ $(LDFLAGS) -o $@
     50hdhomerun_config : hdhomerun_config.c $(LIBSRCS)
     51        $(CC) $(TARGET) $(CFLAGS) $+ $(LDFLAGS) -o $@
    5252        $(STRIP) $@
    5353
    54 hdhomerun_config_arm64 : hdhomerun_config.c $(LIBSRCS)
    55         $(CC) $(TARGET_ARM64) $(CFLAGS) $+ $(LDFLAGS) -o $@
    56         $(STRIP) $@
    57 
    58 hdhomerun_config : hdhomerun_config_x64 hdhomerun_config_arm64
    59         lipo -create -output hdhomerun_config hdhomerun_config_x64 hdhomerun_config_arm64
    60 
    61 libhdhomerun_x64.dylib : $(LIBSRCS)
    62         $(CC) $(TARGET_X64) $(CFLAGS) -DDLL_EXPORT -fPIC -dynamiclib $+ $(LDFLAGS) -o $@
    63 
    64 libhdhomerun_arm64.dylib : $(LIBSRCS)
    65         $(CC) $(TARGET_ARM64) $(CFLAGS) -DDLL_EXPORT -fPIC -dynamiclib $+ $(LDFLAGS) -o $@
    66 
    67 libhdhomerun.dylib : libhdhomerun_x64.dylib libhdhomerun_arm64.dylib
    68         lipo -create -output libhdhomerun.dylib libhdhomerun_x64.dylib libhdhomerun_arm64.dylib
     54libhdhomerun.dylib : $(LIBSRCS)
     55        $(CC) $(TARGET) $(CFLAGS) -DDLL_EXPORT -fPIC -dynamiclib -install_name @PREFIX@/lib/libhdhomerun$(LIBEXT) $+ $(LDFLAGS) -o $@
    6956
    7057else
    7158