]> git.argeo.org Git - cc0/argeo-build.git/blob - common.mk
Debug repackage native install
[cc0/argeo-build.git] / common.mk
1 build-major=2
2 build-minor=3
3
4 # Required third party libraries
5 ECJ_MAJOR=3
6 BNDLIB_BRANCH=5.3
7 SYSLOGGER_BRANCH=$(build-major).$(build-minor)
8
9 # The following variables are found in the sdk.mk file which is generated by the configure script:
10 # SDK_SRC_BASE the base of the source code, typically the root of the cloned git repository
11 # SDK_BUILD_BASE the base of the output
12 # JAVA_HOME the base of the JDK used to build
13 A2_OUTPUT = $(SDK_BUILD_BASE)/a2
14 JVM ?= $(JAVA_HOME)/bin/java
15 JAVADOC ?= $(JAVA_HOME)/bin/javadoc
16
17 # The following variables have default values which can be overriden
18 # A2_BASE the space-separated directories where already built a2 categories can be found
19 A2_BASE ?=$(A2_OUTPUT) /usr/local/share/a2 /usr/share/a2
20
21 # GNU defaults
22 prefix ?= /usr/local
23 datarootdir ?= $(prefix)/share
24 exec_prefix ?= $(prefix)
25 libdir ?= $(exec_prefix)/lib
26
27 A2_INSTALL_TARGET ?= $(DESTDIR)$(datarootdir)/a2
28 A2_NATIVE_INSTALL_TARGET ?= $(DESTDIR)$(libdir)/a2
29
30 # OS-speciific
31 KNOWN_ARCHS ?= x86_64 aarch64
32 TARGET_OS ?= linux
33 TARGET_ARCH ?= $(shell uname -m)
34
35 TARGET_OS_CATEGORY_PREFIX=lib/linux
36 TARGET_ARCH_CATEGORY_PREFIX=$(TARGET_OS_CATEGORY_PREFIX)/$(TARGET_ARCH)
37 PORTABLE_CATEGORIES=$(filter-out lib/%, $(CATEGORIES))
38 ARCH_CATEGORIES=$(filter $(TARGET_ARCH_CATEGORY_PREFIX)/%, $(CATEGORIES))
39 OS_CATEGORIES=$(filter-out $(foreach arch, $(KNOWN_ARCHS), $(TARGET_OS_CATEGORY_PREFIX)/$(arch)/%), $(filter $(TARGET_OS_CATEGORY_PREFIX)/%, $(CATEGORIES)))
40
41 # Utilities
42 # Make variables used to replace spaces by a separator, typically in order to generate classpaths
43 # for example: CLASSPATH = $(subst $(space),$(pathsep),$(strip $(JARS)))
44 null :=
45 space := $(null) #
46 pathsep := :
47 define LF
48
49 $(null)
50 endef