$NetBSD: patch-libretro_Makefile,v 1.2 2020/06/13 10:43:15 nia Exp $ Use ffmpeg from pkgsrc. Don't pass CFLAGS to as. --- libretro/Makefile.orig 2018-12-04 13:43:39.000000000 +0000 +++ libretro/Makefile @@ -40,7 +40,6 @@ endif # Dirs CORE_DIR = .. -FFMPEGDIR = $(CORE_DIR)/ffmpeg LIBRETRODIR = $(CORE_DIR)/libretro COREDIR = $(CORE_DIR)/Core COMMONDIR = $(CORE_DIR)/Common @@ -60,9 +59,7 @@ ifneq (,$(findstring unix,$(platform))) TARGET := $(TARGET_NAME)_libretro.so LDFLAGS += -shared -Wl,--version-script=link.T -Wl,--no-undefined - FFMPEGINCFLAGS += -I$(FFMPEGDIR)/linux/$(TARGET_ARCH)/include - FFMPEGLIBDIR := $(FFMPEGDIR)/linux/$(TARGET_ARCH)/lib - FFMPEGLDFLAGS += -L$(FFMPEGLIBDIR) -lavformat -lavcodec -lavutil -lswresample -lswscale + FFMPEGLDFLAGS += -lavformat -lavcodec -lavutil -lswresample -lswscale fpic = -fPIC ifneq (,$(findstring gles,$(platform))) GLES = 1 @@ -429,7 +426,7 @@ endif all: $(TARGET) %.o: %.S - $(AS) $(CFLAGS) -c $(OBJOUT)$@ $< + $(CC) $(CFLAGS) -c $(OBJOUT)$@ $< %.o: %.c $(CC) $(CFLAGS) -c $(OBJOUT)$@ $<