aboutsummaryrefslogtreecommitdiff
path: root/example_packages/makefile_complex/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'example_packages/makefile_complex/Makefile')
-rw-r--r--example_packages/makefile_complex/Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/example_packages/makefile_complex/Makefile b/example_packages/makefile_complex/Makefile
new file mode 100644
index 0000000..497c6b2
--- /dev/null
+++ b/example_packages/makefile_complex/Makefile
@@ -0,0 +1,9 @@
+INCLUDE_FLAGS = $(addprefix -I,$(INCLUDE_DIRS))
+
+$(BUILD_DIR)/libmakefile_complex.a: $(BUILD_DIR)/wrapper_mod.o
+ ar rs $(@) $(^)
+
+$(BUILD_DIR)/wrapper_mod.mod: src/wrapper_mod.f90
+
+$(BUILD_DIR)/wrapper_mod.o: src/wrapper_mod.f90
+ $(FC) -c -J$(BUILD_DIR) $(INCLUDE_FLAGS) $(FFLAGS) -o $(@) $(<)