summaryrefslogtreecommitdiff
path: root/ext/nomali/Makefile
blob: 171ce266856db182c053d5377c17eabfbd2519cf (plain)
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
76
77
78
79
80
81
#
# Copyright (c) 2014-2015 ARM Limited
# All rights reserved
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# Authors: Andreas Sandberg

DOXYGEN = doxygen

GCC_VERSION := $(shell $(CC) -dumpversion | sed -e 's/\.//g')
ifeq "$(shell expr $(GCC_VERSION) \< 47)" "1"
$(error Default GCC version is too old. Please use gcc 4.7 or newer.)
endif

CPPFLAGS = -Iinclude/
CFLAGS = -fvisibility=hidden -O1 -g -Wall
CXXFLAGS = -std=c++0x $(CFLAGS)
LDFLAGS=

LIB_CPPFLAGS = $(CPPFLAGS)
LIB_CFLAGS = $(CFLAGS) -fPIC
LIB_CXXFLAGS = $(CXXFLAGS) -fPIC
LIB_LDFLAGS= $(LDFLAGS) -shared

# Default targets
ALL :=

# Test targets
ALL_TESTS :=

# Dependency includes
DEPS :=

# Files/directories to remove in the clean target
CLEAN :=

all: _all

dir:=lib
include $(dir)/Rules.mk

dir:=tests
include $(dir)/Rules.mk

_all: $(ALL)

test: $(ALL_TESTS)
	@set -e;			\
	for T in $^ ; do		\
	  echo "Running $${T}";		\
	  ./$${T};			\
	done

docs:
	$(DOXYGEN) Doxyfile

depclean:
	$(RM) $(DEPS)

clean:
	$(RM) -r $(CLEAN)
	$(RM) -r docs/html


.PHONY: all _all test depclean clean docs

# Include dependencies
-include $(MODEL_OBJS:.o=.d)
-include $(LIBMIDGARDMODEL_OBJS:.o=.d)
-include $(LIBNOMALI_OBJS:.o=.d)