GitLab will be upgraded to the 12.10.14-ce.0 on 28 Sept 2020 at 2.00pm (AEDT) to 2.30pm (AEDT). During the update, GitLab and Mattermost services will not be available. If you have any concerns with this, please talk to us at N110 (b) CSIT building.

Commit da406bfd authored by Timm Allman's avatar Timm Allman

fix issues that cause mu_refimpl2_new and mu_refimpl2_new_ex to return NULL always (hopefully)

parent d2922b2e
CFLAGS += -std=gnu11
ifndef JAVA_HOME
$(error JAVA_HOME is required. Invoke with 'make JAVA_HOME=/path/to/java/home')
endif
CFLAGS += -I $(JAVA_HOME)/include
CFLAGS += -std=gnu11 -g -I $(JAVA_HOME)/include
ifndef OS
uname := $(shell uname)
ifeq ($(uname),Darwin)
OS = OSX
else
ifeq ($(uname),Linux)
OS = LINUX
uname := $(shell uname)
ifeq ($(uname),Darwin)
OS = OSX
else ifeq ($(uname),Linux)
OS = LINUX
else
$(error Unrecognized operating system $(uname). I currently only worked on OSX and Linux.)
endif
$(error Unrecognized operating system $(uname). I currently only worked on OSX and Linux.)
endif
endif
ifeq ($(OS),OSX)
CFLAGS += -I $(JAVA_HOME)/include/darwin
LDFLAGS += -L $(JAVA_HOME)/jre/lib/server -l jvm -rpath $(JAVA_HOME)/jre/lib/server -install_name '@rpath/libmurefimpl2start.so'
CFLAGS += -I $(JAVA_HOME)/include/darwin
LDFLAGS += -L $(JAVA_HOME)/jre/lib/server -l jvm -rpath $(JAVA_HOME)/jre/lib/server -install_name '@rpath/libmurefimpl2start.so'
else ifeq ($(OS),LINUX)
CFLAGS += -I $(JAVA_HOME)/include/linux
LDFLAGS += -Wl,--no-as-needed -L $(JAVA_HOME)/jre/lib/amd64/server -l jvm -Wl,-rpath,$(JAVA_HOME)/jre/lib/amd64/server
endif
ifeq ($(OS),LINUX)
CFLAGS += -I $(JAVA_HOME)/include/linux
LDFLAGS += -Wl,--no-as-needed -L $(JAVA_HOME)/jre/lib/amd64/server -l jvm -Wl,-rpath,$(JAVA_HOME)/jre/lib/amd64/server
endif
.PHONY: all
all: libs tests
......@@ -56,10 +49,8 @@ test_client2: test_client2.c libmurefimpl2start.so
$(CC) `./refimpl2-config --istart --cflags --libs` -o $@ $<
.PHONY: clean veryclean
clean:
rm *.so test_client test_client2
rm -f *.so test_client test_client2
veryclean:
rm *.so test_client test_client2 classpath.txt classpath.h
rm ../classpath.txt
veryclean: clean
rm -f classpath.txt classpath.h ../classpath.txt
......@@ -36,8 +36,4 @@ if '--istart' in args:
whereami, whereami), end="")
else:
if '--cflags' in args:
print("-I {} ".format(whereami), end="")
if '--libs' in args:
pass
print("-I {} ".format(whereami), end="")
\ No newline at end of file
......@@ -21,7 +21,7 @@ const char *gc_conf =
"vmLog=DEBUG\n"
;
const char *boot_image_name = "test_client2_bootimg.mu";
char *boot_image_name = "test_client2_bootimg.mu";
int *muerrno;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment