summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.in26
-rw-r--r--src/ortho/llvm/Makefile4
2 files changed, 15 insertions, 15 deletions
diff --git a/Makefile.in b/Makefile.in
index 947bd26..998804a 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -40,24 +40,23 @@ VHDL_LIB_DIR=$(prefix)/$(libdirsuffix)
ADAC=$(CC)
# Debug
-ADA_FLAGS=-g -gnata
+OPT_FLAGS=-g
+ADA_FLAGS=-gnata
# Optimize, do not forget to use MODE=--genfast for iirs.adb.
-#ADA_FLAGS+=-O -gnatpn
-#GRT_FLAGS+=-O
+#ADA_FLAGS+=-gnatpn
+#OPT_FLAGS+=-O
# Profiling.
-#ADA_FLAGS+=-pg -gnatn -O
-#GRT_FLAGS+=-pg -O
+#ADA_FLAGS+=-gnatn
+#OPT_FLAGS+=-pg -O
# Coverage
-#ADA_FLAGS+=-fprofile-arcs -ftest-coverage
-
-GRT_FLAGS=-g
-LIB_CFLAGS=-g -O2
-
-GNATFLAGS=-gnaty3befhkmr -gnatwae -aO. -gnatf -gnat05 $(ADA_FLAGS)
+#OPT_FLAGS+=-fprofile-arcs -ftest-coverage
+GNATFLAGS=-gnaty3befhkmr -gnatwae -aO. -gnatf -gnat05 $(OPT_FLAGS) $(ADA_FLAGS)
+GRT_FLAGS=$(OPT_FLAGS)
+LIB_CFLAGS=$(OPT_FLAGS)
GNAT_BARGS=-bargs -E
@@ -95,7 +94,7 @@ ghdl_mcode: $(GRT_ADD_OBJS) $(ORTHO_DEPS) memsegs_c.o chkstk.o force
$(GNATMAKE) -o $@ $(GHDL_MCODE_INCFLAGS) $(GNATFLAGS) ghdl_jit.adb $(GNAT_BARGS) -largs memsegs_c.o chkstk.o $(GNAT_LARGS) $(GRT_ADD_OBJS) $(subst @,$(GRTSRCDIR),$(GRT_EXTRA_LIB))
memsegs_c.o: $(srcdir)/src/ortho/mcode/memsegs_c.c
- $(CC) -c -g -o $@ $<
+ $(CC) -c $(OPT_FLAGS) -o $@ $<
libs.vhdl.mcode: vhdl.libs.all
@@ -183,7 +182,8 @@ ghdl_llvm_jit: $(GRT_ADD_OBJS) $(ORTHO_DEPS) llvm-cbindings.o force
$(GNATMAKE) -o $@ $(GHDL_LLVM_INCFLAGS) $(GNATFLAGS) ghdl_jit.adb $(GNAT_BARGS) -largs llvm-cbindings.o $(GNAT_LARGS) $(GRT_ADD_OBJS) $(subst @,$(GRTSRCDIR),$(GRT_EXTRA_LIB)) `$(LLVM_CONFIG) --ldflags --libs --system-libs` -lc++
llvm-cbindings.o: $(srcdir)/src/ortho/llvm/llvm-cbindings.cpp
- $(CXX) -c -m64 `$(LLVM_CONFIG) --includedir --cxxflags` -g -o $@ $<
+ $(CXX) -c `$(LLVM_CONFIG) --includedir --cxxflags` \
+ $(OPT_FLAGS) -o $@ $<
libs.vhdl.llvmjit:
$(MAKE) GHDL=ghdl_llvm_jit vhdl.libs.all
diff --git a/src/ortho/llvm/Makefile b/src/ortho/llvm/Makefile
index 135dbdf..0e20086 100644
--- a/src/ortho/llvm/Makefile
+++ b/src/ortho/llvm/Makefile
@@ -8,12 +8,12 @@ BE=llvm
all: $(ortho_exec)
$(ortho_exec): $(ortho_srcdir)/llvm/ortho_llvm.ads force llvm-cbindings.o
- gnatmake -m -o $@ -g -aI$(ortho_srcdir)/llvm -aI$(ortho_srcdir) \
+ gnatmake -o $@ -aI$(ortho_srcdir)/llvm -aI$(ortho_srcdir) \
$(GNAT_FLAGS) ortho_code_main -bargs -E \
-largs llvm-cbindings.o `$(LLVM_CONFIG) --ldflags --libs --system-libs` -lc++ #-static
llvm-cbindings.o: $(ortho_srcdir)/llvm/llvm-cbindings.cpp
- $(CXX) -c -I`$(LLVM_CONFIG) --includedir --cflags` -g -o $@ $<
+ $(CXX) -c -I`$(LLVM_CONFIG) --includedir --cflags` -o $@ $<
clean:
$(RM) -f *.o *.ali ortho_code_main