From 5fe624aa1d7b51ddae1ca35cea96e6823b2bcdd8 Mon Sep 17 00:00:00 2001 From: David Hadka Date: Tue, 28 Nov 2023 01:11:49 +0000 Subject: [PATCH] Fix compilation of WDS --- native/WDS/Makefile | 2 +- native/WDS/src/models.h | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/native/WDS/Makefile b/native/WDS/Makefile index 258d550..506e2d5 100644 --- a/native/WDS/Makefile +++ b/native/WDS/Makefile @@ -1,7 +1,7 @@ CC = gcc SRC_DIR = src SOURCE = $(SRC_DIR)/main.c $(SRC_DIR)/models.c $(SRC_DIR)/moeaframework.c -C_FLAGS = -I$(SRC_DIR)/epanet2 -Lbin -lepanet2 -Wl,-R,\. +C_FLAGS = -I$(SRC_DIR)/epanet2 -Lbin -lm -lepanet2 -Wl,-R,\. all: $(MAKE) -C $(SRC_DIR)/epanet2 diff --git a/native/WDS/src/models.h b/native/WDS/src/models.h index b267431..cf2b91d 100644 --- a/native/WDS/src/models.h +++ b/native/WDS/src/models.h @@ -1,5 +1,5 @@ -int nvars; -int nobjs; -int nconstrs; -char* inputFile; +extern int nvars; +extern int nobjs; +extern int nconstrs; +extern char* inputFile; void test_problem (double *xreal, double *xbin, int **gene, double *obj, double *constr); \ No newline at end of file