diff --git a/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_bsd_fxplugins_Makefile b/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_bsd_fxplugins_Makefile new file mode 100644 index 000000000000..b87efb00fdc7 --- /dev/null +++ b/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_bsd_fxplugins_Makefile @@ -0,0 +1,10 @@ +--- modules/javafx.media/src/main/native/gstreamer/projects/bsd/fxplugins/Makefile.orig 2024-06-01 08:37:05 UTC ++++ modules/javafx.media/src/main/native/gstreamer/projects/bsd/fxplugins/Makefile +@@ -21,7 +21,6 @@ CFLAGS = -fPIC \ + -fstack-protector \ + -Werror=implicit-function-declaration \ + -Werror=trampolines \ +- -msse2 \ + -fbuiltin \ + -DHAVE_STDINT_H \ + -DLINUX \ diff --git a/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_linux_avplugin_Makefile b/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_linux_avplugin_Makefile index 1d019e231f7a..713473ab268c 100644 --- a/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_linux_avplugin_Makefile +++ b/java/openjfx14/files/patch-modules_javafx.media_src_main_native_gstreamer_projects_linux_avplugin_Makefile @@ -1,37 +1,45 @@ --- modules/javafx.media/src/main/native/gstreamer/projects/linux/avplugin/Makefile.orig 2020-07-17 10:21:33 UTC +++ modules/javafx.media/src/main/native/gstreamer/projects/linux/avplugin/Makefile -@@ -41,25 +41,16 @@ endif +@@ -24,7 +24,6 @@ CFLAGS = -fPIC \ + -fstack-protector \ + -Werror=implicit-function-declaration \ + -Werror=trampolines \ +- -msse2 \ + -fbuiltin \ + -DHAVE_STDINT_H \ + -DLINUX \ +@@ -41,25 +40,16 @@ PACKAGES_LIBS := $(shell pkg-config --libs glib-2. PACKAGES_INCLUDES := $(shell pkg-config --cflags glib-2.0) PACKAGES_LIBS := $(shell pkg-config --libs glib-2.0 gobject-2.0) -INCLUDES= -I../../../plugins \ - -I../../../plugins/av \ - -I../../../gstreamer-lite/gstreamer \ - -I../../../gstreamer-lite/gstreamer/libs \ - $(PACKAGES_INCLUDES) +INCLUDES = -I../../../plugins -I../../../plugins/av -I../../../gstreamer-lite/gstreamer -I../../../gstreamer-lite/gstreamer/libs -I%%LOCALBASE%%/ffmpeg4/include $(PACKAGES_INCLUDES) +LDFLAGS = -L$(BUILD_DIR) -lgstreamer-lite -L%%LOCALBASE%%/ffmpeg4/lib -lavcodec -lavformat $(PACKAGES_LIBS) -z relro -static-libgcc -static-libstdc++ -Wl,--gc-sections -LDFLAGS = -L$(BUILD_DIR) \ - -lgstreamer-lite \ - $(PACKAGES_LIBS) \ - -z relro \ - -static-libgcc -static-libstdc++ -Wl,--gc-sections - -ifneq ($(strip $(LIBAV_DIR)),) -INCLUDES += -I$(LIBAV_DIR)/include -LDFLAGS += -L$(LIBAV_DIR)/lib/ -lavcodec -lavformat -else -INCLUDES += $(shell pkg-config --cflags libavcodec libavformat) -LDFLAGS += $(shell pkg-config --libs libavcodec libavformat) -endif +# ifneq ($(strip $(LIBAV_DIR)),) +# INCLUDES += -I$(LIBAV_DIR)/include +# LDFLAGS += -L$(LIBAV_DIR)/lib/ -lavcodec -lavformat +# else +# INCLUDES += $(shell pkg-config --cflags libavcodec libavformat) +# LDFLAGS += $(shell pkg-config --libs libavcodec libavformat) +# endif ifeq ($(ARCH), x32) CFLAGS += -m32 diff --git a/java/openjfx14/files/patch-modules_javafx.media_src_main_native_jfxmedia_projects_bsd_Makefile b/java/openjfx14/files/patch-modules_javafx.media_src_main_native_jfxmedia_projects_bsd_Makefile index bcb55296939c..1cc7c3ca9f22 100644 --- a/java/openjfx14/files/patch-modules_javafx.media_src_main_native_jfxmedia_projects_bsd_Makefile +++ b/java/openjfx14/files/patch-modules_javafx.media_src_main_native_jfxmedia_projects_bsd_Makefile @@ -1,42 +1,43 @@ ---- modules/javafx.media/src/main/native/jfxmedia/projects/bsd/Makefile.orig 2020-07-19 18:30:00 UTC +--- modules/javafx.media/src/main/native/jfxmedia/projects/bsd/Makefile.orig 2024-06-01 08:44:07 UTC +++ modules/javafx.media/src/main/native/jfxmedia/projects/bsd/Makefile @@ -1,5 +1,5 @@ # -# Linux/ARM jfxmedia makefile +# BSD jfxmedia makefile # BUILD_DIR = $(OUTPUT_DIR)/$(BUILD_TYPE) -@@ -18,6 +18,7 @@ DIRLIST = jni \ +@@ -18,6 +18,7 @@ CFLAGS = -DTARGET_OS_LINUX=1 \ TARGET = $(BUILD_DIR)/lib$(BASE_NAME).so CFLAGS = -DTARGET_OS_LINUX=1 \ + -DTARGET_OS_BSD=1 \ -D_GNU_SOURCE \ -DGST_REMOVE_DEPRECATED \ -DGST_DISABLE_GST_DEBUG \ @@ -26,6 +27,7 @@ CFLAGS = -DTARGET_OS_LINUX=1 \ -DHAVE_CONFIG_H \ -DJFXMEDIA_JNI_EXPORTS \ -DLINUX \ + -DG_DISABLE_DEPRECATED \ -ffunction-sections -fdata-sections CPPFLAGS = -fno-rtti -ffunction-sections -fdata-sections -@@ -42,7 +44,6 @@ ifdef HOST_COMPILE +@@ -42,8 +44,6 @@ ifdef HOST_COMPILE -Wformat-security \ -fstack-protector \ -Werror=implicit-function-declaration \ - -Werror=trampolines \ - -msse2 \ +- -msse2 \ -DGSTREAMER_LITE -@@ -51,7 +52,7 @@ ifdef HOST_COMPILE + PACKAGES_INCLUDES := $(shell pkg-config --cflags glib-2.0) +@@ -51,7 +51,7 @@ ifdef HOST_COMPILE INCLUDES = $(BASE_INCLUDES) \ -I$(JAVA_HOME)/include \ - -I$(JAVA_HOME)/include/linux \ + -I$(JAVA_HOME)/include/freebsd \ -I$(GSTREAMER_LITE_DIR)/gstreamer \ -I$(GSTREAMER_LITE_DIR)/gst-plugins-base/gst-libs \ -I$(GSTREAMER_LITE_DIR)/gstreamer/libs \