diff options
author | Raja R Harinath <harinath@hurrynot.org> | 2009-07-26 22:46:17 +0400 |
---|---|---|
committer | Raja R Harinath <harinath@hurrynot.org> | 2009-07-26 22:46:17 +0400 |
commit | 28e2595fdba4eb24819c9f479b6fb3b61fd2f35e (patch) | |
tree | 26e304afe70007194c45b859d033b48324d4d422 /mcs | |
parent | 31f9ff7de53fef16c8ef4e1d61b688351637bcbb (diff) |
Make AOT compilation explicit
* platforms/darwin.make (PLATFORM_AOT_SUFFIX): New.
* platforms/linux.make (PLATFORM_AOT_SUFFIX): New.
* library.make ($(build_lib)): Don't try to AOT compile the
library in its possibly temporary location.
(DO_AOT): Remove. Move to ...
($(the_lib)$(PLATFORM_AOT_SUFFIX)): ... here, new rule to
explicitly run the AOT compilation.
(all-local) [ENABLE_AOT]: Build the AOT compiled library as appropriate.
svn path=/trunk/mcs/; revision=138696
Diffstat (limited to 'mcs')
-rw-r--r-- | mcs/build/ChangeLog | 12 | ||||
-rw-r--r-- | mcs/build/library.make | 30 | ||||
-rw-r--r-- | mcs/build/platforms/darwin.make | 2 | ||||
-rw-r--r-- | mcs/build/platforms/linux.make | 2 | ||||
-rw-r--r-- | mcs/build/platforms/win32.make | 3 |
5 files changed, 33 insertions, 16 deletions
diff --git a/mcs/build/ChangeLog b/mcs/build/ChangeLog index 3ccc2048b3e..ded7d195d36 100644 --- a/mcs/build/ChangeLog +++ b/mcs/build/ChangeLog @@ -1,5 +1,17 @@ 2009-07-26 Raja R Harinath <harinath@hurrynot.org> + Make AOT compilation explicit + * platforms/darwin.make (PLATFORM_AOT_SUFFIX): New. + * platforms/linux.make (PLATFORM_AOT_SUFFIX): New. + * library.make ($(build_lib)): Don't try to AOT compile the + library in its possibly temporary location. + (DO_AOT): Remove. Move to ... + ($(the_lib)$(PLATFORM_AOT_SUFFIX)): ... here, new rule to + explicitly run the AOT compilation. + (all-local) [ENABLE_AOT]: Build the AOT compiled library as appropriate. + +2009-07-26 Raja R Harinath <harinath@hurrynot.org> + Fix parallel-build issues with LIBRARY_USE_INTERMEDIATE_FILE * library.make (build_lib): Define to a profile dependent temporary location for LIBRARY_USE_INTERMEDIATE_FILE. diff --git a/mcs/build/library.make b/mcs/build/library.make index ea234e42ac9..51fa22634fe 100644 --- a/mcs/build/library.make +++ b/mcs/build/library.make @@ -219,20 +219,6 @@ BUILT_SOURCES_cmdline = `echo $(BUILT_SOURCES) | $(PLATFORM_CHANGE_SEPARATOR_CMD endif endif -Q_AOT=$(if $(V),,@echo "AOT [$(PROFILE)] $(notdir $(@))";) - -ifdef ENABLE_AOT -ifneq (,$(filter $(AOT_IN_PROFILES), $(PROFILE))) - -DO_AOT := $(Q_AOT) MONO_PATH='$(build_libdir):$(the_libdir)' > $(PROFILE)_aot.log 2>&1 $(RUNTIME) --aot=bind-to-runtime-version - -endif -endif - -ifndef DO_AOT -DO_AOT = @: -endif - # The library $(the_lib): $(the_libdir)/.stamp @@ -240,16 +226,28 @@ $(the_lib): $(the_libdir)/.stamp $(build_lib): $(response) $(sn) $(BUILT_SOURCES) $(build_libdir:=/.stamp) $(LIBRARY_COMPILE) $(LIBRARY_FLAGS) $(LIB_MCS_FLAGS) -target:library -out:$@ $(BUILT_SOURCES_cmdline) @$(response) $(SN) $(SNFLAGS) $@ $(LIBRARY_SNK) - $(DO_AOT) $@ ifdef LIBRARY_USE_INTERMEDIATE_FILE $(the_lib): $(build_lib) $(Q) cp $(build_lib) $@ $(Q) test ! -f $(build_lib).mdb || mv $(build_lib).mdb $@.mdb - $(Q) test ! -f $(build_lib).so || mv $(build_lib).so $@.so $(Q) test ! -f $(build_lib:.dll=.pdb) || mv $(build_lib:.dll=.pdb) $(the_lib:.dll=.pdb) endif +ifdef PLATFORM_AOT_SUFFIX +Q_AOT=$(if $(V),,@echo "AOT [$(PROFILE)] $(notdir $(@))";) +$(the_lib)$(PLATFORM_AOT_SUFFIX): $(the_lib) + $(Q_AOT) MONO_PATH='$(the_libdir)' > $(PROFILE)_aot.log 2>&1 $(RUNTIME) --aot=bind-to-runtime-version $(the_lib) +endif + +ifdef ENABLE_AOT +ifneq (,$(filter $(AOT_IN_PROFILES), $(PROFILE))) + +all-local: $(the_lib)$(PLATFORM_AOT_SUFFIX) + +endif +endif + $(makefrag): $(sourcefile) @echo Creating $@ ... @sed 's,^,$(build_lib): ,' $< >$@ diff --git a/mcs/build/platforms/darwin.make b/mcs/build/platforms/darwin.make index 8a95dda4d5c..7d34071b081 100644 --- a/mcs/build/platforms/darwin.make +++ b/mcs/build/platforms/darwin.make @@ -24,6 +24,8 @@ PLATFORM_PATH_SEPARATOR = : # This is for changing / to \ on windows PLATFORM_CHANGE_SEPARATOR_CMD = cat +PLATFORM_AOT_SUFFIX = .dylib + hidden_prefix = . hidden_suffix = diff --git a/mcs/build/platforms/linux.make b/mcs/build/platforms/linux.make index 0a63daa7d96..2689a0f75ed 100644 --- a/mcs/build/platforms/linux.make +++ b/mcs/build/platforms/linux.make @@ -24,6 +24,8 @@ PLATFORM_PATH_SEPARATOR = : # This is for changing / to \ on windows PLATFORM_CHANGE_SEPARATOR_CMD = cat +PLATFORM_AOT_SUFFIX = .so + hidden_prefix = . hidden_suffix = diff --git a/mcs/build/platforms/win32.make b/mcs/build/platforms/win32.make index 7c6b3f1a917..f5e623c34c7 100644 --- a/mcs/build/platforms/win32.make +++ b/mcs/build/platforms/win32.make @@ -26,6 +26,9 @@ PLATFORM_MAKE_CORLIB_CMP = yes PLATFORM_CHANGE_SEPARATOR_CMD=tr '/' '\\\\' PLATFORM_PATH_SEPARATOR = ; +## not so simple :-) +#PLATFORM_AOT_SUFFIX = .dll + hidden_prefix = hidden_suffix = .tmp |