From 390c0cfb06c9576bebef2473a3e3d76bfd2f67a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=A1clav=20Slav=C3=ADk?= Date: Sun, 27 Jul 2003 09:50:55 +0000 Subject: [PATCH] include headers in MSVC++ project files git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@22313 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- build/bakefiles/common.bkl | 13 +++++++++++-- build/bakefiles/monolithic.bkl | 2 ++ build/bakefiles/multilib.bkl | 8 ++++++++ build/bakefiles/opengl.bkl | 2 ++ build/bakefiles/wxwin.py | 17 +++++++++++++++++ 5 files changed, 40 insertions(+), 2 deletions(-) diff --git a/build/bakefiles/common.bkl b/build/bakefiles/common.bkl index bc42741cbd..c846c7a3ad 100644 --- a/build/bakefiles/common.bkl +++ b/build/bakefiles/common.bkl @@ -146,10 +146,10 @@ $(OBJS) - + $(top_builddir)lib - $(TOP_SRCDIR)lib$(DIRSEP)$(COMPILER)_$(CFG_NAME_PART) + $(nativePaths(TOP_SRCDIR))lib$(DIRSEP)$(COMPILER)_$(CFG_NAME_PART) @@ -269,6 +269,14 @@ + + + + $(addPrefixToList('include\', wxwin.headersOnly(value))) + + + + diff --git a/build/bakefiles/monolithic.bkl b/build/bakefiles/monolithic.bkl index 9d0f043a5e..b59d87fac9 100644 --- a/build/bakefiles/monolithic.bkl +++ b/build/bakefiles/monolithic.bkl @@ -14,6 +14,7 @@ wxUSE_BASE=1 WXMAKINGDLL $(MONOLIB_SRC) + $(ALL_HEADERS) $(EXTRALIBS_XML) @@ -21,6 +22,7 @@ cond="SHARED=='0' and MONOLITHIC=='1'"> wxUSE_BASE=1 $(MONOLIB_SRC) + $(ALL_HEADERS) diff --git a/build/bakefiles/multilib.bkl b/build/bakefiles/multilib.bkl index 2222ab8f73..cbb21d4b6d 100644 --- a/build/bakefiles/multilib.bkl +++ b/build/bakefiles/multilib.bkl @@ -13,6 +13,7 @@ wxUSE_BASE=1 wxUSE_GUI=0 $(BASE_SRC) $(BASE_AND_GUI_SRC) + $(BASE_CMN_HDR) $(BASE_PLATFORM_HDR) wxUSE_BASE=1 wxUSE_GUI=0 $(BASE_SRC) $(BASE_AND_GUI_SRC) + $(BASE_CMN_HDR) $(BASE_PLATFORM_HDR) @@ -32,6 +34,7 @@ WXMAKINGDLL_CORE wxUSE_BASE=0 $(BASE_AND_GUI_SRC) $(CORE_SRC) + $(ALL_GUI_HEADERS) basedll @@ -39,6 +42,7 @@ cond="SHARED=='0' and USE_GUI=='1' and MONOLITHIC=='0'"> wxUSE_BASE=0 $(BASE_AND_GUI_SRC) $(CORE_SRC) + $(ALL_GUI_HEADERS) @@ -53,11 +57,13 @@ $(HTML_SRC) coredll basedll + $(HTML_HDR) $(HTML_SRC) + $(HTML_HDR) @@ -76,6 +82,7 @@ WXUSINGDLL WXMAKINGDLL_XML $(XML_SRC) + $(XML_HDR) basedll $(EXTRALIBS_XML) @@ -83,6 +90,7 @@ $(XML_SRC) + $(XML_HDR) diff --git a/build/bakefiles/opengl.bkl b/build/bakefiles/opengl.bkl index 56ed96378a..2d5353c637 100644 --- a/build/bakefiles/opengl.bkl +++ b/build/bakefiles/opengl.bkl @@ -19,6 +19,7 @@ WXUSINGDLL WXMAKINGDLL_GL $(OPENGL_SRC) + $(OPENGL_HDR) $(WXLIBGLDEP_CORE) @@ -41,6 +42,7 @@ $(OPENGL_SRC) + $(OPENGL_HDR) diff --git a/build/bakefiles/wxwin.py b/build/bakefiles/wxwin.py index 69a8d9567b..78c0162b00 100644 --- a/build/bakefiles/wxwin.py +++ b/build/bakefiles/wxwin.py @@ -106,3 +106,20 @@ def getVersionMinor(): return getVersion()[1] def getVersionRelease(): return getVersion()[2] + + +def headersOnly(files): + """Filters 'files' so that only headers are left. Used with + to add headers to VC++ projects but not files such + as arrimpl.cpp.""" + + def callback(cond, sources): + prf = suf = '' + if sources[0].isspace(): prefix=' ' + if sources[-1].isspace(): suffix=' ' + retval = [] + for s in sources.split(): + if s.endswith('.h'): + retval.append(s) + return '%s%s%s' % (prf, ' '.join(retval), suf) + return utils.substitute2(files, callback)