forked from drinkingkazu/OpT0Finder
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathGNUmakefile
More file actions
40 lines (31 loc) · 1.08 KB
/
GNUmakefile
File metadata and controls
40 lines (31 loc) · 1.08 KB
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
ifndef FMATCH_BASEDIR
ERROR_MESSAGE := $(error FMATCH_BASEDIR is not set... run configure.sh!)
endif
OSNAME = $(shell uname -s)
HOST = $(shell uname -n)
OSNAMEMODE = $(OSNAME)
include $(FMATCH_BASEDIR)/Makefile/Makefile.${OSNAME}
SUBDIRS := Base/FMWKTools GeoAlgo Base Algorithms PyUtil #
#ifeq ($(LARCV_NUMPY),1)
#CORE_SUBDIRS += PyUtil
#endif
.phony: all clean
all: obj lib
#all: obj
clean: clean_app clean_core
@rm -f $(FMATCH_LIBDIR)/libflashmatch.so
clean_core:
@for i in $(SUBDIRS); do ( echo "" && echo "Cleaning $$i..." && cd $(FMATCH_DIR)/$$i && rm -rf $(FMATCH_BUILDDIR)/$$i && rm -rf $(FMATCH_BUILDDIR)/lib/*$ii.* ) || exit $$?; done
obj:
@echo
@echo Building ...
@echo
@for i in $(SUBDIRS); do ( echo "" && echo "Compiling $$i..." && cd $(FMATCH_DIR)/$$i && $(MAKE) ) || exit $$?; done
lib: obj
@echo
@if [ `${FMATCH_PYTHON} ${FMATCH_BASEDIR}/bin/libarg.py build` ]; then \
echo Linking library...; \
$(SOMAKER) $(SOFLAGS) $(shell ${FMATCH_PYTHON} $(FMATCH_BASEDIR)/bin/libarg.py); \
else \
echo Nothing to be done for lib...; \
fi