Makefile.conf
author Damiano Boppart <damiano@pep-security.net>
Sun, 13 Aug 2017 02:22:03 +0200
branchENGINE-228
changeset 1953 e9f2e628cc12
parent 1942 f734d5bd851a
child 1958 433df9ee336d
permissions -rw-r--r--
Split platform-specific parts of Makefile.conf into separate files
damiano@1953
     1
# Copyright 2017, pEp Security SA
damiano@1953
     2
# This file is part of pEpEngine
damiano@1953
     3
# This file may be used under the terms of the GNU General Public License version 3
damiano@1953
     4
# see LICENSE.txt
vb@1513
     5
damiano@1953
     6
# To use custom build configuration variables, put them in a new file at `build-config/<name>.conf`. Execute `export PLATFORM_OVERRIDE=<name>` before running make. If this environment variable is not set, make will load a default configuration for your platform.
vb@450
     7
damiano@1953
     8
BUILD_CONFIG=build-config
vb@450
     9
damiano@1953
    10
include $(BUILD_CONFIG)/common.conf
damiano@1953
    11
ifdef PLATFORM_OVERRIDE
damiano@1953
    12
    include $(BUILD_CONFIG)/$(PLATFORM_OVERRIDE).conf
damiano@1953
    13
# cross-compiling is currently not supported, but maybe you can hack something with `PLATFORM_OVERRIDE`
damiano@1953
    14
else ifeq ($(BUILD_ON),$(BUILD_FOR))
damiano@1953
    15
    include $(BUILD_CONFIG)/$(BUILD_ON).conf
damiano@1953
    16
else
damiano@1953
    17
    $(error I don't know how to build for $(BUILD_FOR) on $(BUILD_ON))
damiano@1953
    18
endif