tMove VERSION definition to Makefile - cngf-pf - continuum model for granular f… | |
git clone git://src.adamsgaard.dk/cngf-pf | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit 812fb3de573d8e4412dbf66aafd9f6b54828f635 | |
parent eed6e94cd9af2c67920a537b5b2dd9fa41cf5378 | |
Author: Anders Damsgaard <[email protected]> | |
Date: Wed, 11 Dec 2019 11:10:44 +0100 | |
Move VERSION definition to Makefile | |
Diffstat: | |
M 1d_fd_simple_shear.c | 1 - | |
M Makefile | 5 ++++- | |
M max_depth_simple_shear.c | 1 - | |
3 files changed, 4 insertions(+), 3 deletions(-) | |
--- | |
diff --git a/1d_fd_simple_shear.c b/1d_fd_simple_shear.c | |
t@@ -9,7 +9,6 @@ | |
#include "simulation.h" | |
#include "fluid.h" | |
-#define VERSION "0.4.6" | |
#define PROGNAME "1d_fd_simple_shear" | |
#include "parameter_defaults.h" | |
diff --git a/Makefile b/Makefile | |
t@@ -7,13 +7,16 @@ PREFIX ?= /usr/local | |
INSTALL ?= install | |
STRIP ?= strip | |
+VERSION = 0.4.6 | |
+GLOBALCONST = -DVERSION=\"${VERSION}\" | |
+ | |
default: ${BIN} | |
.o: | |
${CC} ${LDFLAGS} -o $@ ${LIBS} | |
.c.o: | |
- ${CC} ${CFLAGS} -c $< | |
+ ${CC} ${CFLAGS} ${GLOBALCONST} -c $< | |
1d_fd_simple_shear: 1d_fd_simple_shear.o arrays.o fluid.o simulation.o ${HDR} | |
${CC} ${LDFLAGS} 1d_fd_simple_shear.o arrays.o fluid.o simulation.o -o… | |
diff --git a/max_depth_simple_shear.c b/max_depth_simple_shear.c | |
t@@ -9,7 +9,6 @@ | |
#include "simulation.h" | |
#include "fluid.h" | |
-#define VERSION "0.4.6" | |
#define PROGNAME "1d_fd_simple_shear" | |
#include "parameter_defaults.h" |