summaryrefslogtreecommitdiffstats
path: root/tools/depends/native/Makefile
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-10 18:07:22 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-10 18:07:22 +0000
commitc04dcc2e7d834218ef2d4194331e383402495ae1 (patch)
tree7333e38d10d75386e60f336b80c2443c1166031d /tools/depends/native/Makefile
parentInitial commit. (diff)
downloadkodi-c04dcc2e7d834218ef2d4194331e383402495ae1.tar.xz
kodi-c04dcc2e7d834218ef2d4194331e383402495ae1.zip
Adding upstream version 2:20.4+dfsg.upstream/2%20.4+dfsg
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tools/depends/native/Makefile')
-rw-r--r--tools/depends/native/Makefile105
1 files changed, 105 insertions, 0 deletions
diff --git a/tools/depends/native/Makefile b/tools/depends/native/Makefile
new file mode 100644
index 0000000..800270f
--- /dev/null
+++ b/tools/depends/native/Makefile
@@ -0,0 +1,105 @@
+include ../Makefile.include
+
+ifneq ($(shell test -f $(NATIVEPREFIX)/share/config.site && echo 1),1)
+ $(error Error: $(NATIVEPREFIX)/share/config.site is missing. Please reconfigure depends to generate it)
+endif
+
+# Keep in alphabetical order
+NATIVE= \
+ autoconf \
+ autoconf-archive \
+ automake \
+ cmake \
+ gas-preprocessor \
+ gettext \
+ giflib \
+ heimdal \
+ JsonSchemaBuilder \
+ libjpeg-turbo \
+ liblzo2 \
+ libpng \
+ libtool \
+ m4 \
+ meson \
+ nasm \
+ ninja \
+ openssl \
+ pcre \
+ perlmodule-parseyapp \
+ pkg-config \
+ python3 \
+ swig \
+ TexturePacker \
+ zlib
+
+ifneq ($(NATIVE_OS),osx)
+ NATIVE += libffi
+ LIBFFI = libffi
+endif
+
+ifeq ($(OS),darwin_embedded)
+ NATIVE += dpkg xz tar ldid
+endif
+
+ifeq ($(OS),linux)
+ NATIVE += expat wayland-scanner pugixml waylandpp-scanner
+ EXPAT = expat
+
+ ifeq ($(RENDER_SYSTEM),gles)
+ NATIVE += MarkupSafe Mako
+ endif
+endif
+
+.PHONY: $(NATIVE) native
+
+all: native
+ @echo "Dependencies built successfully."
+
+# Dependency layout for parallel builds
+autoconf-archive: autoconf
+autoconf: m4
+automake: autoconf
+dpkg: automake gettext libtool pkg-config tar
+heimdal: libtool
+JsonSchemaBuilder: automake
+libjpeg-turbo: cmake nasm
+libpng: zlib automake
+libtool: automake
+Mako: MarkupSafe
+meson: python3
+ninja: meson
+openssl: zlib
+pugixml: cmake
+python3: $(EXPAT) $(LIBFFI) pkg-config zlib openssl autoconf-archive
+swig: pcre
+tar: xz automake
+TexturePacker: automake pkg-config libpng liblzo2 giflib libjpeg-turbo
+wayland-scanner: expat pkg-config
+waylandpp-scanner: cmake pugixml
+
+# python installs are not thread safe when using easy_install method.
+# MarkupSafe doesn't really depend on ninja but we need to make the
+# build sequential
+MarkupSafe: ninja
+
+#liblzo2 has stale packaged automake files that cause borked host/build detection
+liblzo2: automake
+
+native: $(NATIVE)
+$(NATIVE):
+ $(MAKE) -C $@
+clean:
+ for d in $(NATIVE); do $(MAKE) -C $$d clean; done
+
+# Debug target, this will DELETE all data in staging!
+test-dependencies:
+ ( for d in $(NATIVE); do \
+ rm -rf $(NATIVEPREFIX); \
+ mkdir -p $(NATIVEPREFIX)/include $(NATIVEPREFIX)/share $(NATIVEPREFIX)/bin; \
+ cp -f config.site $(NATIVEPREFIX)/share/; \
+ $(MAKE) distclean; \
+ $(MAKE) $$d; done ) && echo "$@ built successfully"
+
+distclean::
+ for d in $(NATIVE); do $(MAKE) -C $$d distclean; done
+