diff options
Diffstat (limited to 'build/Makefile.msvcproj')
-rw-r--r-- | build/Makefile.msvcproj | 44 |
1 files changed, 42 insertions, 2 deletions
diff --git a/build/Makefile.msvcproj b/build/Makefile.msvcproj index f127eea5..a4e93a5d 100644 --- a/build/Makefile.msvcproj +++ b/build/Makefile.msvcproj @@ -17,14 +17,19 @@ # MSVCPROJS = YourProject (can be multiple projects in a single srcdir) # YourProject_FILES = $(libyourlib_1_0_SOURCES) # YourProject_EXCLUDES = ... # list of sources to exclude, separated by '|', wildcards allowed; use random unsed value if none +# (the following 3 lines if headers need to be installed) # YourProject_HEADERS_DIR = $(libyourlibincludedir) # YourProject_HEADERS_INST = $(libyourlib_1_0_HEADERS) # YourProject_HEADERS_EXCLUDES = ... # <list of headers to exclude from installation, separated by '|', wildcards allowed; use random unsed value if none> # # dist-hook: \ # (or add to it if it is already there, note the vs9 items will also call the vs10 items in the process) # $(top_builddir)/build/win32/vs9/YourProject.vcproj \ -# $(top_builddir)/build/win32/vs9/YourProject.headers - +# $(top_builddir)/build/win32/vs9/YourProject.headers # if headers need to be installed +# +# --or, if Visual Studio 2013 or later is required-- +# dist-hook: \ # (or add to it if it is already there, this does -not- call other vs items in the process) +# $(top_builddir)/build/win32/vs12/YourProject.vcxproj \ +# $(top_builddir)/build/win32/vs12/YourProject.vs12.headers # if headers need to be installed # Private functions @@ -109,6 +114,41 @@ $(top_builddir)/build/win32/vs9/$(1).headers: Makefile esac; \ done +$(top_builddir)/build/win32/vs12/$(1).vcxproj.filters: $(top_builddir)/build/win32/vs12/$(1).vcxproj + +$(top_builddir)/build/win32/vs12/$(1).vcxproj: Makefile + -$(RM) $(top_builddir)/build/win32/vs14/$(1).vcxproj + -$(RM) $(top_builddir)/build/win32/vs14/$(1).vcxproj.filters + + for F in $(_proj_files); do \ + case $$$$F in \ + $(_proj_filters)) \ + ;; \ + *.c|*.cpp|*.cc|*.cxx) \ + echo ' <ClCompile Include="..\..\..'$(_proj_subdir)$$$$F'" />' >>$(1).vs12.sourcefiles && \ + echo ' <ClCompile Include="..\..\..'$(_proj_subdir)$$$$F'"><Filter>Source Files</Filter></ClCompile>' >>$(1).vs12.sourcefiles.filters \ + ;; \ + esac; \ + done + + $(CPP) -P - <$(top_srcdir)/build/win32/vs12/$(1).vcxprojin >$(top_builddir)/build/win32/vs12/$(1).vcxproj + $(CPP) -P - <$(top_srcdir)/build/win32/vs12/$(1).vcxproj.filtersin >$(top_builddir)/build/win32/vs12/$(1).vcxproj.filters + $(RM) $(1).vs12.sourcefiles + $(RM) $(1).vs12.sourcefiles.filters + +$(top_builddir)/build/win32/vs12/$(1).vs12.headers: Makefile + -$(RM) $(top_builddir)/build/win32/vs12/$(1).vs12.headers + + for F in $(_proj_headers); do \ + case $$$$F in \ + $(_proj_headers_excludes)) \ + ;; \ + *.h|*.hpp|*.hh|*.hxx) \ + echo 'copy ..\..\..'$(_proj_subdir)$$$$F' $$$$(CopyDir)\include'$(_headers_destdir)'\'$$$$F >>$(top_builddir)/build/win32/vs12/$(1).vs12.headers \ + ;; \ + esac; \ + done + endef $(foreach proj,$(MSVCPROJS),$(eval $(call msvcproj-builder,$(proj)))) |