forked from ITensor/ITensor
-
Notifications
You must be signed in to change notification settings - Fork 6
/
Makefile
45 lines (38 loc) · 1.16 KB
/
Makefile
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
#
# Makefile for ITensor libraries
#
####################################
include options.mk
build: itensor
itensor: configure
@echo
@echo Building ITensor library
@echo
@cd itensor && $(MAKE)
configure:
@echo
@echo Configure: Writing current dir to this_dir.mk
@echo "THIS_DIR=${CURDIR}" > this_dir.mk
@echo "#ifndef __ITENSOR_CONFIG_H" > itensor/config.h
@echo "#define __ITENSOR_CONFIG_H" >> itensor/config.h
@echo "" >> itensor/config.h
@echo "#ifndef PLATFORM_$(PLATFORM)" >> itensor/config.h
@echo "#define PLATFORM_$(PLATFORM)" >> itensor/config.h
@echo "#endif" >> itensor/config.h
@echo "" >> itensor/config.h
@echo "#ifndef __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES" >> itensor/config.h
@echo "#define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0" >> itensor/config.h
@echo "#endif" >> itensor/config.h
@echo "" >> itensor/config.h
@echo "#endif " >> itensor/config.h
clean:
@echo "Removing temporary build files"
@touch this_dir.mk
@cd itensor && $(MAKE) clean
@cd sample && $(MAKE) clean
@cd unittest && $(MAKE) clean
@rm -f lib/*
@rm -f this_dir.mk
@rm -f itensor/config.h
distclean: clean
@rm -f this_dir.mk options.mk