blob: fd7ec71b1d0bc90b1bdc8a3bc13b0c4be24ca627 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
|
--- Makefile.common.orig 2025-07-19 20:40:49 UTC
+++ Makefile.common
@@ -28,8 +28,13 @@ else
ifeq ($(OS_NAME),Mac)
ENDIANESS:="Little Endian"
else
-ENDIANESS:=$(shell lscpu | grep "Byte Order" |cut -d ":" -f2)
+_btord:=$(shell sysctl -n hw.byteorder)
+ifeq ($(_btord),1234)
+ENDIANESS:="Little Endian"
+else
+ENDIANESS:="Big Endian"
endif
+endif
# Windows uses different path separators
ifeq ($(OS_NAME),Windows)
@@ -50,7 +55,7 @@ endif
# os=Default is meant to be generic unix/linux
# To support new CPU architecture, add a new target name here
-known_os_archs := Linux-x86_64-musl Linux-x86 Linux-x86_64 Linux-arm Linux-armv6 Linux-armv7 Linux-android-arm Linux-android-aarch64 Linux-aarch64 Linux-ppc Linux-ppc64 Linux-ppc64le Linux-s390 Linux-s390x Mac-x86 Mac-x86_64 Mac-aarch64 FreeBSD-x86_64 Windows-x86 Windows-x86_64 Windows-aarch64 SunOS-x86 SunOS-sparc SunOS-x86_64 AIX-ppc AIX-ppc64 Linux-riscv Linux-riscv64 Linux-loongarch Linux-loongarch64
+known_os_archs := Linux-x86_64-musl Linux-x86 Linux-x86_64 Linux-arm Linux-armv6 Linux-armv7 Linux-android-arm Linux-android-aarch64 Linux-aarch64 Linux-ppc Linux-ppc64 Linux-ppc64le Linux-s390 Linux-s390x Mac-x86 Mac-x86_64 Mac-aarch64 FreeBSD-arm FreeBSD-aarch64 FreeBSD-ppc FreeBSD-ppc64 FreeBSD-ppc64le FreeBSD-x86 FreeBSD-x86_64 Windows-x86 Windows-x86_64 Windows-aarch64 SunOS-x86 SunOS-sparc SunOS-x86_64 AIX-ppc AIX-ppc64 Linux-riscv Linux-riscv64 Linux-loongarch Linux-loongarch64
os_arch := $(OS_NAME)-$(OS_ARCH)
IBM_JDK_7 := $(findstring IBM, $(shell $(JAVA) -version 2>&1 | grep IBM | grep "JRE 1.7"))
@@ -272,6 +277,48 @@ Mac-x86_64_SNAPPY_FLAGS :=
Mac-x86_64_LINKFLAGS := -dynamiclib
Mac-x86_64_LIBNAME := libsnappyjava.dylib
Mac-x86_64_SNAPPY_FLAGS :=
+
+FreeBSD-aarch64_CXX := $(CROSS_PREFIX)g++
+FreeBSD-aarch64_STRIP := $(CROSS_PREFIX)strip
+FreeBSD-aarch64_CXXFLAGS := -I$(JAVA_HOME)/include -Ilib/inc_mac -O2 -fPIC -fvisibility=hidden
+FreeBSD-aarch64_LINKFLAGS := -shared -static-libgcc
+FreeBSD-aarch64_LIBNAME := libsnappyjava.so
+FreeBSD-aarch64_SNAPPY_FLAGS :=
+
+FreeBSD-arm_CXX := $(CROSS_PREFIX)g++
+FreeBSD-arm_STRIP := $(CROSS_PREFIX)strip
+FreeBSD-arm_CXXFLAGS := -I$(JAVA_HOME)/include -Ilib/inc_mac -O2 -fPIC -fvisibility=hidden -DSNAPPY_HAVE_NEON=0
+FreeBSD-arm_LINKFLAGS := -shared -static-libgcc
+FreeBSD-arm_LIBNAME := libsnappyjava.so
+FreeBSD-arm_SNAPPY_FLAGS :=
+
+FreeBSD-ppc_CXX := $(CROSS_PREFIX)g++
+FreeBSD-ppc_STRIP := $(CROSS_PREFIX)strip
+FreeBSD-ppc_CXXFLAGS := -I$(JAVA_HOME)/include -Ilib/inc_mac -O2 -fPIC -fvisibility=hidden
+FreeBSD-ppc_LINKFLAGS := -shared -static-libgcc
+FreeBSD-ppc_LIBNAME := libsnappyjava.so
+FreeBSD-ppc_SNAPPY_FLAGS :=
+
+FreeBSD-ppc64_CXX := $(CROSS_PREFIX)g++
+FreeBSD-ppc64_STRIP := $(CROSS_PREFIX)strip
+FreeBSD-ppc64_CXXFLAGS := -I$(JAVA_HOME)/include -Ilib/inc_mac -O2 -fPIC -fvisibility=hidden
+FreeBSD-ppc64_LINKFLAGS := -shared -static-libgcc
+FreeBSD-ppc64_LIBNAME := libsnappyjava.so
+FreeBSD-ppc64_SNAPPY_FLAGS :=
+
+FreeBSD-ppc64le_CXX := $(CROSS_PREFIX)g++
+FreeBSD-ppc64le_STRIP := $(CROSS_PREFIX)strip
+FreeBSD-ppc64le_CXXFLAGS := -I$(JAVA_HOME)/include -Ilib/inc_mac -O2 -fPIC -fvisibility=hidden
+FreeBSD-ppc64le_LINKFLAGS := -shared -static-libgcc
+FreeBSD-ppc64le_LIBNAME := libsnappyjava.so
+FreeBSD-ppc64le_SNAPPY_FLAGS :=
+
+FreeBSD-x86_CXX := $(CROSS_PREFIX)g++
+FreeBSD-x86_STRIP := $(CROSS_PREFIX)strip
+FreeBSD-x86_CXXFLAGS := -I$(JAVA_HOME)/include -Ilib/inc_mac -O2 -fPIC -fvisibility=hidden
+FreeBSD-x86_LINKFLAGS := -shared -static-libgcc
+FreeBSD-x86_LIBNAME := libsnappyjava.so
+FreeBSD-x86_SNAPPY_FLAGS :=
Mac-aarch64_CXX := c++ -arch arm64
Mac-aarch64_STRIP := strip -x
|