diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | config/var-def.mk | 2 | ||||
-rw-r--r-- | src/ChangeLog | 9 | ||||
-rw-r--r-- | src/driver/Makefile.in | 4 | ||||
-rw-r--r-- | src/driver/main.c | 3 | ||||
-rw-r--r-- | src/driver/utils.c | 3 |
6 files changed, 22 insertions, 5 deletions
@@ -1,3 +1,9 @@ +2010-07-29 Gabriel Dos Reis <gdr@cs.tamu.edu> + + Support C++ as implementation language. + * config/var-def.mk (CXXCOMPILE): New. + (CXXLINK): Likewise. + 2010-05-07 Gabriel Dos Reis <gdr@cse.tamu.edu> * configure.ac.pamphlet: Add new option: --enable-int-file-retention. diff --git a/config/var-def.mk b/config/var-def.mk index cd5041a9..1768b3e9 100644 --- a/config/var-def.mk +++ b/config/var-def.mk @@ -68,12 +68,14 @@ LIBTOOL = $(top_builddir)/libtool ## Command used to compile a C program COMPILE = $(LIBTOOL) --mode=compile $(CC) -c +CXXCOMPILE = $(LIBTOOL) --mode=compile $(CXX) -c ## Sadly, at the moment, the C parts of the OpenAxiom system is not ## well structured enough to allow for clean dynamic libraries ## and dynamic linking. So, we build static programs. ## This situation is to be fixed when I have time. LINK = $(LIBTOOL) --mode=link $(CC) -static +CXXLINK = $(LIBTOOL) --mode=link $(CXX) -static ## Libtool is a disaster for building DLLs on Cygwin, and insists ## on adding silly extensions where it should not on MinGW, so we have diff --git a/src/ChangeLog b/src/ChangeLog index b7e694f2..a54a1ef7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,14 @@ 2010-07-29 Gabriel Dos Reis <gdr@cs.tamu.edu> + * driver/main.c (main): Add explicit conversion to + openaxiom_spawn_flags. + * driver/utils.c (openaxiom_execute_core): The system want the + excepath to be writable. + * driver/Makefile.in (%.lo): Compile source programs as C++ programs. + (open-axiom$(EXEEXT)): Link as a C++ program. + +2010-07-29 Gabriel Dos Reis <gdr@cs.tamu.edu> + * interp/c-util.boot (removeToplevelRETURN_-FROM): New. (transformToBackendCode): Use it to clean function body. diff --git a/src/driver/Makefile.in b/src/driver/Makefile.in index 75e67763..ae5a6282 100644 --- a/src/driver/Makefile.in +++ b/src/driver/Makefile.in @@ -53,7 +53,7 @@ stamp: $(bin_PROGRAMS) .PRECIOUS: %.lo %.obj %.lo: %.c - $(COMPILE) ${CCF} -o $@ \ + $(CXXCOMPILE) ${CCF} -o $@ \ -DOPENAXIOM_ROOT_DIRECTORY="\"$(open_axiom_installdir)\"" \ $(axiom_includes) $< @@ -61,7 +61,7 @@ utils.lo: utils.h main.lo: utils.h open-axiom$(EXEEXT): $(open_axiom_objects) - $(LINK) -o $@ $(open_axiom_objects) $(open_axiom_LDADD) + $(CXXLINK) -o $@ $(open_axiom_objects) $(open_axiom_LDADD) mostlyclean-local: @rm -f $(open_axiom_objects) diff --git a/src/driver/main.c b/src/driver/main.c index 15e27d8b..c1af3879 100644 --- a/src/driver/main.c +++ b/src/driver/main.c @@ -106,7 +106,8 @@ main(int argc, char* argv[]) case openaxiom_execute_driver: return oa_spawn(&command.core, - openaxiom_spawn_search_path | openaxiom_spawn_replace); + openaxiom_spawn_flags + (openaxiom_spawn_search_path | openaxiom_spawn_replace)); case openaxiom_sman_driver: break; diff --git a/src/driver/utils.c b/src/driver/utils.c index ea8c4faf..d60d4dd6 100644 --- a/src/driver/utils.c +++ b/src/driver/utils.c @@ -316,8 +316,7 @@ int openaxiom_execute_core(const openaxiom_command* command, openaxiom_driver driver) { - const char* execpath = - openaxiom_make_path_for(command->root_dir, driver); + char* execpath = (char*) openaxiom_make_path_for(command->root_dir, driver); #ifdef __WIN32__ char* command_line; int cur = strlen(command->core.argv[0]); |