ECHO_CC =@echo $(QUOTE)[CC] $<$(QUOTE)
ECHO_HOSTCC =@echo $(QUOTE)[HOST-CC] $<$(QUOTE)
ECHO_CL =@echo $(QUOTE)[CL] $<$(QUOTE)
- ECHO_AS =@echo $(QUOTE)[AS] $<$(QUOTE)
+ ECHO_GAS =@echo $(QUOTE)[GAS] $<$(QUOTE)
ECHO_NASM =@echo $(QUOTE)[NASM] $<$(QUOTE)
ECHO_AR =@echo $(QUOTE)[AR] $@$(QUOTE)
ECHO_HOSTAR =@echo $(QUOTE)[HOST-AR] $@$(QUOTE)
ECHO_WINEBLD =@echo $(QUOTE)[WINEBLD] $@$(QUOTE)
ECHO_WRC =@echo $(QUOTE)[WRC] $@$(QUOTE)
- ECHO_RC =@echo $(QUOTE)[RC] $@$(QUOTE)
- ECHO_CVTRES =@echo $(QUOTE)[CVTRES] $@$(QUOTE)
ECHO_WIDL =@echo $(QUOTE)[WIDL] $@$(QUOTE)
ECHO_BIN2RES =@echo $(QUOTE)[BIN2RES] $<$(QUOTE)
ECHO_DLLTOOL =@echo $(QUOTE)[DLLTOOL] $@$(QUOTE)
ECHO_CPP =
ECHO_CC =
ECHO_HOSTCC =
- ECHO_AS =
+ ECHO_GAS =
ECHO_NASM =
ECHO_AR =
ECHO_HOSTAR =
ECHO_WINEBLD =
ECHO_WRC =
- ECHO_RC =
- ECHO_CVTRES =
ECHO_WIDL =
ECHO_BIN2RES =
ECHO_DLLTOOL =
endif
gcc = $(Q)$(TARGET_CC)
gpp = $(Q)$(TARGET_CPP)
-gas = $(Q)$(TARGET_CC) -x assembler-with-cpp
ld = $(Q)$(PREFIX_)ld
nm = $(Q)$(PREFIX_)nm
objdump = $(Q)$(PREFIX_)objdump
<property name="VERSION_TARGET" value="NT52" />
<if property="VERSION_TARGET" value="NT4">
- <define name="WINVER">0x400</define>
+ <define name="WINVER" overridable="true">0x400</define>
<define name="_WIN32_IE">0x600</define>
- <define name="_WIN32_WINNT">0x400</define>
+ <define name="_WIN32_WINNT" overridable="true">0x400</define>
<define name="_WIN32_WINDOWS">0x400</define>
<define name="_SETUPAPI_VER">0x400</define>
</if>
<if property="VERSION_TARGET" value="NT5">
- <define name="WINVER">0x500</define>
+ <define name="WINVER" overridable="true">0x500</define>
<define name="_WIN32_IE">0x600</define>
- <define name="_WIN32_WINNT">0x500</define>
+ <define name="_WIN32_WINNT" overridable="true">0x500</define>
<define name="_WIN32_WINDOWS">0x500</define>
<define name="_SETUPAPI_VER">0x500</define>
</if>
<if property="VERSION_TARGET" value="NT51">
- <define name="WINVER">0x501</define>
+ <define name="WINVER" overridable="true">0x501</define>
<define name="_WIN32_IE">0x600</define>
- <define name="_WIN32_WINNT">0x501</define>
+ <define name="_WIN32_WINNT" overridable="true">0x501</define>
<define name="_WIN32_WINDOWS">0x501</define>
<define name="_SETUPAPI_VER">0x501</define>
</if>
<if property="VERSION_TARGET" value="NT52">
- <define name="WINVER">0x502</define>
+ <define name="WINVER" overridable="true">0x502</define>
<define name="_WIN32_IE">0x600</define>
- <define name="_WIN32_WINNT">0x502</define>
+ <define name="_WIN32_WINNT" overridable="true">0x502</define>
<define name="_WIN32_WINDOWS">0x502</define>
<define name="_SETUPAPI_VER">0x502</define>
</if>
<if property="VERSION_TARGET" value="NT6">
- <define name="WINVER">0x600</define>
+ <define name="WINVER" overridable="true">0x600</define>
<define name="_WIN32_IE">0x600</define>
- <define name="_WIN32_WINNT">0x600</define>
+ <define name="_WIN32_WINNT" overridable="true">0x600</define>
<define name="_WIN32_WINDOWS">0x600</define>
<define name="_SETUPAPI_VER">0x600</define>
</if>
<xi:include href="tools/tools.rbuild" />
</directory>
- <compilerflag compiler="cxx">-Wno-non-virtual-dtor</compilerflag>
+ <compilerflag compiler="cpp">-Wno-non-virtual-dtor</compilerflag>
</group>
<module name="umpnpmgr" type="win32cui" installbase="system32" installname="umpnpmgr.exe" unicode="yes">
<include base="umpnpmgr">.</include>
<include base="pnp_server">.</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>pnp_server</library>
<library>ntdll</library>
<library>kernel32</library>
<include base="zlib">.</include>
<include base="inflib">.</include>
<include base="ReactOS">include/reactos/drivers</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="__NO_CTYPE_INLINES" />
<library>zlib</library>
<library>inflib</library>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="autochk" type="nativecui" installbase="system32" installname="autochk.exe">
<include base="autochk">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>nt</library>
<library>ntdll</library>
<file>autochk.c</file>
<module name="smss" type="nativecui" installbase="system32" installname="smss.exe">
<include base="smss">.</include>
<include base="ReactOS">include/reactos/subsys</include>
+ <define name="_DISABLE_TIDENTS" />
<library>nt</library>
<library>smlib</library>
<library>ntdll</library>
<module name="dxtn" type="win32dll" entrypoint="0" installbase="system32" installname="dxtn.dll" allowwarnings="true" crt="msvcrt">
<importlibrary definition="dxtn.spec" />
<include base="dxtn">.</include>
+ <define name="__USE_W32API" />
<file>fxt1.c</file>
<file>dxtn.c</file>
<file>wrapper.c</file>
<importlibrary definition="ncpa.spec" />
<include base="ncpa">.</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>kernel32</library>
<library>advapi32</library>
<importlibrary definition="amstream.spec" />
<include base="amstream">.</include>
<include base="ReactOS">include/reactos/wine</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="__WINESRC__" />
<file>amstream.c</file>
<file>main.c</file>
<module name="dinput" type="win32dll" baseaddress="${BASEADDRESS_DINPUT}" installbase="system32" installname="dinput.dll" unicode="yes">
<autoregister infsection="OleControlDlls" type="DllRegisterServer" />
<importlibrary definition="dinput.spec" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<include base="dinput">.</include>
<include base="ReactOS">include/reactos/wine</include>
<library>wine</library>
<module name="dinput8" type="win32dll" entrypoint="0" baseaddress="${BASEADDRESS_DINPUT8}" installbase="system32" installname="dinput8.dll" unicode="yes">
<autoregister infsection="OleControlDlls" type="DllRegisterServer" />
<importlibrary definition="dinput8.spec" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<include base="dinput8">.</include>
<include base="ReactOS">include/reactos/wine</include>
<library>wine</library>
<importlibrary definition="qedit.spec" />
<include base="qedit">.</include>
<include base="ReactOS">include/reactos/wine</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="__WINESRC__" />
<file>main.c</file>
<file>mediadet.c</file>
<importlibrary definition="quartz.spec" />
<include base="quartz">.</include>
<include base="ReactOS">include/reactos/wine</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>uuid</library>
<library>advapi32</library>
<file>viewport.c</file>
<dependency>wineheaders</dependency>
-
- <!-- See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38054#c7 -->
- <compilerflag>-fno-unit-at-a-time</compilerflag>
</module>
<!DOCTYPE module SYSTEM "../../../../tools/rbuild/project.dtd">
<module name="wined3d" type="win32dll" installbase="system32" installname="wined3d.dll" allowwarnings ="true" crt="msvcrt">
<importlibrary definition="wined3d.spec" />
+ <compilerflag compiler="cc">-Wno-format</compilerflag>
<include base="wined3d">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
<module name="kbda1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbda1.dll">
<importlibrary definition="kbda1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbda1.c</file>
<file>kbda1.rc</file>
</module>
<module name="kbda2" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbda2.dll">
<importlibrary definition="kbda2.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbda2.c</file>
<file>kbda2.rc</file>
</module>
<module name="kbda3" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbda3.dll">
<importlibrary definition="kbda3.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbda3.c</file>
<file>kbda3.rc</file>
</module>
<module name="kbdal" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdal.dll">
<importlibrary definition="kbdal.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdal.c</file>
<file>kbdal.rc</file>
</module>
<module name="kbdarme" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdarme.dll">
<importlibrary definition="kbdarme.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdarme.c</file>
<file>kbdarme.rc</file>
</module>
<module name="kbdarmw" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdarmw.dll">
<importlibrary definition="kbdarmw.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdarmw.c</file>
<file>kbdarmw.rc</file>
</module>
<module name="kbdaze" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdaze.dll">
<importlibrary definition="kbdaze.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdaze.c</file>
<file>kbdaze.rc</file>
</module>
<module name="kbdazel" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdazel.dll">
<importlibrary definition="kbdazel.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdazel.c</file>
<file>kbdazel.rc</file>
</module>
<module name="kbdbe" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdbe.dll">
<importlibrary definition="kbdbe.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdbe.c</file>
<file>kbdbe.rc</file>
</module>
<module name="kbdbga" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdbga.dll">
<importlibrary definition="kbdbga.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdbga.c</file>
<file>kbdbga.rc</file>
</module>
<module name="kbdbgm" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdbgm.dll">
<importlibrary definition="kbdbgm.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdbgm.c</file>
<file>kbdbgm.rc</file>
</module>
<module name="kbdbgt" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdbgt.dll">
<importlibrary definition="kbdbgt.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdbgt.c</file>
<file>kbdbgt.rc</file>
</module>
<module name="kbdblr" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdblr.dll">
<importlibrary definition="kbdblr.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdblr.c</file>
<file>kbdblr.rc</file>
</module>
<module name="kbdbr" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdbr.dll">
<importlibrary definition="kbdbr.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdbr.c</file>
<file>kbdbr.rc</file>
</module>
<module name="kbdbur" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdbur.dll">
<importlibrary definition="kbdbur.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdbur.c</file>
<file>kbdbur.rc</file>
</module>
<module name="kbdcan" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdcan.dll">
<importlibrary definition="kbdcan.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdcan.c</file>
<file>kbdcan.rc</file>
</module>
<module name="kbdcr" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdcr.dll">
<importlibrary definition="kbdcr.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdcr.c</file>
<file>kbdcr.rc</file>
</module>
<module name="kbdcz" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdcz.dll">
<importlibrary definition="kbdcz.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdcz.c</file>
<file>kbdcz.rc</file>
</module>
<module name="kbdcz1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdcz1.dll">
<importlibrary definition="kbdcz1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdcz1.c</file>
<file>kbdcz1.rc</file>
</module>
<module name="kbdda" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdda.dll">
<importlibrary definition="kbdda.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdda.c</file>
<file>kbdda.rc</file>
</module>
<module name="kbddv" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbddv.dll">
<importlibrary definition="kbddv.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbddv.c</file>
<file>kbddv.rc</file>
</module>
<module name="kbdes" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdes.dll">
<importlibrary definition="kbdes.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdes.c</file>
<file>kbdes.rc</file>
</module>
<module name="kbdest" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdest.dll">
<importlibrary definition="kbdest.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdest.c</file>
<file>kbdest.rc</file>
</module>
<module name="kbdfc" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdfc.dll">
<importlibrary definition="kbdfc.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdfc.c</file>
<file>kbdfc.rc</file>
</module>
<module name="kbdfi" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdfi.dll">
<importlibrary definition="kbdfi.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdfi.c</file>
<file>kbdfi.rc</file>
</module>
<module name="kbdfr" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdfr.dll">
<importlibrary definition="kbdfr.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdfr.c</file>
<file>kbdfr.rc</file>
</module>
<module name="kbdgeo" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdgeo.dll">
<importlibrary definition="kbdgeo.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdgeo.c</file>
<file>kbdgeo.rc</file>
</module>
<module name="kbdgerg" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdgerg.dll">
<importlibrary definition="kbdgerg.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdgerg.c</file>
<file>kbdgerg.rc</file>
</module>
<module name="kbdgneo" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdgneo.dll">
<importlibrary definition="kbdgneo.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdgneo.c</file>
<file>kbdgneo.rc</file>
</module>
<module name="kbdgr" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdgr.dll">
<importlibrary definition="kbdgr.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdgr.c</file>
<file>kbdgr.rc</file>
</module>
<module name="kbdgrist" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdgrist.dll">
<importlibrary definition="kbdgrist.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdgrist.c</file>
<file>kbdgrist.rc</file>
</module>
<module name="kbdhe" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdhe.dll">
<importlibrary definition="kbdhe.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdhe.c</file>
<file>kbdhe.rc</file>
</module>
<module name="kbdheb" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdheb.dll">
<importlibrary definition="kbdheb.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdheb.c</file>
<file>kbdheb.rc</file>
</module>
<module name="kbdhu" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdhu.dll">
<importlibrary definition="kbdhu.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdhu.c</file>
<file>kbdhu.rc</file>
</module>
<module name="kbdic" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdic.dll">
<importlibrary definition="kbdic.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdic.c</file>
<file>kbdic.rc</file>
</module>
<module name="kbdinasa" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdinasa.dll">
<importlibrary definition="kbdinasa.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdinasa.c</file>
<file>kbdinasa.rc</file>
</module>
<module name="kbdinben" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdinben.dll">
<importlibrary definition="kbdinben.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdinben.c</file>
<file>kbdinben.rc</file>
</module>
<module name="kbdindev" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdindev.dll">
<importlibrary definition="kbdindev.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdindev.c</file>
<file>kbdindev.rc</file>
</module>
<module name="kbdinguj" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdinguj.dll">
<importlibrary definition="kbdinguj.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdinguj.c</file>
<file>kbdinguj.rc</file>
</module>
<module name="kbdinmal" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdinmal.dll">
<importlibrary definition="kbdinmal.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdinmal.c</file>
<file>kbdinmal.rc</file>
</module>
<module name="kbdir" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdir.dll">
<importlibrary definition="kbdir.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdir.c</file>
<file>kbdir.rc</file>
</module>
<module name="kbdit" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdit.dll">
<importlibrary definition="kbdit.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdit.c</file>
<file>kbdit.rc</file>
</module>
<module name="kbdja" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdja.dll">
<importlibrary definition="kbdja.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdja.c</file>
<file>kbdja.rc</file>
</module>
<module name="kbdkaz" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdkaz.dll">
<importlibrary definition="kbdkaz.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdkaz.c</file>
<file>kbdkaz.rc</file>
</module>
<module name="kbdko" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdko.dll">
<importlibrary definition="kbdko.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdko.c</file>
<file>kbdko.rc</file>
</module>
<module name="kbdla" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdla.dll">
<importlibrary definition="kbdla.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdla.c</file>
<file>kbdla.rc</file>
</module>
<module name="kbdlt1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdlt1.dll" allowwarnings="true">
<importlibrary definition="kbdlt1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdlt1.c</file>
<file>kbdlt1.rc</file>
</module>
<module name="kbdlv" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdlv.dll">
<importlibrary definition="kbdlv.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdlv.c</file>
<file>kbdlv.rc</file>
</module>
<module name="kbdmac" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdmac.dll">
<importlibrary definition="kbdmac.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdmac.c</file>
<file>kbdmac.rc</file>
</module>
<module name="kbdne" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdne.dll">
<importlibrary definition="kbdne.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdne.c</file>
<file>kbdne.rc</file>
</module>
<module name="kbdno" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdno.dll">
<importlibrary definition="kbdno.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdno.c</file>
<file>kbdno.rc</file>
</module>
<module name="kbdpl1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdpl1.dll">
<importlibrary definition="kbdpl1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdpl1.c</file>
<file>kbdpl1.rc</file>
</module>
<module name="kbdpo" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdpo.dll">
<importlibrary definition="kbdpo.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdpo.c</file>
<file>kbdpo.rc</file>
</module>
<module name="kbdro" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdro.dll">
<importlibrary definition="kbdro.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdro.c</file>
<file>kbdro.rc</file>
</module>
<module name="kbdru" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdru.dll">
<importlibrary definition="kbdru.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdru.c</file>
<file>kbdru.rc</file>
</module>
<module name="kbdru1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdru1.dll">
<importlibrary definition="kbdru1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdru1.c</file>
<file>kbdru1.rc</file>
</module>
<module name="kbdsg" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdsg.dll">
<importlibrary definition="kbdsg.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdsg.c</file>
<file>kbdsg.rc</file>
</module>
<module name="kbdsk" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdsk.dll">
<importlibrary definition="kbdsk.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdsk.c</file>
<file>kbdsk.rc</file>
</module>
<module name="kbdsk1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdsk1.dll">
<importlibrary definition="kbdsk1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdsk1.c</file>
<file>kbdsk1.rc</file>
</module>
<module name="kbdsw" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdsw.dll">
<importlibrary definition="kbdsw.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdsw.c</file>
<file>kbdsw.rc</file>
</module>
<module name="kbdtat" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdtat.dll">
<importlibrary definition="kbdtat.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdtat.c</file>
<file>kbdtat.rc</file>
</module>
<module name="kbdth0" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdth0.dll">
<importlibrary definition="kbdth0.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdth0.c</file>
<file>kbdth0.rc</file>
</module>
<module name="kbdth1" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdth1.dll">
<importlibrary definition="kbdth1.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdth1.c</file>
<file>kbdth1.rc</file>
</module>
<module name="kbdth2" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdth2.dll">
<importlibrary definition="kbdth2.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdth2.c</file>
<file>kbdth2.rc</file>
</module>
<module name="kbdth3" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdth3.dll">
<importlibrary definition="kbdth3.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdth3.c</file>
<file>kbdth3.rc</file>
</module>
<module name="kbdtuf" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdtuf.dll">
<importlibrary definition="kbdtuf.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdtuf.c</file>
<file>kbdtuf.rc</file>
</module>
<module name="kbdtuq" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdtuq.dll">
<importlibrary definition="kbdtuq.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdtuq.c</file>
<file>kbdtuq.rc</file>
</module>
<module name="kbduk" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbduk.dll">
<importlibrary definition="kbduk.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbduk.c</file>
<file>kbduk.rc</file>
</module>
<module name="kbdur" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdur.dll">
<importlibrary definition="kbdur.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdur.c</file>
<file>kbdur.rc</file>
</module>
<module name="kbdurs" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdurs.dll">
<importlibrary definition="kbdurs.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdurs.c</file>
<file>kbdurs.rc</file>
</module>
<module name="kbdus" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdus.dll">
<importlibrary definition="kbdus.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdus.c</file>
<file>kbdus.rc</file>
</module>
<module name="kbdusa" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdusa.dll">
<importlibrary definition="kbdusa.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdusa.c</file>
<file>kbdusa.rc</file>
</module>
<module name="kbdusl" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdusl.dll">
<importlibrary definition="kbdusl.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdusl.c</file>
<file>kbdusl.rc</file>
</module>
<module name="kbdusr" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdusr.dll">
<importlibrary definition="kbdusr.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdusr.c</file>
<file>kbdusr.rc</file>
</module>
<module name="kbdusx" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdusx.dll">
<importlibrary definition="kbdusx.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdusx.c</file>
<file>kbdusx.rc</file>
</module>
<module name="kbduzb" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbduzb.dll">
<importlibrary definition="kbduzb.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbduzb.c</file>
<file>kbduzb.rc</file>
</module>
<module name="kbdvntc" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdvntc.dll">
<importlibrary definition="kbdvntc.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdvntc.c</file>
<file>kbdvntc.rc</file>
</module>
<module name="kbdycc" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdycc.dll">
<importlibrary definition="kbdycc.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdycc.c</file>
<file>kbdycc.rc</file>
</module>
<module name="kbdycl" type="keyboardlayout" entrypoint="0" installbase="system32" installname="kbdycl.dll">
<importlibrary definition="kbdycl.spec" />
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<file>kbdycl.c</file>
<file>kbdycl.rc</file>
</module>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="idndl" type="win32dll" installname="idndl.dll" entrypoint="0">
<library>kernel32</library>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
- <redefine name="WINVER">0x600</redefine>
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
+ <define name="WINVER">0x600</define>
<file>idndl.cpp</file>
<importlibrary definition="idndl.def" />
</module>
<module name="idndl_redist" type="win32dll" installname="idndl_redist.dll" crt="libcntpr">
<library>kernel32</library>
<library>scripts</library>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<linkerflag>--entry=0</linkerflag>
<include base="icu4ros">icu/source/common</include>
<include base="scripts">.</include>
<library>idna</library>
<library>normaliz_redist_data</library>
<library>kernel32</library>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<include base="icu4ros">icu/source/common</include>
<importlibrary definition="normaliz.def" />
<file>normaliz.cpp</file>
<include base="ntdll" root="intermediate"></include>
<include base="ReactOS">include/reactos/subsys</include>
<define name="__NTDLL__" />
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTOSKRNL_" />
<define name="__NO_CTYPE_INLINES" />
<library>rtl</library>
<include base="lsa_client">.</include>
<include base="eventlog_client">.</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="_ADVAPI32_" />
<library>scm_client</library>
<include base="atl">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>atl_ax.c</file>
<file>atl_main.c</file>
<file>registrar.c</file>
<include base="avifil32">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>acmstream.c</file>
<file>api.c</file>
<file>avifile.c</file>
<include base="ReactOS">include/reactos/wine</include>
<include base="explorer_new">.</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>ole32</library>
<library>user32</library>
<include base="comcat">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>ole32</library>
<library>user32</library>
<importlibrary definition="crtdll.def" />
<include base="crtdll">.</include>
<include base="crt">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="USE_MSVCRT_PREFIX" />
<define name="_MSVCRT_LIB_" />
<define name="_MSVCRT_" />
<include base="crypt32">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>user32</library>
<library>advapi32</library>
<module name="dhcpcsvc" type="win32dll" baseaddress="${BASEADDRESS_DHCPCSVC}" installbase="system32" installname="dhcpcsvc.dll">
<importlibrary definition="dhcpcsvc.spec" />
<include base="dhcpcsvc">include</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>ws2_32</library>
<include base="dnsapi">include</include>
<include base="adns">src</include>
<include base="adns">adns_win32</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="ADNS_JGAA_WIN32" />
<library>adns</library>
<library>ntdll</library>
<module name="fmifs" type="win32dll" entrypoint="InitializeFmIfs@12" baseaddress="${BASEADDRESS_FMIFS}" installbase="system32" installname="fmifs.dll">
<importlibrary definition="fmifs.spec" />
<include base="fmifs">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<file>chkdsk.c</file>
<module name="gdi32" type="win32dll" baseaddress="${BASEADDRESS_GDI32}" installbase="system32" installname="gdi32.dll" unicode="yes" crt="dll" allowwarnings="true">
<importlibrary definition="gdi32.spec" />
<include base="gdi32">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="LANGPACK" />
<library>user32</library>
<library>kernel32</library>
<include base="ReactOS">include/reactos/wine</include>
<include base="ReactOS" root="intermediate">include/reactos</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<dependency>wineheaders</dependency>
<file>chm.c</file>
<file>content.c</file>
<include base="imm32">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>imm.c</file>
<file>version.rc</file>
<library>wine</library>
<include base="inetcomm">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>imaptransport.c</file>
<file>inetcomm_main.c</file>
<file>internettransport.c</file>
<include base="inseng">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>inseng_main.c</file>
<file>regsvr.c</file>
<library>wine</library>
<autoregister infsection="OleControlDlls" type="DllRegisterServer" />
<importlibrary definition="jscript.spec" />
<include base="jscript">.</include>
- <include base="jscript" root="intermediate" compiler="rc">.</include>
+ <include base="jscript" root="intermediate">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
<define name="RPC_NO_WINDOWS_H" />
<include base="kernel32_base">include</include>
<include base="ReactOS">include/reactos/subsys</include>
<define name="_KERNEL32_" />
- <redefine name="_WIN32_WINNT">0x0600</redefine>
+ <define name="_DISABLE_TIDENTS" />
+ <define name="_WIN32_WINNT">0x0600</define>
<define name="__NO_CTYPE_INLINES" />
<define name="NTDDI_VERSION">0x05020100</define>
<dependency>errcodes</dependency>
</if>
</directory>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<directory name="misc">
<file>icustubs.cpp</file>
<include base="kernel32">.</include>
<include base="kernel32" root="intermediate">.</include>
<include base="kernel32">include</include>
+ <define name="_DISABLE_TIDENTS" />
<library>kernel32_base</library>
<library>wine</library>
<library>pseh</library>
<include base="localspl">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>localmon.c</file>
<file>localspl_main.c</file>
<file>provider.c</file>
<module name="lpk" type="win32dll" baseaddress="${BASEADDRESS_LPK}" installbase="system32" installname="lpk.dll" unicode="yes">
<importlibrary definition="lpk.spec" />
<include base="lpk">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="LANGPACK" />
<library>ntdll</library>
<library>kernel32</library>
<include base="mlang">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>mlang.c</file>
<file>regsvr.c</file>
<library>wine</library>
<include base="msctf">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>categorymgr.c</file>
<file>context.c</file>
<file>documentmgr.c</file>
<include base="mshtml">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>conpoint.c</file>
<file>dispex.c</file>
<file>editor.c</file>
<include base="msi">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>action.c</file>
<file>alter.c</file>
<file>appsearch.c</file>
<include base="mstask">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="WINVER">0x600</redefine>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="WINVER">0x600</define>
+ <define name="_WIN32_WINNT">0x600</define>
<file>factory.c</file>
<file>mstask_main.c</file>
<file>task.c</file>
<importlibrary definition="msvcrt.def" />
<include base="msvcrt">.</include>
<include base="crt">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="USE_MSVCRT_PREFIX" />
<define name="_MSVCRT_" />
<define name="_MSVCRT_LIB_" />
<include base="msxml3" root="intermediate">.</include>
<dependency>msxml3_v1</dependency>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x601</redefine>
+ <define name="_WIN32_WINNT">0x601</define>
<define name="LIBXML_STATIC" />
<library>libxml2</library>
<library>libxslt</library>
<importlibrary definition="ntmarta.spec" />
<include base="ntmarta">.</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>ntdll</library>
<library>kernel32</library>
<library>advapi32</library>
<include base="objsel">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>ole32</library>
<library>user32</library>
<include base="ole32">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="_OLE32_" />
<define name="ENTRY_PREFIX">OLE32_</define>
<define name="PROXY_CLSID">CLSID_PSFactoryBuffer</define>
<include base="ReactOS">include/reactos/libs/libjpeg</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="PROXY_CLSID">CLSID_PSDispatch</define>
<define name="COM_NO_WINDOWS_H"/>
<define name="_OLEAUT32_"/>
<module name="opengl32" type="win32dll" baseaddress="${BASEADDRESS_OPENGL32}" installbase="system32" installname="opengl32.dll" unicode="yes" crt="msvcrt">
<importlibrary definition="opengl32.spec" />
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>gdi32</library>
<include base="pdh">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>kernel32</library>
<library>ntdll</library>
<importlibrary definition="psapi.spec" />
<include base="psapi">.</include>
<include base="psapi">include</include>
+ <define name="_DISABLE_TIDENTS" />
<library>epsapi</library>
<library>pseh</library>
<library>ntdll</library>
<module name="rasdlg" type="win32dll" baseaddress="${BASEADDRESS_RASDLG}" installbase="system32" installname="rasdlg.dll">
<importlibrary definition="rasdlg.spec" />
<include base="rasdlg">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>wine</library>
<library>kernel32</library>
<library>ntdll</library>
<module name="rasman" type="win32dll" baseaddress="${BASEADDRESS_RASMAN}" installbase="system32" installname="rasman.dll">
<importlibrary definition="rasman.spec" />
<include base="rasman">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>wine</library>
<library>kernel32</library>
<library>ntdll</library>
<group>
<module name="riched20" type="win32dll" baseaddress="${BASEADDRESS_RICHED20}" installbase="system32" installname="riched20.dll" allowwarnings="true">
<importlibrary definition="riched20.spec" />
+ <compilerflag compiler="cc">-Wno-format</compilerflag>
<include base="riched20">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
<importlibrary definition="rpcrt4.spec" />
<include base="rpcrt4">.</include>
<include base="ReactOS">include/reactos/wine</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="_RPCRT4_" />
<define name="COM_NO_WINDOWS_H" />
<define name="MSWMSG" />
<module name="samlib" type="win32dll" baseaddress="${BASEADDRESS_SAMLIB}" installbase="system32" installname="samlib.dll">
<importlibrary definition="samlib.spec" />
<include base="samlib">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>advapi32</library>
<include base="ReactOS">include/reactos/wine</include>
<define name="_SHELL32_" />
<define name="COM_NO_WINDOWS_H" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<library>wine</library>
<library>uuid</library>
<library>recyclebin</library>
<module name="shimgvw" type="win32dll" baseaddress="${BASEADDRESS_SHIMGVW}" installbase="system32" installname="shimgvw.dll">
<importlibrary definition="shimgvw.spec" />
<include base="shimgvw">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>kernel32</library>
<library>advapi32</library>
<library>comctl32</library>
<importlibrary definition="shlwapi.spec" />
<include base="shlwapi">.</include>
<include base="ReactOS">include/reactos/wine</include>
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<define name="__WINESRC__" />
<file>assoc.c</file>
<file>clist.c</file>
<importlibrary definition="smdll.spec" />
<include base="smdll">.</include>
<include base="ReactOS">include/reactos/subsys</include>
+ <define name="_DISABLE_TIDENTS" />
<library>smlib</library>
<library>ntdll</library>
<file>dllmain.c</file>
<module name="twain_32" type="win32dll" baseaddress="${BASEADDRESS_TWAIN_32}" installbase="system32" installname="twain_32.dll" allowwarnings="true" crt="msvcrt">
<importlibrary definition="twain_32.def" />
<include base="twain_32">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>wine</library>
<library>ntdll</library>
<library>kernel32</library>
<module name="uext2" type="win32dll" baseaddress="${BASEADDRESS_UEXT2}" installbase="system32" installname="uext2.dll">
<importlibrary definition="uext2.def" />
<include base="uext2">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ext2lib</library>
<library>ntdll</library>
<file>uext2.c</file>
<module name="ufat" type="win32dll" baseaddress="${BASEADDRESS_UFAT}" installbase="system32" installname="ufat.dll">
<importlibrary definition="ufat.def" />
<include base="ufat">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>vfatlib</library>
<library>ntdll</library>
<file>ufat.c</file>
<module name="ufatx" type="win32dll" entrypoint="0" baseaddress="${BASEADDRESS_UFAT}" installbase="system32" installname="ufatx.dll">
<importlibrary definition="ufatx.def" />
<include base="ufatx">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>vfatxlib</library>
<library>ntdll</library>
<file>ufatx.rc</file>
<module name="untfs" type="win32dll" baseaddress="${BASEADDRESS_UNTFS}" installbase="system32" installname="untfs.dll">
<importlibrary definition="untfs.def" />
<include base="untfs">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntfslib</library>
<library>ntdll</library>
<file>untfs.c</file>
<include base="urlmon">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>bindctx.c</file>
<file>binding.c</file>
<file>bindprot.c</file>
<include base="user32">.</include>
<include base="user32">include</include>
<include base="ReactOS">include/reactos/subsys</include>
+ <define name="_DISABLE_TIDENTS" />
<library>wine</library>
<library>gdi32</library>
<library>kernel32</library>
<importlibrary definition="winspool.spec" />
<include base="winspool">.</include>
<include base="ReactOS">include/reactos/wine</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>advapi32</library>
<importlibrary definition="ws2_32.spec" />
<include base="ws2_32">include</include>
<include base="ReactOS">include/reactos/wine</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="LE" />
<library>wine</library>
<library>ntdll</library>
<module name="ws2help" type="win32dll" baseaddress="${BASEADDRESS_WS2HELP}" installbase="system32" installname="ws2help.dll" unicode="yes">
<importlibrary definition="ws2help.def" />
<include base="ws2help">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>ws2_32</library>
<module name="wshirda" type="win32dll" baseaddress="${BASEADDRESS_WSHIRDA}" installbase="system32" installname="wshirda.dll" unicode="yes">
<importlibrary definition="wshirda.spec" />
<include base="wshirda">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>ws2_32</library>
<include base="wuapi">.</include>
<include base="ReactOS">include/reactos/wine</include>
<define name="__WINESRC__" />
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>downloader.c</file>
<file>installer.c</file>
<file>main.c</file>
installbase="system32/drivers" installname="dxapi.sys">
<importlibrary definition="dxapi.spec" />
<include base="dxapi">.</include>
+ <define name="__USE_W32API" />
<define name="_DXAPI_" />
<library>ntoskrnl</library>
<library>hal</library>
installbase="system32/drivers" installname="dxgthk.sys">
<importlibrary definition="dxgthk.spec" />
<include base="dxgthk">.</include>
+ <define name="__USE_W32API" />
<library>win32k</library>
<file>main.c</file>
<file>dxgthk.rc</file>
<bootstrap installbase="$(CDOUTPUT)" />
<include base="uniata">.</include>
<include base="uniata">inc</include>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
<!-- define name="_DEBUG" /-->
<library>ntoskrnl</library>
<library>hal</library>
<module name="mpu401" type="kernelmodedriver" installbase="system32/drivers" installname="mpu401.sys" allowwarnings="true">
<include base="mpu401">.</include>
<include base="mpu401">..</include>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
<library>ntoskrnl</library>
<library>portcls</library>
<file>mpu401.rc</file>
<include base="drmk">.</include>
<include base="drmk">..</include>
<include base="drmk">../include</include>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
<importlibrary definition="drmk.spec" />
<library>ntoskrnl</library>
<define name="BUILDING_DRMK" />
<module name="halarm_generic" type="objectlibrary">
<include base="halarm_generic">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<file>hal.c</file>
<pch>../include/hal.h</pch>
<bootstrap installbase="$(CDOUTPUT)" nameoncd="hal.dll" />
<include base="halarm_generic">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<library>halarm_generic</library>
<library>ntoskrnl</library>
<module name="halppc_generic" type="objectlibrary">
<include base="halppc_generic">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<file>beep.c</file>
<file>bus.c</file>
<bootstrap installbase="$(CDOUTPUT)" nameoncd="hal.dll" />
<include base="halppc_generic">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<library>halppc_generic</library>
<library>ntoskrnl</library>
<module name="hal_generic" type="objectlibrary">
<include base="hal_generic">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<file>beep.c</file>
<file>bios.c</file>
<module name="hal_generic_up" type="objectlibrary">
<include base="hal_generic_up">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<file>irq.S</file>
<file>processor.c</file>
<module name="hal_generic_pc" type="objectlibrary">
<include base="hal_generic_pc">../include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<file>pci.c</file>
</module>
<module name="hal_generic" type="objectlibrary">
<include>include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<directory name="generic">
<file>beep.c</file>
<module name="hal_generic_pc" type="objectlibrary">
<include>include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<directory name="generic">
<file>pci.c</file>
<module name="hal_generic_up" type="objectlibrary">
<include>include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<directory name="generic">
<file>irq.S</file>
<bootstrap installbase="$(CDOUTPUT)" />
<include>include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="CONFIG_SMP" />
<define name="_NTHAL_" />
<library>hal_generic</library>
<bootstrap installbase="$(CDOUTPUT)" />
<include>include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<library>hal_generic</library>
<library>hal_generic_up</library>
<importlibrary base="hal" definition="hal.pspec" />
<include>include</include>
<include base="ntoskrnl">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
<define name="SARCH_XBOX" />
<library>hal_generic</library>
#ifndef KJK_INTRIN_H_
#define KJK_INTRIN_H_
-#ifndef RC_INVOKED
-
#ifndef __GNUC__
#error Unsupported compiler
#endif
#endif
-#endif
-
/* EOF */
<!DOCTYPE group SYSTEM "../../../tools/rbuild/project.dtd">
<group>
<module name="pnp_server" type="rpcserver">
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>pnp.idl</file>
</module>
<module name="pnp_client" type="rpcclient">
- <redefine name="_WIN32_WINNT">0x600</redefine>
+ <define name="_WIN32_WINNT">0x600</define>
<file>pnp.idl</file>
</module>
<module name="scm_server" type="rpcserver">
<define name="U_HAVE_INTTYPES_H" />
<define name="UCONFIG_NO_FILE_IO">1</define>
<define name="ICU_NO_USER_DATA_OVERRIDE">1</define>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<include base="icu4ros">icu/source/common</include>
<include base="icu4ros">icu/source/i18n</include>
<file>stubs.cpp</file>
<group>
<module name="wine" type="staticlibrary">
<include base="ReactOS">include/reactos/wine</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="__WINESRC__" />
<file>config.c</file>
<file>debug_ros.c</file>
</module>
<module name="wineldr" type="staticlibrary">
<include base="ReactOS">include/reactos/wine</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="__WINESRC__" />
<file>loader.c</file>
</module>
<module name="oskittcp" type="staticlibrary">
<define name="__NTDRIVER__"/>
<define name="KERNEL"/>
+ <define name="_DISABLE_TIDENTS"/>
<define name="__NO_CTYPE_INLINES" />
<include base="oskittcp">include/freebsd</include>
<include base="oskittcp">include/freebsd/sys/include</include>
<?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd">
<module name="epsapi" type="objectlibrary">
+ <define name="_DISABLE_TIDENTS" />
<directory name="enum">
<file>drivers.c</file>
<file>modules.c</file>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="ext2lib" type="staticlibrary">
<include base="ext2lib">.</include>
+ <define name="_DISABLE_TIDENTS" />
<file>Badblock.c</file>
<file>Bitmap.c</file>
<file>Disk.c</file>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="ntfslib" type="staticlibrary">
<include base="ntfslib">.</include>
+ <define name="_DISABLE_TIDENTS" />
<file>ntfslib.c</file>
</module>
\ No newline at end of file
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="vfatlib" type="staticlibrary">
<include base="vfatlib">.</include>
+ <define name="_DISABLE_TIDENTS" />
<file>fat12.c</file>
<file>fat16.c</file>
<file>fat32.c</file>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="vfatxlib" type="staticlibrary">
<include base="vfatxlib">.</include>
+ <define name="_DISABLE_TIDENTS" />
<file>fatx.c</file>
<file>vfatxlib.c</file>
</module>
<module name="idna" type="staticlibrary">
<library>icu4ros</library>
- <redefine name="WINVER">0x600</redefine>
+ <define name="WINVER">0x600</define>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<include base="icu4ros">icu/source/common</include>
<file>idna.cpp</file>
<file>nameprep.cpp</file>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="normalize" type="staticlibrary">
<library>icu4ros</library>
- <redefine name="WINVER">0x600</redefine>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+
+ <define name="WINVER">0x600</define>
+
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<include base="icu4ros">icu/source/common</include>
<file>normalize.cpp</file>
</module>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="scripts" type="staticlibrary">
<library>icu4ros</library>
- <redefine name="WINVER">0x600</redefine>
- <compilerflag compiler="cxx">-fno-exceptions</compilerflag>
- <compilerflag compiler="cxx">-fno-rtti</compilerflag>
+
+ <define name="WINVER">0x600</define>
+
+ <compilerflag compiler="cpp">-fno-exceptions</compilerflag>
+ <compilerflag compiler="cpp">-fno-rtti</compilerflag>
<include base="icu4ros">icu/source/common</include>
<file>scripts.cpp</file>
</module>
<?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd">
<module name="ntdllsys" type="staticlibrary">
+ <define name="_DISABLE_TIDENTS" />
<directory name="." root="intermediate">
<file>ntdll.S</file>
</directory>
<library>chkstk</library>
<include base="crt">.</include>
<include base="crt">include</include>
+ <define name="_DISABLE_TIDENTS" />
<define name="__MINGW_IMPORT">extern</define>
<define name="USE_MSVCRT_PREFIX" />
<define name="_MSVCRT_LIB_" />
<?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="dxguid" type="staticlibrary">
+ <define name="_DISABLE_TIDENTS" />
<file>dxguid-mingw.c</file>
</module>
<?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="nt" type="staticlibrary">
+ <define name="_DISABLE_TIDENTS" />
<file>entry_point.c</file>
</module>
<?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="strmiids" type="staticlibrary">
+ <define name="_DISABLE_TIDENTS" />
<file>strmiids.c</file>
</module>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="uuid" type="staticlibrary">
<include base="ReactOS">include/reactos/wine</include>
+ <define name="_DISABLE_TIDENTS" />
<file>uuid.c</file>
</module>
<module name="smlib" type="staticlibrary">
<include base="smlib">.</include>
<include base="ReactOS">include/reactos/subsys</include>
+ <define name="_DISABLE_TIDENTS" />
<file>connect.c</file>
<file>execpgm.c</file>
<file>compses.c</file>
<?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd">
<module name="win32ksys" type="staticlibrary">
+ <define name="_DISABLE_TIDENTS" />
<directory name="." root="intermediate">
<file>win32k.S</file>
</directory>
<group xmlns:xi="http://www.w3.org/2001/XInclude">
<bootstrap installbase="$(CDOUTPUT)" />
<importlibrary definition="ntoskrnl.pspec" />
+ <define name="_DISABLE_TIDENTS" />
<define name="__NTOSKRNL__" />
<define name="_NTOSKRNL_" />
<define name="_NTSYSTEM_" />
<include base="csrsrv">.</include>
<include base="csr">.</include>
<include base="ReactOS">include/reactos/subsys</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>pseh</library>
<file>api.c</file>
<!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd">
<module name="ntvdm" type="win32cui" installbase="system32" installname="ntvdm.exe">
<include base="ntvdm">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>user32</library>
<include base="ReactOS">include/reactos/subsys</include>
<include base="ReactOS">include/reactos/drivers</include>
<include base="console">.</include>
+ <define name="_DISABLE_TIDENTS" />
<library>ntdll</library>
<library>kernel32</library>
<library>user32</library>
vector<MingwModuleHandler*> v;
size_t i;
- for ( std::map<std::string, Module*>::iterator p = ProjectNode.modules.begin (); p != ProjectNode.modules.end (); ++ p )
- fprintf ( fMakefile, "%s_TYPE:=%u\n", p->second->name.c_str(), p->second->type );
-
for ( std::map<std::string, Module*>::iterator p = ProjectNode.modules.begin (); p != ProjectNode.modules.end (); ++ p )
{
Module& module = *p->second;
}
void
-MingwBackend::GenerateGlobalProperties (
+MingwBackend::GenerateProjectCFlagsMacro ( const char* assignmentOperation,
+ const IfableData& data ) const
+{
+ set<string> used_defs;
+
+ if ( data.includes.size () > 0 )
+ fprintf (
+ fMakefile,
+ "PROJECT_CINCLUDES %s %s\n",
+ assignmentOperation,
+ MingwModuleHandler::GenerateGccIncludeParametersFromVector ( data.includes ).c_str ());
+
+ if ( data.defines.size () > 0 )
+ fprintf (
+ fMakefile,
+ "PROJECT_CDEFINES %s %s\n",
+ assignmentOperation,
+ MingwModuleHandler::GenerateGccDefineParametersFromVector ( data.defines, used_defs ).c_str ());
+}
+
+void
+MingwBackend::GenerateGlobalCFlagsAndProperties (
const char* assignmentOperation,
const IfableData& data ) const
{
prop.value.c_str() );
}
}
+
+ if ( data.includes.size() || data.defines.size() )
+ {
+ GenerateProjectCFlagsMacro ( assignmentOperation,
+ data );
+ }
+}
+
+void
+MingwBackend::GenerateProjectGccOptionsMacro ( const char* assignmentOperation,
+ IfableData& data ) const
+{
+ size_t i;
+
+ fprintf (
+ fMakefile,
+ "PROJECT_GCCOPTIONS %s",
+ assignmentOperation );
+
+ for ( i = 0; i < data.compilerFlags.size(); i++ )
+ {
+ if ( data.compilerFlags[i]->compiler == CompilerTypeDontCare )
+ {
+ fprintf (
+ fMakefile,
+ " %s",
+ data.compilerFlags[i]->flag.c_str() );
+ }
+ }
+
+ fputs ( "\n", fMakefile );
+
+ // TODO: reference these from somewhere
+ fprintf (
+ fMakefile,
+ "PROJECT_GCC_CFLAGS %s",
+ assignmentOperation );
+
+ for ( i = 0; i < data.compilerFlags.size(); i++ )
+ {
+ if ( data.compilerFlags[i]->compiler == CompilerTypeCC )
+ {
+ fprintf (
+ fMakefile,
+ " %s",
+ data.compilerFlags[i]->flag.c_str() );
+ }
+ }
+
+ fputs ( "\n", fMakefile );
+
+ fprintf (
+ fMakefile,
+ "PROJECT_GCC_CXXFLAGS %s",
+ assignmentOperation );
+
+ for ( i = 0; i < data.compilerFlags.size(); i++ )
+ {
+ if ( data.compilerFlags[i]->compiler == CompilerTypeCPP )
+ {
+ fprintf (
+ fMakefile,
+ " %s",
+ data.compilerFlags[i]->flag.c_str() );
+ }
+ }
+
+ fputs ( "\n", fMakefile );
+}
+
+void
+MingwBackend::GenerateProjectGccOptions (
+ const char* assignmentOperation,
+ IfableData& data ) const
+{
+ if ( data.compilerFlags.size() )
+ {
+ GenerateProjectGccOptionsMacro ( assignmentOperation,
+ data );
+ }
}
string
"PREFIX := %s\n",
compilerPrefix.c_str () );
fprintf ( fMakefile,
- "nasm := $(Q)%s\n",
+ "nasm := %s\n",
nasmCommand.c_str () );
- GenerateGlobalProperties ( "=", ProjectNode.non_if_data );
-
- fprintf ( fMakefile, "PROJECT_CFLAGS += -Wall\n" );
- fprintf ( fMakefile, "PROJECT_CXXFLAGS += -Wall\n" );
- fprintf ( fMakefile, "ifneq ($(OARCH),)\n" );
- fprintf ( fMakefile, "PROJECT_CFLAGS += -march=$(OARCH)\n" );
- fprintf ( fMakefile, "PROJECT_CXXFLAGS += -march=$(OARCH)\n" );
- fprintf ( fMakefile, "endif\n" );
- fprintf ( fMakefile, "ifneq ($(TUNE),)\n" );
- fprintf ( fMakefile, "PROJECT_CFLAGS += -mtune=$(TUNE)\n" );
- fprintf ( fMakefile, "PROJECT_CXXFLAGS += -mtune=$(TUNE)\n" );
- fprintf ( fMakefile, "endif\n" );
+ GenerateGlobalCFlagsAndProperties ( "=", ProjectNode.non_if_data );
+ GenerateProjectGccOptions ( "=", ProjectNode.non_if_data );
- fprintf ( fMakefile, "PROJECT_CFLAGS += -g%s\n", Environment::GetArch() == "amd64" ? "dwarf-2" : "stabs+" );
- fprintf ( fMakefile, "PROJECT_CXXFLAGS += -g%s\n", Environment::GetArch() == "amd64" ? "dwarf-2" : "stabs+" );
- fprintf ( fMakefile, "PROJECT_ASFLAGS += -g%s\n", Environment::GetArch() == "amd64" ? "dwarf-2" : "stabs+" );
-
- MingwModuleHandler::GenerateParameters ( "PROJECT", "+=", ProjectNode.non_if_data );
- MingwModuleHandler::GenerateParameters ( "PROJECT_HOST", "+=", ProjectNode.host_non_if_data );
-
- if ( usePipe )
- {
- fprintf ( fMakefile, "PROJECT_CFLAGS += -pipe\n" );
- fprintf ( fMakefile, "PROJECT_CXXFLAGS += -pipe\n" );
- fprintf ( fMakefile, "PROJECT_ASFLAGS += -pipe\n" );
- }
-
- // Because RosBE gcc is built to suck
- fputs ( "BUILTIN_HOST_CINCLUDES+= $(HOST_CFLAGS)\n", fMakefile );
- fputs ( "BUILTIN_HOST_CPPINCLUDES+= $(HOST_CFLAGS)\n", fMakefile );
- fputs ( "BUILTIN_HOST_CXXINCLUDES+= $(HOST_CPPFLAGS)\n", fMakefile );
-
- // Would be nice to have our own C++ runtime
- fputs ( "BUILTIN_CXXINCLUDES+= $(TARGET_CPPFLAGS)\n", fMakefile );
-
- // TODO: linker flags
+ fprintf ( fMakefile, "PROJECT_RCFLAGS := $(PROJECT_CINCLUDES) $(PROJECT_CDEFINES)\n" );
+ fprintf ( fMakefile, "PROJECT_WIDLFLAGS := $(PROJECT_CINCLUDES) $(PROJECT_CDEFINES)\n" );
fprintf ( fMakefile, "PROJECT_LFLAGS := '$(shell ${TARGET_CC} -print-libgcc-file-name)' %s\n", GenerateProjectLFLAGS ().c_str () );
fprintf ( fMakefile, "PROJECT_LPPFLAGS := '$(shell ${TARGET_CPP} -print-file-name=libstdc++.a)' '$(shell ${TARGET_CPP} -print-file-name=libgcc.a)' '$(shell ${TARGET_CPP} -print-file-name=libmingw32.a)' '$(shell ${TARGET_CPP} -print-file-name=libmingwex.a)' '$(shell ${TARGET_CPP} -print-file-name=libcoldname.a)'\n" );
/* hack to get libgcc_eh.a, should check mingw version or something */
{
fprintf ( fMakefile, "PROJECT_LPPFLAGS += '$(shell ${TARGET_CPP} -print-file-name=libgcc_eh.a)'\n" );
}
-
- // TODO: use symbolic names for module types
- for ( size_t i = 0; i < sizeof(ModuleHandlerInformations) / sizeof(ModuleHandlerInformations[0]); ++ i )
- {
- if ( ModuleHandlerInformations[i].cflags && ModuleHandlerInformations[i].cflags[0] )
- {
- fprintf ( fMakefile,
- "MODULETYPE%d_%sFLAGS:=%s\n",
- i,
- "C",
- ModuleHandlerInformations[i].cflags );
- }
-
- if ( ModuleHandlerInformations[i].cflags && ModuleHandlerInformations[i].cflags[0] )
- {
- fprintf ( fMakefile,
- "MODULETYPE%d_%sFLAGS:=%s\n",
- i,
- "CXX",
- ModuleHandlerInformations[i].cflags );
- }
-
- if ( ModuleHandlerInformations[i].nasmflags && ModuleHandlerInformations[i].nasmflags[0] )
- {
- fprintf ( fMakefile,
- "MODULETYPE%d_%sFLAGS:=%s\n",
- i,
- "NASM",
- ModuleHandlerInformations[i].nasmflags );
- }
- }
-
+ fprintf ( fMakefile, "PROJECT_GCCOPTIONS += -Wall\n" );
+ fprintf ( fMakefile, "ifneq ($(OARCH),)\n" );
+ fprintf ( fMakefile, "PROJECT_GCCOPTIONS += -march=$(OARCH)\n" );
+ fprintf ( fMakefile, "endif\n" );
+ fprintf ( fMakefile, "ifneq ($(TUNE),)\n" );
+ fprintf ( fMakefile, "PROJECT_GCCOPTIONS += -mtune=$(TUNE)\n" );
+ fprintf ( fMakefile, "endif\n" );
+ fprintf ( fMakefile, "PROJECT_CFLAGS = $(PROJECT_GCCOPTIONS) $(PROJECT_GCC_CFLAGS)\n" );
+ fprintf ( fMakefile, "PROJECT_CXXFLAGS = $(PROJECT_GCCOPTIONS) $(PROJECT_GCC_CXXFLAGS)\n" );
fprintf ( fMakefile, "\n" );
}
void CreateMakefile ();
void CloseMakefile () const;
void GenerateHeader () const;
- void GenerateGlobalProperties ( const char* assignmentOperation,
- const IfableData& data ) const;
+ void GenerateProjectCFlagsMacro ( const char* assignmentOperation,
+ const IfableData& data ) const;
+ void GenerateGlobalCFlagsAndProperties ( const char* op,
+ const IfableData& data ) const;
+ void GenerateProjectGccOptionsMacro ( const char* assignmentOperation,
+ IfableData& data ) const;
+ void GenerateProjectGccOptions ( const char* assignmentOperation,
+ IfableData& data ) const;
std::string GenerateProjectLFLAGS () const;
void GenerateDirectories ();
void GenerateGlobalVariables () const;
module.name.c_str () );
}
-static
-const char * const CompilerPrefixTable [ CompilerTypesCount ] =
-{
- "C",
- "CXX",
- "CPP",
- "AS",
- "MIDL",
- "RC",
- "NASM",
-};
-
-/* static */ void
-MingwModuleHandler::GenerateParameters (
- const char* prefix,
- const char* assignmentOperation,
- const IfableData& data )
-{
- for ( unsigned type = CompilerTypeCC; type < CompilerTypesCount; ++ type )
- {
- CompilerType compiler = static_cast < CompilerType > ( type );
-
- // Includes
- std::string includes = GenerateIncludeParametersFromVector ( data.includes, compiler );
-
- if ( includes.size() )
- {
- fprintf ( fMakefile,
- "%s_%sINCLUDES%s%s\n",
- prefix,
- CompilerPrefixTable [ compiler ],
- assignmentOperation,
- includes.c_str () );
- }
-
- // Defines
- std::string defines = GenerateDefineParametersFromVector ( data.defines, compiler );
-
- if ( defines.size() )
- {
- fprintf ( fMakefile,
- "%s_%sDEFINES%s%s\n",
- prefix,
- CompilerPrefixTable [ compiler ],
- assignmentOperation,
- defines.c_str () );
- }
-
- // Flags
- std::string flags = GenerateCompilerParametersFromVector ( data.compilerFlags, compiler );
-
- if ( flags.size() )
- {
- fprintf ( fMakefile,
- "%s_%sFLAGS%s%s\n",
- prefix,
- CompilerPrefixTable [ compiler ],
- assignmentOperation,
- flags.c_str () );
- }
- }
-}
-
/* static */ string
MingwModuleHandler::GenerateGccDefineParametersFromVector (
const vector<Define*>& defines,
Define& define = *defines[i];
if (used_defs.find(define.name) != used_defs.end())
continue;
- if (define.redefine)
- {
- if (parameters.length () > 0)
- parameters += " ";
- parameters += "-U";
- parameters += define.name;
- }
if (parameters.length () > 0)
parameters += " ";
- if (define.arguments.length ())
+ if (define.name.find('(') != string::npos)
parameters += "$(QT)";
parameters += "-D";
parameters += define.name;
- parameters += define.arguments;
if (define.value.length () > 0)
{
parameters += "=";
parameters += define.value;
}
- if (define.arguments.length ())
+ if (define.name.find('(') != string::npos)
parameters += "$(QT)";
used_defs.insert(used_defs.begin(),define.name);
}
return parameters;
}
-/* static */ string
-MingwModuleHandler::GenerateDefineParametersFromVector (
- const std::vector<Define*>& defines,
- CompilerType compiler )
-{
- string parameters;
-
- for ( size_t i = 0; i < defines.size (); i++ )
- {
- Define& define = *defines[i];
- if (!define.IsCompilerSet (compiler))
- continue;
- if (define.redefine)
- {
- if (parameters.length () > 0)
- parameters += " ";
- parameters += "-U";
- parameters += define.name;
- }
- if (parameters.length () > 0)
- parameters += " ";
- if (define.arguments.length ())
- parameters += "$(QT)";
- parameters += "-D";
- parameters += define.name;
- parameters += define.arguments;
- if (define.value.length () > 0)
- {
- parameters += "=";
- parameters += define.value;
- }
- if (define.arguments.length ())
- parameters += "$(QT)";
- }
- return parameters;
-}
-
string
MingwModuleHandler::ConcatenatePaths (
const string& path1,
}
/* static */ string
-MingwModuleHandler::GenerateIncludeParametersFromVector ( const vector<Include*>& includes, const CompilerType type )
+MingwModuleHandler::GenerateGccIncludeParametersFromVector ( const vector<Include*>& includes )
{
string parameters, path_prefix;
for ( size_t i = 0; i < includes.size (); i++ )
{
Include& include = *includes[i];
- if ( include.IsCompilerSet( type ) )
- parameters += " -I" + backend->GetFullPath ( *include.directory );
+ if ( parameters.length () > 0 )
+ parameters += " ";
+ parameters += "-I" + backend->GetFullPath ( *include.directory );
}
return parameters;
}
-/* static */ string
-MingwModuleHandler::GenerateCompilerParametersFromVector ( const vector<CompilerFlag*>& compilerFlags, const CompilerType type )
+string
+MingwModuleHandler::GenerateCompilerParametersFromVector ( const vector<CompilerFlag*>& compilerFlags, const CompilerType type ) const
{
string parameters;
for ( size_t i = 0; i < compilerFlags.size (); i++ )
{
CompilerFlag& compilerFlag = *compilerFlags[i];
- if ( compilerFlag.IsCompilerSet( type ) )
+ if ( compilerFlag.compiler == type )
parameters += " " + compilerFlag.flag;
}
return parameters;
return GenerateLinkerParametersFromVector ( module.linkerFlags );
}
+void
+MingwModuleHandler::GenerateMacro (
+ const char* assignmentOperation,
+ const string& macro,
+ const IfableData& data,
+ set<const Define *> *used_defs,
+ bool generatingCompilerMacro )
+{
+ size_t i;
+ bool generateAssignment;
+
+ generateAssignment = (use_pch && module.pch != NULL ) || data.includes.size () > 0 || data.defines.size () > 0;
+ if ( generatingCompilerMacro )
+ generateAssignment |= data.compilerFlags.size () > 0;
+ if ( generateAssignment )
+ {
+ fprintf ( fMakefile,
+ "%s %s",
+ macro.c_str(),
+ assignmentOperation );
+ }
+
+ const FileLocation *pchFilename = GetPrecompiledHeaderFilename ();
+ if ( pchFilename )
+ {
+ fprintf ( fMakefile,
+ " -I%s",
+ backend->GetFullPath ( *pchFilename ).c_str () );
+ delete pchFilename;
+ }
+
+ if ( generatingCompilerMacro )
+ {
+ string compilerParameters = GenerateCompilerParametersFromVector ( data.compilerFlags, CompilerTypeDontCare );
+ if ( compilerParameters.size () > 0 )
+ {
+ fprintf (
+ fMakefile,
+ "%s",
+ compilerParameters.c_str () );
+ }
+ }
+ for ( i = 0; i < data.includes.size(); i++ )
+ {
+ const Include& include = *data.includes[i];
+ const FileLocation* includeDirectory = include.directory;
+ fprintf (
+ fMakefile,
+ " -I%s",
+ backend->GetFullPath ( *includeDirectory ).c_str() );
+ }
+ for ( i = 0; i < data.defines.size(); i++ )
+ {
+ const Define& define = *data.defines[i];
+ if ( used_defs )
+ {
+ set<const Define *>::const_iterator last_define;
+ for (last_define = used_defs->begin ();
+ last_define != used_defs->end ();
+ last_define++)
+ {
+ if ( (*last_define)->name != define.name )
+ continue;
+ if ( !define.overridable )
+ {
+ throw InvalidOperationException ( (*last_define)->node->location.c_str (),
+ 0,
+ "Invalid override of define '%s', already defined at %s",
+ define.name.c_str (),
+ define.node->location.c_str () );
+ }
+ if ( backend->configuration.Verbose )
+ printf("%s: Overriding '%s' already defined at %s\n",
+ (*last_define)->node->location.c_str (), define.name.c_str (),
+ define.node->location.c_str () );
+ break;
+ }
+ if ( last_define != used_defs->end () )
+ continue;
+ }
+ fprintf (
+ fMakefile,
+ " -D%s",
+ define.name.c_str() );
+ if (define.value.length () > 0)
+ fprintf (
+ fMakefile,
+ "=%s",
+ define.value.c_str() );
+ if ( used_defs )
+ used_defs->insert( used_defs->begin (), &define );
+ }
+ if ( generateAssignment )
+ {
+ fprintf ( fMakefile, "\n" );
+ }
+}
+
void
MingwModuleHandler::GenerateMacros (
const char* assignmentOperation,
const vector<LinkerFlag*>* linkerFlags,
set<const Define *>& used_defs )
{
+ fprintf ( fMakefile, "# MACROS\n" );
+ GenerateMacro ( assignmentOperation,
+ commonflagsMacro,
+ data,
+ &used_defs,
+ true );
+ GenerateMacro ( assignmentOperation,
+ windresflagsMacro,
+ data,
+ NULL,
+ false );
+
if ( linkerFlags != NULL )
{
string linkerParameters = GenerateLinkerParametersFromVector ( *linkerFlags );
{
size_t i;
+ fprintf ( fMakefile, "# SOURCE MACROS\n" );
const vector<CompilationUnit*>& compilationUnits = data.compilationUnits;
vector<const FileLocation *> headers;
if ( compilationUnits.size () > 0 )
vector<const FileLocation *> headers;
vector<const FileLocation *> mcheaders;
vector<const FileLocation *> mcresources;
+ fprintf ( fMakefile, "# OBJECT MACROS\n" );
if ( compilationUnits.size () > 0 )
{
for ( i = 0; i < compilationUnits.size (); i++ )
return new FileLocation( IntermediateDirectory, dlldata_path, module.name + ".dlldata.c" );
}
-const FileLocation*
-MingwModuleHandler::GetPrecompiledHeaderPath () const
-{
- if ( !module.pch || !use_pch )
- return NULL;
- return new FileLocation ( IntermediateDirectory,
- module.pch->file->relative_path,
- ".gch_" + module.name );
-}
-
+/* caller needs to delete the returned object */
const FileLocation*
MingwModuleHandler::GetPrecompiledHeaderFilename () const
{
module.pch->file->name + ".gch" );
}
-Rule windresRule ( "$(eval $(call RBUILD_WRC_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule arRule1 ( "$(intermediate_path_noext).a: $($(module_name)_OBJS) $(dependencies) | $(intermediate_dir)\n",
+ "$(intermediate_path_noext).a",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule arRule2 ( "\t$(ECHO_AR)\n"
+ "\t${ar} -rc $@ $($(module_name)_OBJS) \n",
+ NULL );
+Rule arHostRule2 ( "\t$(ECHO_HOSTAR)\n"
+ "\t${host_ar} -rc $@ $($(module_name)_OBJS)\n",
+ NULL );
+Rule gasRule ( "$(source): ${$(module_name)_precondition}\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_unique).o.d: $(source) | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -x assembler-with-cpp -MF $@ -D__ASM__ $($(module_name)_CFLAGS) -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_unique).o.d\n"
+ "endif\n"
+ "$(intermediate_path_unique).o: $(source)$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_unique).o.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_GAS)\n"
+ "\t${gcc} -x assembler-with-cpp -o $@ -D__ASM__ $($(module_name)_CFLAGS) -c $<\n",
+ "$(intermediate_path_unique).o",
+ "$(intermediate_path_unique).o.d",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule bootRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(module_output): $(source) $(dependencies) | $(OUTPUT)$(SEP)$(source_dir)\n"
+ "\t$(ECHO_NASM)\n"
+ "\t$(Q)${nasm} -f win32 $< -o $@ $($(module_name)_NASMFLAGS)\n",
+ "$(OUTPUT)$(SEP)$(source_dir)$(SEP)", NULL );
+Rule nasmRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_unique).o: $(source) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_NASM)\n"
+ "\t$(Q)${nasm} -f win32 $< -o $@ $($(module_name)_NASMFLAGS)\n",
+ "$(intermediate_path_unique).o",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule windresRule ( "$(source): ${$(module_name)_precondition}\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_unique).coff.d: $(source) | $(intermediate_dir) $(TEMPORARY)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -xc -M -MP -MT $@ -DRC_INVOKED ${$(module_name)_RCFLAGS} $(source) -MF $@\n"
+ "-include $(intermediate_path_unique).coff.d\n"
+ "endif\n"
+ "$(intermediate_path_unique).coff: $(source)$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_unique).coff.d) $(dependencies) $(WRC_TARGET) | $(intermediate_dir) $(TEMPORARY)\n"
+ "\t$(ECHO_WRC)\n"
+ "\t${gcc} -xc -E -DRC_INVOKED ${$(module_name)_RCFLAGS} $(source) > $(TEMPORARY)$(SEP)$(module_name).$(source_name_noext).rci.tmp\n"
+ "\t$(Q)$(WRC_TARGET) ${$(module_name)_RCFLAGS} $(TEMPORARY)$(SEP)$(module_name).$(source_name_noext).rci.tmp $(TEMPORARY)$(SEP)$(module_name).$(source_name_noext).res.tmp\n"
+ "\t-@${rm} $(TEMPORARY)$(SEP)$(module_name).$(source_name_noext).rci.tmp 2>$(NUL)\n"
+ "\t${windres} $(TEMPORARY)$(SEP)$(module_name).$(source_name_noext).res.tmp -o $@\n"
+ "\t-@${rm} $(TEMPORARY)$(SEP)$(module_name).$(source_name_noext).res.tmp 2>$(NUL)\n",
"$(intermediate_path_unique).coff",
- "$(intermediate_path_unique).res",
- "$(intermediate_path_unique).res.d",
+ "$(intermediate_path_unique).coff.d",
"$(intermediate_dir)$(SEP)", NULL );
-Rule winebuildPRule ( "$(eval $(call RBUILD_WINEBUILD_WITH_CPP_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags),$(module_dllname)))\n",
+Rule wmcRule ( "$(intermediate_path_noext).rc $(INTERMEDIATE)$(SEP)include$(SEP)reactos$(SEP)$(source_name_noext).h: $(WMC_TARGET) $(source) | $(intermediate_dir)\n"
+ "\t$(ECHO_WMC)\n"
+ "\t$(Q)$(WMC_TARGET) -i -H $(INTERMEDIATE)$(SEP)include$(SEP)reactos$(SEP)$(source_name_noext).h -o $(intermediate_path_noext).rc $(source)\n",
+ "$(intermediate_path_noext).rc",
+ "$(INTERMEDIATE)$(SEP)include$(SEP)reactos$(SEP)$(source_name_noext).h",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule winebuildPDefRule ( "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_unique).spec.d: $(source) | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -xc -M -MP -MT $@ ${$(module_name)_RCFLAGS} $(source) -MF $@\n\n"
+ "-include $(intermediate_path_unique).spec.d\n"
+ "endif\n"
+ "$(intermediate_path_unique).spec: $(source)$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_unique).spec.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CPP)\n"
+ "\t${gcc} -xc -E ${$(module_name)_RCFLAGS} $(source) > $(intermediate_path_unique).spec\n\n"
+ "$(intermediate_path_unique).auto.def: $(intermediate_path_unique).spec $(WINEBUILD_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WINEBLD)\n"
+ "\t$(Q)$(WINEBUILD_TARGET) $(WINEBUILD_FLAGS) -o $(intermediate_path_unique).auto.def --def -E $(intermediate_path_unique).spec --filename $(module_dllname)\n\n",
+ "$(intermediate_path_unique).spec",
+ "$(intermediate_path_unique).spec.d",
+ "$(intermediate_path_unique).auto.def",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule winebuildPRule ( "$(intermediate_path_unique).stubs.c: $(intermediate_path_unique).spec $(WINEBUILD_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WINEBLD)\n"
+ "\t$(Q)$(WINEBUILD_TARGET) $(WINEBUILD_FLAGS) -o $@ --pedll $(intermediate_path_unique).spec --filename $(module_dllname)\n\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_unique).stubs.o.d: $(intermediate_path_unique).stubs.c | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -MF $@ $($(module_name)_CFLAGS)$(compiler_flags) -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_unique).stubs.o.d\n"
+ "endif\n"
+ "$(intermediate_path_unique).stubs.o: $(intermediate_path_unique).stubs.c$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_unique).stubs.o.d) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -c $<\n",
"$(intermediate_path_unique).spec",
- "$(intermediate_path_unique).spec.d",
- "$(intermediate_path_unique).auto.def",
"$(intermediate_path_unique).stubs.c",
"$(intermediate_path_unique).stubs.o",
"$(intermediate_path_unique).stubs.o.d",
"$(intermediate_dir)$(SEP)", NULL );
-Rule winebuildRule ( "$(eval $(call RBUILD_WINEBUILD_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags),$(module_dllname)))\n",
- "$(intermediate_path_unique).auto.def",
+Rule winebuildDefRule ( "$(intermediate_path_unique).auto.def: $(source) $(dependencies) $(WINEBUILD_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WINEBLD)\n"
+ "\t$(Q)$(WINEBUILD_TARGET) $(WINEBUILD_FLAGS) -o $(intermediate_path_unique).auto.def --def -E $(source) --filename $(module_dllname)\n\n",
+ "$(intermediate_path_noext).spec",
+ "$(intermediate_path_unique).auto.def",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule winebuildRule ( "$(intermediate_path_unique).stubs.c: $(source) $(WINEBUILD_TARGET)\n"
+ "\t$(ECHO_WINEBLD)\n"
+ "\t$(Q)$(WINEBUILD_TARGET) $(WINEBUILD_FLAGS) -o $@ --pedll $(source) --filename $(module_dllname)\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_unique).stubs.o.d: $(intermediate_path_unique).stubs.c | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -MF $@ $($(module_name)_CFLAGS)$(compiler_flags) -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_unique).stubs.o.d\n"
+ "endif\n"
+ "$(intermediate_path_unique).stubs.o: $(intermediate_path_unique).stubs.c$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_unique).stubs.o.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -c $<\n",
"$(intermediate_path_unique).stubs.c",
"$(intermediate_path_unique).stubs.o",
"$(intermediate_path_unique).stubs.o.d",
"$(intermediate_dir)$(SEP)", NULL );
-Rule gasRule ( "$(eval $(call RBUILD_GAS_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_path_unique).o",
- "$(intermediate_path_unique).o.d", NULL );
-Rule gccRule ( "$(eval $(call RBUILD_GCC_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_path_unique).o",
- "$(intermediate_path_unique).o.d", NULL );
-Rule gccHostRule ( "$(eval $(call RBUILD_HOST_GCC_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_path_unique).o", NULL );
-Rule gppRule ( "$(eval $(call RBUILD_GPP_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_path_unique).o",
- "$(intermediate_path_unique).o.d", NULL );
-Rule gppHostRule ( "$(eval $(call RBUILD_HOST_GPP_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_path_unique).o", NULL );
-Rule widlHeaderRule ( "$(eval $(call RBUILD_WIDL_HEADER_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule widlHeaderRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_noext).h: $(source) $(dependencies) $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) -h -H $(intermediate_path_noext).h $(source)\n",
"$(intermediate_path_noext).h",
"$(intermediate_dir)$(SEP)", NULL );
-Rule widlServerRule ( "$(eval $(call RBUILD_WIDL_SERVER_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule widlInterfaceRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_noext)_i.c: $(source) $(dependencies) $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) -u -U $(intermediate_path_noext)_i.c $(source)\n"
+ "$(intermediate_path_noext)_i.o: $(intermediate_path_noext)_i.c $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -c $<\n",
+ "$(intermediate_path_noext)_i.c",
+ "$(intermediate_path_noext)_i.o",
+ "$(intermediate_dir)$(SEP)", NULL );
+Rule widlServerRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_noext)_s.c $(intermediate_path_noext)_s.h: $(source) $(dependencies) $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) -h -H $(intermediate_path_noext)_s.h -s -S $(intermediate_path_noext)_s.c $(source)\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_noext)_s.o.d: $(intermediate_path_noext)_s.c | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -MF $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_noext)_s.o.d\n"
+ "endif\n"
+ "$(intermediate_path_noext)_s.o: $(intermediate_path_noext)_s.c $(intermediate_path_noext)_s.h$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_noext)_s.o.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -c $<\n",
"$(intermediate_path_noext)_s.h",
"$(intermediate_path_noext)_s.c",
"$(intermediate_path_noext)_s.o",
+ "$(intermediate_path_noext)_s.o.d",
"$(intermediate_dir)$(SEP)", NULL );
-Rule widlClientRule ( "$(eval $(call RBUILD_WIDL_CLIENT_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule widlClientRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_noext)_c.c $(intermediate_path_noext)_c.h: $(source) $(dependencies) $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) -h -H $(intermediate_path_noext)_c.h -c -C $(intermediate_path_noext)_c.c $(source)\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_noext)_c.o.d: $(intermediate_path_noext)_c.c | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -MF $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_noext)_c.o.d\n"
+ "endif\n"
+ "$(intermediate_path_noext)_c.o: $(intermediate_path_noext)_c.c $(intermediate_path_noext)_c.h$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_noext)_c.o.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -c $<\n",
"$(intermediate_path_noext)_c.h",
"$(intermediate_path_noext)_c.c",
"$(intermediate_path_noext)_c.o",
+ "$(intermediate_path_noext)_c.o.d",
"$(intermediate_dir)$(SEP)", NULL );
-Rule widlProxyRule ( "$(eval $(call RBUILD_WIDL_PROXY_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule widlProxyRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_noext)_p.c $(intermediate_path_noext)_p.h: $(source) $(dependencies) $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) -h -H $(intermediate_path_noext)_p.h -p -P $(intermediate_path_noext)_p.c $(source)\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_noext)_p.o.d: $(intermediate_path_noext)_p.c | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -MF $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_noext)_p.o.d\n"
+ "endif\n"
+ "$(intermediate_path_noext)_p.o: $(intermediate_path_noext)_p.c $(intermediate_path_noext)_p.h$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_noext)_p.o.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -fno-unit-at-a-time -c $<\n",
"$(intermediate_path_noext)_p.h",
"$(intermediate_path_noext)_p.c",
"$(intermediate_path_noext)_p.o",
+ "$(intermediate_path_noext)_p.o.d",
"$(intermediate_dir)$(SEP)", NULL );
-Rule widlInterfaceRule ( "$(eval $(call RBUILD_WIDL_INTERFACE_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_path_noext)_i.c",
- "$(intermediate_path_noext)_i.o",
- "$(intermediate_dir)$(SEP)", NULL );
-Rule widlDlldataRule ( "$(eval $(call RBUILD_WIDL_DLLDATA_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags),$(bare_dependencies)))\n",
- "$(intermediate_path_noext).o", NULL );
-Rule widlTlbRule ( "$(eval $(call RBUILD_WIDL_TLB_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule widlDlldataRule ( "$(source): $(dependencies) ${$(module_name)_precondition} $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) --dlldata-only --dlldata=$(source) $(bare_dependencies)\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_path_noext).o.d: $(source) | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t${gcc} -MF $@ $($(module_name)_CFLAGS)$(compiler_flags) -M -MP -MT $@ $<\n"
+ "-include $(intermediate_path_noext).o.d\n"
+ "endif\n"
+ "$(intermediate_path_noext).o: $(source)$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_path_noext).o.d) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_CC)\n"
+ "\t${gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -c $<\n",
+ "$(intermediate_path_noext).o",
+ "$(intermediate_path_noext).o.d", NULL );
+Rule widlTlbRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_dir)$(SEP)$(module_name).tlb: $(source) $(dependencies) $(WIDL_TARGET) | $(intermediate_dir)\n"
+ "\t$(ECHO_WIDL)\n"
+ "\t$(Q)$(WIDL_TARGET) $($(module_name)_WIDLFLAGS) -t -T $(intermediate_path_noext).tlb $(source)\n",
"$(intermediate_dir)$(SEP)", NULL );
-Rule pchRule ( "$(eval $(call RBUILD_GCC_PCH_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+Rule gccRule ( "$(eval $(call RBUILD_GCC_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+ "$(intermediate_path_unique).o",
+ "$(intermediate_path_unique).o.d", NULL );
+Rule gccHostRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_unique).o: $(source) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_HOSTCC)\n"
+ "\t${host_gcc} -o $@ $($(module_name)_CFLAGS)$(compiler_flags) -c $<\n",
+ "$(intermediate_path_unique).o", NULL );
+Rule gppRule ( "$(eval $(call RBUILD_GPP_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
+ "$(intermediate_path_unique).o",
+ "$(intermediate_path_unique).o.d", NULL );
+Rule gppHostRule ( "$(source): ${$(module_name)_precondition}\n"
+ "$(intermediate_path_unique).o: $(source) $(dependencies) | $(intermediate_dir)\n"
+ "\t$(ECHO_HOSTCC)\n"
+ "\t${host_gpp} -o $@ $($(module_name)_CXXFLAGS)$(compiler_flags) -c $<\n",
+ "$(intermediate_path_unique).o", NULL );
+Rule pchRule ( "$(source): ${$(module_name)_precondition}\n"
+ "ifeq ($(ROS_BUILDDEPS),full)\n"
+ "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch.d: $(source) | $(intermediate_dir)\n"
+ "\t$(ECHO_DEPENDS)\n"
+ "\t$(pch_cc) -MF $@ $(pch_ccflags)$(compiler_flags) -x $(pch_language) -M -MP -MT $@ $<\n"
+ "-include $(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch.d\n"
+ "endif\n"
+ "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch: $(source)$(if $(subst _full,,_$(ROS_BUILDDEPS)),, $(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch.d) $(dependencies) | $(intermediate_dir)$(SEP).gch_$(module_name)\n"
+ "\t$(ECHO_PCH)\n"
+ "\t$(pch_cc) -o $@ $(pch_ccflags)$(compiler_flags) -x $(pch_language) -c $<\n",
"$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch",
- "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch.d",
- "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)", NULL );
-Rule pchCxxRule ( "$(eval $(call RBUILD_GPP_PCH_RULE,$(module_name),$(source),$(dependencies),$(compiler_flags)))\n",
- "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch",
- "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch.d",
- "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)", NULL );
-Rule bootRule ( "$(eval $(call RBUILD_NASM,$(module_name),$(source),$(dependencies),,$(module_output)))\n",
- "$(module_output)",
- "$(OUTPUT)$(SEP)$(source_dir)$(SEP)", NULL );
-Rule nasmRule ( "$(eval $(call RBUILD_NASM,$(module_name),$(source),$(dependencies),,$(intermediate_path_unique).o))\n",
- "$(intermediate_path_unique).o",
- "$(intermediate_dir)$(SEP)", NULL );
-
-/* TODO: move these to rules.mak */
-Rule wmcRule ( "$(intermediate_path_noext).rc $(INTERMEDIATE)$(SEP)include$(SEP)reactos$(SEP)$(source_name_noext).h: $(WMC_TARGET) $(source) | $(intermediate_dir)\n"
- "\t$(ECHO_WMC)\n"
- "\t$(Q)$(WMC_TARGET) -i -H $(INTERMEDIATE)$(SEP)include$(SEP)reactos$(SEP)$(source_name_noext).h -o $(intermediate_path_noext).rc $(source)\n",
- "$(intermediate_path_noext).rc",
- "$(INTERMEDIATE)$(SEP)include$(SEP)reactos$(SEP)$(source_name_noext).h",
- "$(intermediate_dir)$(SEP)", NULL );
-/* TODO: if possible, move these to rules.mak */
-Rule arRule1 ( "$(intermediate_path_noext).a: $($(module_name)_OBJS) $(dependencies) | $(intermediate_dir)\n",
- "$(intermediate_path_noext).a",
- "$(intermediate_dir)$(SEP)", NULL );
-Rule arRule2 ( "\t$(ECHO_AR)\n"
- "\t${ar} -rc $@ $($(module_name)_OBJS)\n",
- NULL );
-Rule arHostRule2 ( "\t$(ECHO_HOSTAR)\n"
- "\t${host_ar} -rc $@ $($(module_name)_OBJS)\n",
- NULL );
-
+ "$(intermediate_dir)$(SEP).gch_$(module_name)$(SEP)$(source_name).gch.d", NULL );
Rule emptyRule ( "", NULL );
void
const FileLocation *pchFilename = GetPrecompiledHeaderFilename ();
string dependencies = extraDependencies;
+ string flags;
+ string extension = GetExtension ( *sourceFile );
+ if ( extension == ".cc" || extension == ".cpp" || extension == ".cxx" )
+ flags = GenerateCompilerParametersFromVector ( module.non_if_data.compilerFlags, CompilerTypeCPP );
+ else
+ flags = GenerateCompilerParametersFromVector ( module.non_if_data.compilerFlags, CompilerTypeCC );
+
if ( pchFilename )
{
dependencies += " " + backend->GetFullName ( *pchFilename );
if ( rpcDependencies.size () > 0 )
dependencies += " " + v2s ( backend, rpcDependencies, 5 );
- rule->Execute ( fMakefile, backend, module, sourceFile, clean_files, dependencies );
+ rule->Execute ( fMakefile, backend, module, sourceFile, clean_files, dependencies, flags );
}
string
size_t i;
Rule *customRule = NULL;
+ fprintf ( fMakefile, "# COMMANDS\n" );
+
for ( i = 0; i < sizeof ( rules ) / sizeof ( rules[0] ); i++ )
{
if ( rules[i].host != HostDontCare && rules[i].host != ModuleHandlerInformations[module.type].DefaultHost )
{
GenerateCommands ( *compilationUnits[i],
moduleDependencies );
+ fprintf ( fMakefile,
+ "\n" );
}
vector<CompilationUnit*> sourceCompilationUnits;
}
CleanupCompilationUnitVector ( sourceCompilationUnits );
+ SpecFileType spec = IsSpecDefinitionFile ();
+
+ if ( spec )
+ {
+ Rule * defRule;
+
+ if (spec == PSpec)
+ defRule = &winebuildPRule;
+ else
+ defRule = &winebuildRule;
+
+ defRule->Execute ( fMakefile, backend, module, module.importLibrary->source, clean_files );
+ }
+
if ( module.type == RpcProxy )
{
widlDlldataRule.Execute ( fMakefile,
std::map<string, string> vars;
+ if ( ModuleHandlerInformations[module.type].DefaultHost == HostTrue )
+ vars["pch_cc"] = "${host_gcc}";
+ else
+ vars["pch_cc"] = "${gcc}";
+
+ if ( module.cplusplus )
+ {
+ vars["pch_language"] = "c++-header";
+ vars["pch_ccflags"] = cxxflagsMacro.c_str();
+ }
+ else
+ {
+ vars["pch_language"] = "c-header";
+ vars["pch_ccflags"] = cflagsMacro.c_str();
+ }
+
/* WIDL generated headers may be used */
string dependencies;
vector<FileLocation> rpcDependencies;
if ( rpcDependencies.size () > 0 )
dependencies = " " + v2s ( backend, rpcDependencies, 5 );
- if ( module.cplusplus )
- pchCxxRule.Execute ( fMakefile, backend, module, module.pch->file, clean_files, dependencies );
- else
- pchRule.Execute ( fMakefile, backend, module, module.pch->file, clean_files, dependencies );
-
+ pchRule.Execute ( fMakefile,
+ backend,
+ module,
+ module.pch->file,
+ clean_files,
+ dependencies,
+ GenerateCompilerParametersFromVector ( module.non_if_data.compilerFlags, module.cplusplus ? CompilerTypeCPP : CompilerTypeCC ).c_str(),
+ vars );
fprintf ( fMakefile, "\n" );
}
module.name.c_str () );
}
+string
+MingwModuleHandler::GetLinkingDependenciesMacro () const
+{
+ return ssprintf ( "$(%s_LINKDEPS)", module.name.c_str () );
+}
+
string
MingwModuleHandler::GetLibsMacro () const
{
}
string
-MingwModuleHandler::GetDebugFormat ()
+MingwModuleHandler::GetDebugFormat () const
{
if (Environment::GetArch() == "amd64")
{
{
sourcesMacro = ssprintf ( "%s_SOURCES", module.name.c_str ());
- if ( module.type == RpcProxy || module.type == Cabinet )
- GenerateSourceMacros ( module.non_if_data );
+ GenerateSourceMacros ( module.non_if_data );
// future references to the macro will be to get its values
sourcesMacro = ssprintf ("$(%s)", sourcesMacro.c_str ());
void
MingwModuleHandler::GenerateTargetMacro ()
{
+ fprintf ( fMakefile, "# TARGET MACRO\n" );
fprintf ( fMakefile,
"%s := %s\n",
GetTargetMacro ( module, false ).c_str (),
{
set<const Define *> used_defs;
+ fprintf ( fMakefile, "# OTHER MACROS\n" );
+
+ commonflagsMacro = ssprintf ("%s_COMMONFLAGS", module.name.c_str ());
+ cflagsMacro = ssprintf ("%s_CFLAGS", module.name.c_str ());
+ cxxflagsMacro = ssprintf ("%s_CXXFLAGS", module.name.c_str ());
+ nasmflagsMacro = ssprintf ("%s_NASMFLAGS", module.name.c_str ());
+ windresflagsMacro = ssprintf ("%s_RCFLAGS", module.name.c_str ());
+ widlflagsMacro = ssprintf ("%s_WIDLFLAGS", module.name.c_str ());
linkerflagsMacro = ssprintf ("%s_LFLAGS", module.name.c_str ());
libsMacro = ssprintf("%s_LIBS", module.name.c_str ());
+ linkDepsMacro = ssprintf ("%s_LINKDEPS", module.name.c_str ());
- const FileLocation * pchPath = GetPrecompiledHeaderPath ();
+ GenerateMacros (
+ "=",
+ module.non_if_data,
+ &module.linkerFlags,
+ used_defs );
- if ( pchPath )
+ if ( ModuleHandlerInformations[module.type].DefaultHost == HostTrue )
{
- string pchPathStr = backend->GetFullName ( *pchPath );
- delete pchPath;
+ GenerateMacros("+=", module.project.host_non_if_data, NULL, used_defs);
+ }
+ else
+ {
+ GenerateMacros (
+ "+=",
+ module.project.non_if_data,
+ NULL,
+ used_defs );
+ }
- fprintf ( fMakefile,
- "%s_%sINCLUDES+= -I%s\n",
- module.name.c_str(),
- CompilerPrefixTable[CompilerTypeCC],
- pchPathStr.c_str() );
+ if ( IsSpecDefinitionFile() )
+ {
+ vector<FileLocation> s;
+ GetSpecImplibDependencies ( s, module.importLibrary->source );
- fprintf ( fMakefile,
- "%s_%sINCLUDES+= -I%s\n",
- module.name.c_str(),
- CompilerPrefixTable[CompilerTypeCXX],
- pchPathStr.c_str() );
+ fprintf (
+ fMakefile,
+ "%s +=",
+ linkDepsMacro.c_str() );
+ for ( size_t i = 0; i < s.size(); i++ )
+ fprintf ( fMakefile,
+ " %s",
+ backend->GetFullName ( s[i] ).c_str () );
+ fprintf ( fMakefile, "\n" );
}
- const char * toolPrefix = "";
-
+ string globalCflags = " ";
+ globalCflags += ssprintf ("$(%s)", commonflagsMacro.c_str ());
+ if ( ModuleHandlerInformations[module.type].DefaultHost == HostFalse )
+ {
+ if ( module.dynamicCRT )
+ globalCflags += " -D_DLL -D__USE_CRTIMP";
+ }
+ else
+ globalCflags += " -Wall -Wpointer-arith";
+ globalCflags += " -g" + MingwModuleHandler::GetDebugFormat ();
+ if ( backend->usePipe )
+ globalCflags += " -pipe";
+ if ( !module.allowWarnings )
+ globalCflags += " -Werror";
if ( ModuleHandlerInformations[module.type].DefaultHost == HostTrue )
- toolPrefix = "HOST_";
+ {
+ if ( module.cplusplus )
+ globalCflags += " $(HOST_CPPFLAGS)";
+ else
+ globalCflags += " -Wno-strict-aliasing $(HOST_CFLAGS)";
+ }
+ else
+ {
+ if ( module.cplusplus )
+ {
+ globalCflags += " $(TARGET_CPPFLAGS)";
+ }
+ else
+ globalCflags += " -nostdinc";
+ }
+
+ // Always force disabling of sibling calls optimisation for GCC
+ // (TODO: Move to version-specific once this bug is fixed in GCC)
+ globalCflags += " -fno-optimize-sibling-calls";
- // FIXME: this is very ugly and generates lots of useless entries
- for ( unsigned type = CompilerTypeCC; type < CompilerTypesCount; ++ type )
+ if ( ModuleHandlerInformations[module.type].DefaultHost == HostFalse )
{
- string flags;
+ fprintf (
+ fMakefile,
+ "%s +=%s\n",
+ cflagsMacro.c_str (),
+ (" $(PROJECT_CFLAGS)" + globalCflags).c_str () );
- if ( module.dynamicCRT )
- flags += ssprintf ( " $(%s%sFLAG_CRTDLL)", toolPrefix, CompilerPrefixTable[type] );
+ fprintf (
+ fMakefile,
+ "%s +=%s\n",
+ cxxflagsMacro.c_str (),
+ (" $(PROJECT_CXXFLAGS)" + globalCflags).c_str () );
- // FIXME: this duplicates the flag for CPP and C/CXX
- if ( !module.allowWarnings )
- flags += ssprintf ( " $(%s%sFLAG_WERROR)", toolPrefix, CompilerPrefixTable[type] );
+ fprintf (
+ fMakefile,
+ "%s += $(PROJECT_RCFLAGS)\n",
+ windresflagsMacro.c_str () );
- if ( module.isUnicode )
- flags += ssprintf ( " $(%s%sFLAG_UNICODE)", toolPrefix, CompilerPrefixTable[type] );
+ fprintf (
+ fMakefile,
+ "%s += $(PROJECT_WIDLFLAGS) -I%s\n",
+ widlflagsMacro.c_str (),
+ module.output->relative_path.c_str () );
- if ( flags.size() )
- {
- fprintf ( fMakefile,
- "%s_%sFLAGS+=%s\n",
- module.name.c_str(),
- CompilerPrefixTable[type],
- flags.c_str() );
- }
+ fprintf (
+ fMakefile,
+ "%s_LFLAGS := $(PROJECT_LFLAGS) $(%s_LFLAGS)\n",
+ module.name.c_str (),
+ module.name.c_str () );
}
+ else
+ {
+ fprintf (
+ fMakefile,
+ "%s +=%s\n",
+ cflagsMacro.c_str (),
+ globalCflags.c_str () );
- GenerateParameters ( module.name.c_str(), "+=", module.non_if_data );
+ fprintf (
+ fMakefile,
+ "%s +=%s\n",
+ cxxflagsMacro.c_str (),
+ globalCflags.c_str () );
- const char *linkerflags = ModuleHandlerInformations[module.type].linkerflags;
- if ( strlen( linkerflags ) > 0 )
+ fprintf (
+ fMakefile,
+ "%s_LFLAGS += $(HOST_LFLAGS)\n",
+ module.name.c_str () );
+ }
+
+ fprintf (
+ fMakefile,
+ "%s += $(%s)\n",
+ linkDepsMacro.c_str (),
+ libsMacro.c_str () );
+
+ const char *cflags = ModuleHandlerInformations[module.type].cflags;
+ if ( strlen( cflags ) > 0 )
{
fprintf ( fMakefile,
"%s += %s\n\n",
- linkerflagsMacro.c_str (),
- linkerflags );
+ cflagsMacro.c_str (),
+ cflags );
+ fprintf ( fMakefile,
+ "%s += %s\n\n",
+ cxxflagsMacro.c_str (),
+ cflags );
}
- // FIXME: make rules for linker, move standard flags there
- if ( ModuleHandlerInformations[module.type].DefaultHost == HostFalse )
+ const char* nasmflags = ModuleHandlerInformations[module.type].nasmflags;
+ if ( strlen( nasmflags ) > 0 )
{
- if ( module.cplusplus )
- fprintf ( fMakefile,
- "%s+= $(PROJECT_LPPFLAGS)\n\n",
- linkerflagsMacro.c_str () );
- else
- fprintf ( fMakefile,
- "%s+= $(PROJECT_LFLAGS)\n\n",
- linkerflagsMacro.c_str () );
+ fprintf ( fMakefile,
+ "%s += %s\n\n",
+ nasmflagsMacro.c_str (),
+ nasmflags );
}
- GenerateMacros (
- "+=",
- module.non_if_data,
- &module.linkerFlags,
- used_defs );
+ const char *linkerflags = ModuleHandlerInformations[module.type].linkerflags;
+ if ( strlen( linkerflags ) > 0 )
+ {
+ fprintf ( fMakefile,
+ "%s += %s\n\n",
+ linkerflagsMacro.c_str (),
+ linkerflags );
+ }
fprintf ( fMakefile, "\n\n" );
+
+ // future references to the macros will be to get their values
+ commonflagsMacro = ssprintf ("$(%s)", commonflagsMacro.c_str ());
+ cflagsMacro = ssprintf ("$(%s)", cflagsMacro.c_str ());
+ cxxflagsMacro = ssprintf ("$(%s)", cxxflagsMacro.c_str ());
+ nasmflagsMacro = ssprintf ("$(%s)", nasmflagsMacro.c_str ());
+ widlflagsMacro = ssprintf ("$(%s)", widlflagsMacro.c_str ());
}
void
Rule * defRule;
if (spec == PSpec)
- defRule = &winebuildPRule;
+ defRule = &winebuildPDefRule;
else
- defRule = &winebuildRule;
+ defRule = &winebuildDefRule;
defRule->Execute ( fMakefile, backend, module, module.importLibrary->source, clean_files );
}
GetBasename ( file->name ) + "_" + module.name + ".stubs.c" ) );
}
+void
+MingwModuleHandler::GetSpecImplibDependencies (
+ vector<FileLocation>& dependencies,
+ const FileLocation *file ) const
+{
+ dependencies.push_back ( FileLocation ( IntermediateDirectory,
+ file->relative_path,
+ GetBasename ( file->name ) + "_" + module.name + ".auto.def" ) );
+}
+
void
MingwModuleHandler::GetMcObjectDependencies (
vector<FileLocation>& dependencies,
{
string targetMacro ( GetTargetMacro (module) );
string objectsMacro = GetObjectsMacro ( module );
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
string libsMacro = GetLibsMacro ();
GenerateRules ();
fprintf ( fMakefile, "%s: %s %s | %s\n",
targetMacro.c_str (),
objectsMacro.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
backend->GetFullPath ( *target_file ).c_str () );
fprintf ( fMakefile, "\t$(ECHO_HOSTLD)\n" );
fprintf ( fMakefile,
{
string targetMacro ( GetTargetMacro ( module ) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=native -entry=%s -image-base=%s",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro ( module ) );
string workingDirectory = GetWorkingDirectory ();
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=native -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000 -shared",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=native -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000 -shared",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=native -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=console -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000 -shared",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=console -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000 -shared",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=console -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
{
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=windows -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
void
MingwBootLoaderModuleHandler::GenerateBootLoaderModuleTarget ()
{
- fprintf ( fMakefile, "# BOOT LOADER MODULE TARGET\n" );
string targetName ( module.output->name );
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ();
module.name + ".junk.tmp" );
CLEAN_FILE ( junk_tmp );
string objectsMacro = GetObjectsMacro ( module );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateRules ();
+ fprintf ( fMakefile, "# BOOT LOADER MODULE TARGET\n" );
+
const FileLocation *target_file = GetTargetFilename ( module, NULL );
fprintf ( fMakefile, "%s: %s %s | %s\n",
targetMacro.c_str (),
objectsMacro.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
backend->GetFullPath ( *target_file ).c_str () );
fprintf ( fMakefile, "\t$(ECHO_LD)\n" );
"\t${gcc} -Wl,--subsystem,native -Wl,--section-start,startup=0x8000 -o %s %s %s %s\n",
backend->GetFullName ( junk_tmp ).c_str (),
objectsMacro.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
GetLinkerMacro ().c_str ());
}
else
"\t${gcc} -Wl,--subsystem,native -Wl,-Ttext,0x8000 -o %s %s %s %s\n",
backend->GetFullName ( junk_tmp ).c_str (),
objectsMacro.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
GetLinkerMacro ().c_str ());
}
fprintf ( fMakefile,
void
MingwBootProgramModuleHandler::GenerateBootProgramModuleTarget ()
{
- fprintf ( fMakefile, "# BOOT PROGRAM MODULE TARGET\n" );
-
string targetName ( module.output->name );
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ();
CLEAN_FILE ( junk_elf );
CLEAN_FILE ( junk_cpy );
string objectsMacro = GetObjectsMacro ( module );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
const Module *payload = module.project.LocateModule ( module.payload );
GenerateRules ();
+ fprintf ( fMakefile, "# BOOT PROGRAM MODULE TARGET\n" );
+
const FileLocation *target_file = GetTargetFilename ( module, NULL );
fprintf ( fMakefile, "%s: %s %s %s | %s\n",
targetMacro.c_str (),
objectsMacro.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
payload->name.c_str (),
backend->GetFullPath ( *target_file ).c_str () );
fprintf ( fMakefile, "\t${ld} $(%s_LINKFORMAT) %s %s -o %s\n",
module.buildtype.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
backend->GetFullName ( junk_tmp ).c_str (),
backend->GetFullName ( junk_elf ).c_str () );
{
string targetMacro ( GetTargetMacro ( module ) );
string workingDirectory = GetWorkingDirectory ( );
- string libsMacro = GetLibsMacro ();
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
GenerateImportLibraryTargetIfNeeded ();
{
GenerateRules ();
- string dependencies = libsMacro + " " + objectsMacro;
+ string dependencies = linkDepsMacro + " " + objectsMacro;
string linkerParameters = ssprintf ( "-subsystem=console -entry=%s -image-base=%s -file-alignment=0x1000 -section-alignment=0x1000",
module.GetEntryPoint(!(Environment::GetArch() == "arm")).c_str (),
void
MingwCabinetModuleHandler::Process ()
{
- fprintf ( fMakefile, "# CABINET MODULE TARGET\n" );
string targetMacro ( GetTargetMacro (module) );
GenerateRules ();
+ fprintf ( fMakefile, "# CABINET MODULE TARGET\n" );
const FileLocation *target_file = GetTargetFilename ( module, NULL );
fprintf ( fMakefile, "%s: $(CABMAN_TARGET) | %s\n",
targetMacro.c_str (),
string targetMacro ( GetTargetMacro (module) );
string workingDirectory = GetWorkingDirectory ();
string objectsMacro = GetObjectsMacro ( module );
+ string linkDepsMacro = GetLinkingDependenciesMacro ();
string libsMacro = GetLibsMacro ();
string debugFormat = GetDebugFormat ();
- fprintf ( fMakefile, "# ELF EXECUTABLE TARGET\n" );
GenerateRules ();
+ fprintf ( fMakefile, "# ELF EXECUTABLE TARGET\n" );
const FileLocation *target_file = GetTargetFilename ( module, NULL );
fprintf ( fMakefile, "%s: %s %s | %s\n",
targetMacro.c_str (),
objectsMacro.c_str (),
- libsMacro.c_str (),
+ linkDepsMacro.c_str (),
backend->GetFullPath ( *target_file ).c_str () );
fprintf ( fMakefile, "\t$(ECHO_BOOTPROG)\n" );
targetMacro.c_str () );
delete target_file;
- fprintf ( fMakefile, "#/ELF EXECUTABLE TARGET\n" );
}
string_list* pclean_files );
static std::string GenerateGccDefineParametersFromVector ( const std::vector<Define*>& defines, std::set<std::string> &used_defs );
- static std::string GenerateDefineParametersFromVector ( const std::vector<Define*>& defines, CompilerType compiler );
- static std::string GenerateCompilerParametersFromVector ( const std::vector<CompilerFlag*>& compilerFlags, const CompilerType type );
- static std::string GenerateIncludeParametersFromVector ( const std::vector<Include*>& includes, CompilerType compiler );
-
- static void GenerateParameters ( const char* prefix,
- const char* assignmentOperation,
- const IfableData& data );
+ static std::string GenerateGccIncludeParametersFromVector ( const std::vector<Include*>& includes );
std::string GetModuleTargets ( const Module& module );
void GetObjectsVector ( const IfableData& data,
std::string GetLinkingDependenciesMacro () const;
std::string GetLibsMacro () const;
std::string GetLinkerMacro () const;
- static std::string GetDebugFormat ();
+ std::string GetDebugFormat () const;
void GenerateCleanObjectsAsYouGoCode () const;
void GenerateRunRsymCode () const;
void GenerateRunStripCode () const;
private:
std::string ConcatenatePaths ( const std::string& path1,
const std::string& path2 ) const;
+ std::string GenerateCompilerParametersFromVector ( const std::vector<CompilerFlag*>& compilerFlags, const CompilerType type ) const;
std::string GenerateLinkerParametersFromVector ( const std::vector<LinkerFlag*>& linkerFlags ) const;
std::string GenerateImportLibraryDependenciesFromVector ( const std::vector<Library*>& libraries );
std::string GenerateLinkerParameters () const;
+ void GenerateMacro ( const char* assignmentOperation,
+ const std::string& macro,
+ const IfableData& data,
+ std::set<const Define *>* used_defs,
+ bool generatingCompilerMacro );
void GenerateMacros ( const char* op,
const IfableData& data,
const std::vector<LinkerFlag*>* linkerFlags,
void GenerateSourceMacros ( const IfableData& data );
void GenerateObjectMacros ( const IfableData& data );
const FileLocation* GetPrecompiledHeaderFilename () const;
- const FileLocation* GetPrecompiledHeaderPath () const;
const FileLocation* GetDlldataFilename () const;
void GenerateGccCommand ( const FileLocation* sourceFile,
const Rule *rule,
RBUILD_strip_prefix=${subst >>>,,${subst >>>$($(2)),,>>>$(1)}}
RBUILD_strip_prefixes=${subst >>>,,${subst >>>$(SEP),,>>>${call RBUILD_strip_prefix,${call RBUILD_strip_prefix,${call RBUILD_strip_prefix,${call RBUILD_strip_prefix,${call RBUILD_strip_prefix,$(1),INTERMEDIATE},OUTPUT},CDOUTPUT},TEMPORARY},INSTALL}}}
-#(source)
-RBUILD_intermediate_path_noext=${call RBUILD_intermediate_dir,$(1)}$(SEP)$(basename $(notdir $(1)))
-
#(module, source)
-RBUILD_intermediate_path_unique=${call RBUILD_intermediate_path_noext,$(2)}_$(1)
+RBUILD_intermediate_path_unique=${call RBUILD_intermediate_dir,$(2)}$(SEP)$(basename $(notdir $(2)))_$(1)
#(source)
RBUILD_intermediate_dir=${call RBUILD_fullpath,$(value INTERMEDIATE)$(SEP)$(dir ${call RBUILD_strip_prefixes,$(1)})}
-#(source)
-RBUILD_source_name=$(basename $(notdir $(1)))
-
-#(source)
-RBUILD_dir=${call RBUILD_fullpath,$(dir ${call RBUILD_compress_prefixes,$(1)})}
-
-# FIXME: when RosBE stops hijacking HOST_CFLAGS etc., add CFLAGS etc.
-
-#(module, flags, includes, compiler, prefix)
-RBUILD_compiler_flags=\
-$$(BUILTIN_$(5)$(4)FLAGS) \
-$$(PROJECT_$(5)$(4)FLAGS) \
-$$(MODULETYPE$($(1)_TYPE)_$(4)FLAGS) \
-$$($(1)_$(4)FLAGS) \
-$(2)
-
-#(module, flags, includes, compiler, prefix)
-RBUILD_compiler_flags_with_cpp=\
-$(3) \
-$$($(1)_$(4)INCLUDES) $$($(1)_CPPINCLUDES) \
-$$(MODULETYPE$($(1)_TYPE)_$(4)INCLUDES) $$(MODULETYPE$($(1)_TYPE)_CPPINCLUDES) \
-$$(PROJECT_$(5)$(4)INCLUDES) $$(PROJECT_$(5)CPPINCLUDES) \
-$$(BUILTIN_$(5)$(4)INCLUDES) $$(BUILTIN_$(5)CPPINCLUDES) \
-$$(BUILTIN_$(5)CPPDEFINES) $$(BUILTIN_$(5)CPPFLAGS) $$(BUILTIN_$(5)$(4)DEFINES) $$(BUILTIN_$(5)$(4)FLAGS) \
-$$(PROJECT_$(5)CPPDEFINES) $$(PROJECT_$(5)CPPFLAGS) $$(PROJECT_$(5)$(4)DEFINES) $$(PROJECT_$(5)$(4)FLAGS) \
-$$(MODULETYPE$($(1)_TYPE)_CPPDEFINES) $$(MODULETYPE$($(1)_TYPE)_CPPFLAGS) $$(MODULETYPE$($(1)_TYPE)_$(4)DEFINES) $$(MODULETYPE$($(1)_TYPE)_$(4)FLAGS) \
-$$($(1)_CPPDEFINES) $$($(1)_CPPFLAGS) $$($(1)_$(4)DEFINES) $$($(1)_$(4)FLAGS) \
-$(2)
-
-#(module, flags, includes, compiler, prefix)
-RBUILD_compiler_flags_builtin_cpp=\
-$(3) \
-$$($(1)_$(4)INCLUDES) $$($(1)_CPPINCLUDES) \
-$$(MODULETYPE$($(1)_TYPE)_$(4)INCLUDES) $$(MODULETYPE$($(1)_TYPE)_CPPINCLUDES) \
-$$(PROJECT_$(5)$(4)INCLUDES) $$(PROJECT_$(5)CPPINCLUDES) \
-$$(BUILTIN_$(5)$(4)INCLUDES) $$(BUILTIN_$(5)CPPINCLUDES) \
-$$(BUILTIN_$(5)CPPDEFINES) $$(BUILTIN_$(5)$(4)DEFINES) $$(BUILTIN_$(5)$(4)FLAGS) \
-$$(PROJECT_$(5)CPPDEFINES) $$(PROJECT_$(5)$(4)DEFINES) $$(PROJECT_$(5)$(4)FLAGS) \
-$$(MODULETYPE$($(1)_TYPE)_CPPDEFINES) $$(MODULETYPE$($(1)_TYPE)_$(4)DEFINES) $$(MODULETYPE$($(1)_TYPE)_$(4)FLAGS) \
-$$($(1)_CPPDEFINES) $$($(1)_$(4)DEFINES) $$($(1)_$(4)FLAGS) \
-$(2)
-
-#(module, flags, includes, compiler, prefix)
-RBUILD_compiler_flags_with_includes=\
-$(3) \
-$$($(1)_$(4)INCLUDES) $$($(1)_CPPINCLUDES) \
-$$(MODULETYPE$($(1)_TYPE)_$(4)INCLUDES) \
-$$(PROJECT_$(5)$(4)INCLUDES) \
-$$(BUILTIN_$(5)$(4)INCLUDES) \
-$$(BUILTIN_$(5)$(4)FLAGS) \
-$$(PROJECT_$(5)$(4)FLAGS) \
-$$(MODULETYPE$($(1)_TYPE)_$(4)FLAGS) \
-$$($(1)_$(4)FLAGS) \
-$(2)
-
-#(module, flags, includes, compiler, prefix)
-RBUILD_compiler_flags_cpp=\
-$(3) \
-$$($(1)_$(4)INCLUDES) $$($(1)_CPPINCLUDES) \
-$$(MODULETYPE$($(1)_TYPE)_$(4)INCLUDES) $$(MODULETYPE$($(1)_TYPE)_CPPINCLUDES) \
-$$(PROJECT_$(5)$(4)INCLUDES) $$(PROJECT_$(5)CPPINCLUDES) \
-$$(BUILTIN_$(5)$(4)INCLUDES) $$(BUILTIN_$(5)CPPINCLUDES) \
-$$(BUILTIN_$(5)CPPFLAGS) $$(BUILTIN_$(5)CPPDEFINES) $$(BUILTIN_$(5)$(4)DEFINES) \
-$$(PROJECT_$(5)CPPFLAGS) $$(PROJECT_$(5)CPPDEFINES) $$(PROJECT_$(5)$(4)DEFINES) \
-$$(MODULETYPE$($(1)_TYPE)_CPPFLAGS) $$(MODULETYPE$($(1)_TYPE)_CPPDEFINES) $$(MODULETYPE$($(1)_TYPE)_$(4)DEFINES) \
-$$($(1)_CPPFLAGS) $$($(1)_CPPDEFINES) $$($(1)_$(4)DEFINES) \
-$(2)
-
-#(module, flags, includes)
-RBUILD_cflags=${call RBUILD_compiler_flags_with_cpp,$(1),$(2),$(3),C}
-RBUILD_cxxflags=${call RBUILD_compiler_flags_with_cpp,$(1),$(2),$(3),CXX}
-RBUILD_asflags=${call RBUILD_compiler_flags_with_cpp,$(1),$(2),$(3),AS}
-RBUILD_nasmflags=${call RBUILD_compiler_flags_builtin_cpp,$(1),$(2),$(3),NASM}
-RBUILD_rc_pp_flags=${call RBUILD_compiler_flags_cpp,$(1),-DRC_INVOKED=1 -D__WIN32__=1 -D__FLAT__=1,$(3) -I.,RC}
-RBUILD_rc_flags=${call RBUILD_compiler_flags_with_includes,$(1),$(2),$(3),RC}
-RBUILD_spec_pp_flags=${call RBUILD_compiler_flags_cpp,$(1),,$(3),SPEC}
-RBUILD_spec_flags=${call RBUILD_compiler_flags,$(1),$(2),,SPEC}
-RBUILD_midlflags=${call RBUILD_compiler_flags_builtin_cpp,$(1),$(2),$(3),MIDL}
-RBUILD_host_cflags=${call RBUILD_compiler_flags_with_cpp,$(1),$(2),$(3),C,HOST_}
-RBUILD_host_cxxflags=${call RBUILD_compiler_flags_with_cpp,$(1),$(2),$(3),CXX,HOST_}
-
-CFLAG_WERROR:=-Werror
-CFLAG_CRTDLL:=-D_DLL -D__USE_CRTIMP
-
-CXXFLAG_WERROR:=-Werror
-CXXFLAG_CRTDLL:=-D_DLL -D__USE_CRTIMP
-
-CPPFLAG_WERROR:=-Werror
-CPPFLAG_UNICODE:=-DUNICODE -D_UNICODE
-
-RCFLAG_UNICODE:=-DUNICODE -D_UNICODE
-
-BUILTIN_ASDEFINES+= -D__ASM__
-BUILTIN_CPPFLAGS+= -nostdinc
-BUILTIN_CFLAGS+= -fno-optimize-sibling-calls
-BUILTIN_CXXFLAGS+= -fno-optimize-sibling-calls
-BUILTIN_RCFLAGS+= --nostdinc
-BUILTIN_RCDEFINES+= -DRC_INVOKED
-BUILTIN_NASMFLAGS+= -f win32
-
-#(module, source, dependencies, cflags, output)
-define RBUILD_GCC
-
-$(2): $${$(1)_precondition}
-
-ifeq ($(ROS_BUILDDEPS),full)
-
-$(5).d: $(2) | ${call RBUILD_dir,$(5)}
- $$(ECHO_DEPENDS)
- $${gcc} -MF $$@ ${call RBUILD_cflags,$(1),$(4)} -M -MP -MT $$@ $$<
-
--include $(5).d
-
-$(5): $(2) $(5).d $(3) | ${call RBUILD_dir,$(5)}
- $$(ECHO_CC)
- $${gcc} -o $$@ ${call RBUILD_cflags,$(1),$(4)} -c $$<
-
-else
-
-$(5): $(2) $(3) | ${call RBUILD_dir,$(5)}
- $$(ECHO_CC)
- $${gcc} -o $$@ ${call RBUILD_cflags,$(1),$(4)} -c $$<
-
-endif
-
-endef
-
-#(module, source, dependencies, cflags, output)
-define RBUILD_GAS
-
-$(2): $${$(1)_precondition}
-
-ifeq ($(ROS_BUILDDEPS),full)
-
-$(5).d: $(2) | ${call RBUILD_dir,$(5)}
- $$(ECHO_DEPENDS)
- $${gas} -MF $$@ ${call RBUILD_asflags,$(1),$(4)} -M -MP -MT $$@ $$<
-
--include $(5).d
-
-$(5): $(2) $(5).d $(3) | ${call RBUILD_dir,$(5)}
- $$(ECHO_AS)
- $${gas} -o $$@ ${call RBUILD_asflags,$(1),$(4)} -c $$<
-
-else
-
-$(5): $(2) $(3) | ${call RBUILD_dir,$(5)}
- $$(ECHO_AS)
- $${gas} -o $$@ ${call RBUILD_asflags,$(1),$(4)} -c $$<
-
-endif
-
-endef
-
-#(module, source, dependencies, cflags, output)
-define RBUILD_GPP
+#(module, source, dependencies, cflags)
+define RBUILD_GCC_RULE
$(2): $${$(1)_precondition}
ifeq ($(ROS_BUILDDEPS),full)
-$(5).d: $(2) | ${call RBUILD_dir,$(5)}
+${call RBUILD_intermediate_path_unique,$(1),$(2)}.o.d: $(2) | ${call RBUILD_intermediate_dir,$(2)}
$$(ECHO_DEPENDS)
- $${gpp} -MF $$@ ${call RBUILD_cxxflags,$(1),$(4)} -M -MP -MT $$@ $$<
+ $${gcc} -MF $$@ $$($(1)_CFLAGS) $(4) -M -MP -MT $$@ $$<
--include $(5).d
+-include ${call RBUILD_intermediate_path_unique,$(1),$(2)}.o.d
-$(5): $(2) $(5).d $(3) | ${call RBUILD_dir,$(5)}
+${call RBUILD_intermediate_path_unique,$(1),$(2)}.o: $(2) ${call RBUILD_intermediate_path_unique,$(1),$(2)}.o.d $(3) | ${call RBUILD_intermediate_dir,$(2)}
$$(ECHO_CC)
- $${gpp} -o $$@ ${call RBUILD_cxxflags,$(1),$(4)} -c $$<
+ $${gcc} -o $$@ $$($(1)_CFLAGS) $(4) -c $$<
else
-$(5): $(2) $(3) | ${call RBUILD_dir,$(5)}
+${call RBUILD_intermediate_path_unique,$(1),$(2)}.o: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}
$$(ECHO_CC)
- $${gpp} -o $$@ ${call RBUILD_cxxflags,$(1),$(4)} -c $$<
+ $${gcc} -o $$@ $$($(1)_CFLAGS) $(4) -c $$<
endif
endef
-#(module, source, dependencies, cflags)
-RBUILD_GCC_RULE=${call RBUILD_GCC,$(1),$(2),$(3),$(4),${call RBUILD_intermediate_path_unique,$(1),$(2)}.o}
-RBUILD_GPP_RULE=${call RBUILD_GPP,$(1),$(2),$(3),$(4),${call RBUILD_intermediate_path_unique,$(1),$(2)}.o}
-RBUILD_GAS_RULE=${call RBUILD_GAS,$(1),$(2),$(3),$(4),${call RBUILD_intermediate_path_unique,$(1),$(2)}.o}
-
#(module, source, dependencies, cflags)
define RBUILD_GPP_RULE
${call RBUILD_intermediate_path_unique,$(1),$(2)}.o.d: $(2) | ${call RBUILD_intermediate_dir,$(2)}
$$(ECHO_DEPENDS)
- $${gpp} -MF $$@ ${call RBUILD_cxxflags,$(1),$(4)} -M -MP -MT $$@ $$<
+ $${gpp} -MF $$@ $$($(1)_CXXFLAGS) $(4) -M -MP -MT $$@ $$<
-include ${call RBUILD_intermediate_path_unique,$(1),$(2)}.o.d
${call RBUILD_intermediate_path_unique,$(1),$(2)}.o: $(2) ${call RBUILD_intermediate_path_unique,$(1),$(2)}.o.d $(3) | ${call RBUILD_intermediate_dir,$(2)}
$$(ECHO_CC)
- $${gpp} -o $$@ ${call RBUILD_cxxflags,$(1),$(4)} -c $$<
+ $${gpp} -o $$@ $$($(1)_CXXFLAGS) $(4) -c $$<
else
${call RBUILD_intermediate_path_unique,$(1),$(2)}.o: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}
$$(ECHO_CC)
- $${gpp} -o $$@ ${call RBUILD_cxxflags,$(1),$(4)} -c $$<
-
-endif
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_GCC_PCH_RULE
-
-$(2): $${$(1)_precondition}
-
-ifeq ($$(ROS_BUILDDEPS),full)
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch.d: $(2) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_DEPENDS)
- $${gcc} -MF $$@ ${call RBUILD_cflags,$(1),$(4)} -x c-header -M -MP -MT $$@ $$<
-
--include $$(intermediate_dir)$$(SEP).gch_$$(module_name)$$(SEP)$(notdir $(2)).gch.d
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch: $(2) ${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch.d $(3) | ${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)
- $$(ECHO_PCH)
- $${gcc} -MF $$@ ${call RBUILD_cflags,$(1),$(4)} -x c-header -M -MP -MT $$@ $$<
-
-else
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)
- $$(ECHO_PCH)
- $${gcc} -MF $$@ ${call RBUILD_cflags,$(1),$(4)} -x c-header -M -MP -MT $$@ $$<
-
-endif
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_GPP_PCH_RULE
-
-$(2): $${$(1)_precondition}
-
-ifeq ($$(ROS_BUILDDEPS),full)
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch.d: $(2) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_DEPENDS)
- $${gpp} -MF $$@ ${call RBUILD_cxxflags,$(1),$(4)} -x c++-header -M -MP -MT $$@ $$<
-
--include $$(intermediate_dir)$$(SEP).gch_$$(module_name)$$(SEP)$(notdir $(2)).gch.d
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch: $(2) ${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch.d $(3) | ${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)
- $$(ECHO_PCH)
- $${gpp} -MF $$@ ${call RBUILD_cxxflags,$(1),$(4)} -x c++-header -M -MP -MT $$@ $$<
-
-else
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)$$(SEP)$(notdir $(2)).gch: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}$$(SEP).gch_$(1)
- $$(ECHO_PCH)
- $${gpp} -MF $$@ ${call RBUILD_cxxflags,$(1),$(4)} -x c++-header -M -MP -MT $$@ $$<
-
-endif
-
-endef
-
-#(module, source, dependencies, cflags, output)
-define RBUILD_NASM
-
-$(2): $${$(1)_precondition}
-
-$(5): $(2) $(3) | ${call RBUILD_dir,$(5)}
- $$(ECHO_NASM)
- $${nasm} -o $$@ ${call RBUILD_nasmflags,$(1),$(4)} $$<
-
-endef
-
-# TODO: module_dllname -> ${call RBUILD_module_dllname,$(1)}
-
-#(module, source, dependencies, cflags, module_dllname, output)
-define RBUILD_WINEBUILD_DEF
-
-$(6): $(2) $$(WINEBUILD_TARGET) | ${call RBUILD_intermediate_dir,$(6)}
- $$(ECHO_WINEBLD)
- $$(Q)$$(WINEBUILD_TARGET) -o $$@ --def -E $$< --filename $(5) ${call RBUILD_spec_flags,$(1),$(4)}
-
-endef
-
-#(module, source, dependencies, cflags, module_dllname, output)
-define RBUILD_WINEBUILD_STUBS
-
-$(6): $(2) $$(WINEBUILD_TARGET) | ${call RBUILD_intermediate_dir,$(6)}
- $$(ECHO_WINEBLD)
- $$(Q)$$(WINEBUILD_TARGET) -o $$@ --pedll $$< --filename $(5) ${call RBUILD_spec_flags,$(1),$(4)}
-
-endef
-
-#(module, source, dependencies, cflags, module_dllname)
-define RBUILD_WINEBUILD_WITH_CPP_RULE
-
-ifeq ($$(ROS_BUILDDEPS),full)
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec.d: $(2) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_DEPENDS)
- $${gcc} -xc -MF $$@ ${call RBUILD_spec_pp_flags,$(1),$(4)} -M -MP -MT $$@ $$<
-
--include ${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec.d
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec: $(2) ${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec.d $(3) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_CPP)
- $${gcc} -xc -E ${call RBUILD_spec_pp_flags,$(1),$(4)} $$< > $$@
-
-else
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_CPP)
- $${gcc} -xc -E ${call RBUILD_spec_pp_flags,$(1),$(4)} $$< > $$@
+ $${gpp} -o $$@ $$($(1)_CXXFLAGS) $(4) -c $$<
endif
-${call RBUILD_WINEBUILD_DEF,$(1),${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec,,$(4),$(5),${call RBUILD_intermediate_path_unique,$(1),$(2)}.auto.def}
-${call RBUILD_WINEBUILD_STUBS,$(1),${call RBUILD_intermediate_path_unique,$(1),$(2)}.spec,,$(4),$(5),${call RBUILD_intermediate_path_unique,$(1),$(2)}.stubs.c}
-${call RBUILD_GCC,$(1),${call RBUILD_intermediate_path_unique,$(1),$(2)}.stubs.c,,,${call RBUILD_intermediate_path_unique,$(1),$(2)}.stubs.o}
-
-endef
-
-#(module, source, dependencies, cflags, module_dllname)
-define RBUILD_WINEBUILD_RULE
-
-${call RBUILD_WINEBUILD_DEF,$(1),$(2),$(3),$(4),$(5),${call RBUILD_intermediate_path_unique,$(1),$(2)}.auto.def}
-${call RBUILD_WINEBUILD_STUBS,$(1),$(2),$(3),$(4),$(5),${call RBUILD_intermediate_path_unique,$(1),$(2)}.stubs.c}
-${call RBUILD_GCC,$(1),${call RBUILD_intermediate_path_unique,$(1),$(2)}.stubs.c,,,${call RBUILD_intermediate_path_unique,$(1),$(2)}.stubs.o}
-
-endef
-
-# FIXME: wrc butchers localized strings and doesn't implement -M, so we have to use an external preprocessor
-#(module, source, dependencies, cflags)
-define RBUILD_WRC_RULE
-
-$(2): $${$(1)_precondition}
-
-ifeq ($$(ROS_BUILDDEPS),full)
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.res.d: $(2) | ${call RBUILD_intermediate_dir,$(2)} $$(TEMPORARY)
- $$(ECHO_DEPENDS)
- $${gcc} -xc -MF $$@ ${call RBUILD_rc_pp_flags,$(1),$(4)} -M -MP -MT $$@ $$<
-
--include ${call RBUILD_intermediate_path_unique,$(1),$(2)}.coff.d
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.res: $(2) ${call RBUILD_intermediate_path_unique,$(1),$(2)}.res.d $(3) $$(WRC_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_RC)
- $${gcc} -xc ${call RBUILD_rc_pp_flags,$(1),$(4)} -E $$< | $$(WRC_TARGET) -o $$@ ${call RBUILD_rc_flags,$(1),$(4),-I${call RBUILD_dir,$(2)}}
-
-else
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.res: $(2) $(3) $$(WRC_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_RC)
- $${gcc} -xc ${call RBUILD_rc_pp_flags,$(1),$(4)} -E $$< | $$(WRC_TARGET) -o $$@ ${call RBUILD_rc_flags,$(1),$(4),-I${call RBUILD_dir,$(2)}}
-
-endif
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.coff: ${call RBUILD_intermediate_path_unique,$(1),$(2)}.res | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_CVTRES)
- $${windres} -i $$< -o $$@ -J res -O coff
-
-endef
-
-define RBUILD_WIDL
-
-endef
-
-define RBUILD_WIDL_HEADER_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_noext,$(2)}.h: $(2) $(3) $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4),-I${call RBUILD_dir,$(2)}} -h -H $$@ $$<
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_WIDL_CLIENT_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_noext,$(2)}_c.c ${call RBUILD_intermediate_path_noext,$(2)}_c.h: $(2) $(3) $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4),-I${call RBUILD_dir,$(2)}} -h -H ${call RBUILD_intermediate_path_noext,$(2)}_c.h -c -C ${call RBUILD_intermediate_path_noext,$(2)}_c.c $(2)
-
-${call RBUILD_GCC,$(1),${call RBUILD_intermediate_path_noext,$(2)}_c.c,,-fno-unit-at-a-time,${call RBUILD_intermediate_path_noext,$(2)}_c.o}
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_WIDL_SERVER_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_noext,$(2)}_s.c ${call RBUILD_intermediate_path_noext,$(2)}_s.h: $(2) $(3) $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4),-I${call RBUILD_dir,$(2)}} -h -H ${call RBUILD_intermediate_path_noext,$(2)}_s.h -s -S ${call RBUILD_intermediate_path_noext,$(2)}_s.c $(2)
-
-${call RBUILD_GCC,$(1),${call RBUILD_intermediate_path_noext,$(2)}_s.c,,-fno-unit-at-a-time,${call RBUILD_intermediate_path_noext,$(2)}_s.o}
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_WIDL_PROXY_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_noext,$(2)}_p.c ${call RBUILD_intermediate_path_noext,$(2)}_p.h: $(2) $(3) $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4),-I${call RBUILD_dir,$(2)}} -h -H ${call RBUILD_intermediate_path_noext,$(2)}_p.h -p -P ${call RBUILD_intermediate_path_noext,$(2)}_p.c $(2)
-
-${call RBUILD_GCC,$(1),${call RBUILD_intermediate_path_noext,$(2)}_p.c,,-fno-unit-at-a-time,${call RBUILD_intermediate_path_noext,$(2)}_p.o}
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_WIDL_INTERFACE_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_noext,$(2)}_i.c: $(2) $(3) $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4),-I${call RBUILD_dir,$(2)}} -u -U $$@ $$<
-
-${call RBUILD_GCC,$(1),${call RBUILD_intermediate_path_noext,$(2)}_i.c,,-fno-unit-at-a-time,${call RBUILD_intermediate_path_noext,$(2)}_i.o}
-
-endef
-
-# FIXME: this rule sucks
-#(module, source, dependencies, cflags, bare_dependencies)
-define RBUILD_WIDL_DLLDATA_RULE
-
-$(2): $(3) ${$(1)_precondition} $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4)} --dlldata-only --dlldata=$(2) $(5)
-
-${call RBUILD_GCC,$(1),$(2),,,${call RBUILD_intermediate_path_noext,$(2)}.o}
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_WIDL_TLB_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_dir,$(2)}$$(SEP)$(1).tlb: $(2) $(3) $$(WIDL_TARGET) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_WIDL)
- $$(Q)$$(WIDL_TARGET) ${call RBUILD_midlflags,$(1),$(4),-I${call RBUILD_dir,$(2)}} -t -T $$@ $$<
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_HOST_GCC_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.o: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_HOSTCC)
- $${host_gcc} -o $$@ ${call RBUILD_host_cflags,$(1),$(4)} -c $$<
-
-endef
-
-#(module, source, dependencies, cflags)
-define RBUILD_HOST_GPP_RULE
-
-$(2): $${$(1)_precondition}
-
-${call RBUILD_intermediate_path_unique,$(1),$(2)}.o: $(2) $(3) | ${call RBUILD_intermediate_dir,$(2)}
- $$(ECHO_HOSTCC)
- $${host_gpp} -o $$@ ${call RBUILD_host_cxxflags,$(1),$(4)} -c $$<
-
endef
# EOF
+++ /dev/null
-/*
- * Copyright (C) 2009 KJK::Hyperion
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-#include "pch.h"
-#include <assert.h>
-
-#include "rbuild.h"
-
-#include <locale>
-
-void
-CompilerDirective::SetCompiler ( CompilerType compiler )
-{
- assert ( compiler < CompilerTypesCount );
- compilersSet.set ( compiler );
-}
-
-void
-CompilerDirective::UnsetCompiler ( CompilerType compiler )
-{
- assert ( compiler < CompilerTypesCount );
- compilersSet.reset ( compiler );
-}
-
-void
-CompilerDirective::SetAllCompilers ()
-{
- compilersSet.set ();
-}
-
-void
-CompilerDirective::UnsetAllCompilers ()
-{
- compilersSet.reset ();
-}
-
-bool
-CompilerDirective::IsCompilerSet ( CompilerType compiler ) const
-{
- assert ( compiler < CompilerTypesCount );
- return compilersSet.test ( compiler );
-}
-
-template < std::size_t N >
-static
-bool
-CompareStringElement ( const std::string::const_iterator& begin, const std::string::const_iterator& end, const char (& compareTo)[(N)] )
-{
- return !std::use_facet < std::collate < char > > ( std::locale::classic () )
- .compare ( &(*begin),
- &(*(end - 1)),
- &compareTo[0],
- &compareTo[(N) - 2] );
-}
-
-void
-CompilerDirective::ParseCompilers ( const XMLElement& node, const std::string& defaultValue )
-{
- const XMLAttribute* att = node.GetAttribute ( "compiler", false );
- const std::string& value = att ? att->value : defaultValue;
-
- if ( value == "*" )
- SetAllCompilers ();
- else
- {
- UnsetAllCompilers ();
-
- std::string::const_iterator beginString;
-
- beginString = value.begin();
-
- do
- {
- for ( ; beginString != value.end(); ++ beginString )
- {
- if ( *beginString != ',' )
- break;
- }
-
- if ( beginString == value.end() )
- break;
-
- std::string::const_iterator endString = beginString;
-
- for ( ; endString != value.end(); ++ endString )
- {
- if ( *endString == ',' )
- break;
- }
-
- assert ( endString != beginString );
-
- CompilerType compiler;
-
- if ( CompareStringElement ( beginString, endString, "cc" ) )
- compiler = CompilerTypeCC;
- else if ( CompareStringElement ( beginString, endString, "cxx" ) )
- compiler = CompilerTypeCXX;
- else if ( CompareStringElement ( beginString, endString, "cpp" ) )
- compiler = CompilerTypeCPP;
- else if ( CompareStringElement ( beginString, endString, "as" ) )
- compiler = CompilerTypeAS;
- else if ( CompareStringElement ( beginString, endString, "midl" ) )
- compiler = CompilerTypeMIDL;
- else if ( CompareStringElement ( beginString, endString, "rc" ) )
- compiler = CompilerTypeRC;
- else if ( CompareStringElement ( beginString, endString, "nasm" ) )
- compiler = CompilerTypeNASM;
- else
- {
- throw InvalidAttributeValueException (
- node.location,
- "compiler",
- value );
- }
-
- SetCompiler ( compiler );
-
- beginString = endString;
- }
- while ( beginString != value.end() );
-
- if ( !compilersSet.any() )
- {
- throw InvalidAttributeValueException (
- node.location,
- "compiler",
- value );
- }
- }
-}
}
flag = node.value;
+ compiler = CompilerTypeDontCare;
- ParseCompilers ( node, "cc,cxx" );
+ const XMLAttribute* att = node.GetAttribute ( "compiler", false );
+ if ( att != NULL)
+ {
+ if ( att->value == "cpp" )
+ compiler = CompilerTypeCPP;
+ else if ( att->value == "cc" )
+ compiler = CompilerTypeCC;
+ else
+ {
+ throw InvalidAttributeValueException (
+ node.location,
+ "compiler",
+ att->value );
+ }
+ }
}
void
Define::Define ( const Project& project,
const Module* module,
const std::string& name_,
- const std::string& backend_,
- bool redefine_)
+ const std::string& backend_)
: project(project),
module(module),
node(NULL)
name = name_;
value = "";
backend = backend_;
- redefine = redefine_;
}
Define::~Define ()
void
Define::Initialize()
{
- redefine = node->name == "redefine";
-
const XMLAttribute* att = node->GetAttribute ( "name", true );
att = node->GetAttribute ( "name", true );
assert(att);
-
- size_t name_len = att->value.find ( '(' );
-
- name = att->value.substr ( 0, name_len );
-
- if ( name_len != std::string::npos )
- arguments = att->value.substr ( att->value.find ( '(' ) );
-
+ name = att->value;
value = node->value;
att = node->GetAttribute ( "backend", false );
if ( att )
backend = att->value;
- ParseCompilers ( *node, "cpp" );
+ att = node->GetAttribute ( "overridable", false );
+ if ( att )
+ overridable = ( att->value == "true" || att->value == "yes" );
+ else
+ overridable = false;
}
void
node ( includeNode ),
module ( NULL )
{
- Initialize ();
}
Include::Include ( const Project& project,
node ( includeNode ),
module ( module )
{
- Initialize ();
}
Include::Include ( const Project& project,
else
return SourceDirectory;
}
-
-void
-Include::Initialize ()
-{
- ParseCompilers ( *node, "cpp" );
-}
non_if_data.includes.push_back ( include );
subs_invalid = true;
}
- else if ( e.name == "define" || e.name == "redefine" )
+ else if ( e.name == "define" )
{
Define* pDefine = new Define ( project, this, e );
non_if_data.defines.push_back ( pDefine );
#include <map>
#include <set>
#include <utility>
-#include <bitset>
#ifdef WIN32
#include <windows.h>
subs_invalid = true;
}
- else if ( e.name == "define" || e.name == "redefine" )
+ else if ( e.name == "define" )
{
const XMLAttribute* host = e.GetAttribute("host", false);
Define* define = new Define ( *this, e );
CFG=rbuild - Win32 Debug\r
!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
!MESSAGE use the Export Makefile command and run\r
-!MESSAGE\r
+!MESSAGE \r
!MESSAGE NMAKE /f "rbuild.mak".\r
-!MESSAGE\r
+!MESSAGE \r
!MESSAGE You can specify a configuration when running NMAKE\r
!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE\r
+!MESSAGE \r
!MESSAGE NMAKE /f "rbuild.mak" CFG="rbuild - Win32 Debug"\r
-!MESSAGE\r
+!MESSAGE \r
!MESSAGE Possible choices for configuration are:\r
-!MESSAGE\r
+!MESSAGE \r
!MESSAGE "rbuild - Win32 Release" (based on "Win32 (x86) Console Application")\r
!MESSAGE "rbuild - Win32 Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE\r
+!MESSAGE \r
\r
# Begin Project\r
# PROP AllowPerConfigDependencies 0\r
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
\r
-!ENDIF\r
+!ENDIF \r
\r
# Begin Target\r
\r
# End Source File\r
# Begin Source File\r
\r
-SOURCE=.\compilerdirective.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
SOURCE=.\compilerflag.cpp\r
# End Source File\r
# Begin Source File\r
enum CompilerType
{
+ CompilerTypeDontCare,
CompilerTypeCC,
- CompilerTypeCXX,
CompilerTypeCPP,
- CompilerTypeAS,
- CompilerTypeMIDL,
- CompilerTypeRC,
- CompilerTypeNASM,
-
- CompilerTypesCount
};
class FileLocation
bool default_value = false );
};
-class CompilerDirective
-{
-private:
- std::bitset<CompilerTypesCount> compilersSet;
-
-public:
- void SetCompiler ( CompilerType compiler );
- void UnsetCompiler ( CompilerType compiler );
- void SetAllCompilers ();
- void UnsetAllCompilers ();
- void ParseCompilers ( const XMLElement& node, const std::string& defaultValue );
-
- bool IsCompilerSet ( CompilerType compiler ) const;
-};
-
-class Include: public CompilerDirective
+class Include
{
public:
FileLocation *directory;
const XMLElement* node;
const Module* module;
DirectoryLocation GetDefaultDirectoryTree ( const Module* module ) const;
- void Initialize ();
};
-class Define: public CompilerDirective
+class Define
{
public:
const Project& project;
const Module* module;
const XMLElement* node;
std::string name;
- std::string arguments;
std::string value;
std::string backend;
- bool redefine;
+ bool overridable;
Define ( const Project& project,
const XMLElement& defineNode );
Define ( const Project& project,
const Module* module,
const std::string& name_,
- const std::string& backend_ = "",
- bool redefine_ = false );
+ const std::string& backend_ = "" );
~Define();
void ProcessXML();
private:
};
-class CompilerFlag: public CompilerDirective
+class CompilerFlag
{
public:
const Project& project;
const Module* module;
const XMLElement& node;
std::string flag;
+ CompilerType compiler;
CompilerFlag ( const Project& project,
const XMLElement& compilerFlagNode );
cdfile.cpp \
compilationunit.cpp \
compilationunitsupportcode.cpp \
- compilerdirective.cpp \
compilerflag.cpp \
configuration.cpp \
define.cpp \
$(ECHO_HOSTCC)
${host_gpp} $(RBUILD_HOST_CXXFLAGS) -c $< -o $@
-$(RBUILD_INT_)compilerdirective.o: $(RBUILD_BASE_)compilerdirective.cpp $(RBUILD_HEADERS) | $(RBUILD_INT)
- $(ECHO_HOSTCC)
- ${host_gpp} $(RBUILD_HOST_CXXFLAGS) -c $< -o $@
-
$(RBUILD_INT_)compilerflag.o: $(RBUILD_BASE_)compilerflag.cpp $(RBUILD_HEADERS) | $(RBUILD_INT)
$(ECHO_HOSTCC)
${host_gpp} $(RBUILD_HOST_CXXFLAGS) -c $< -o $@
/>\r
</FileConfiguration>\r
</File>\r
- <File\r
- RelativePath="compilerdirective.cpp"\r
- >\r
- <FileConfiguration\r
- Name="Release|Win32"\r
- >\r
- <Tool\r
- Name="VCCLCompilerTool"\r
- Optimization="2"\r
- PreprocessorDefinitions=""\r
- />\r
- </FileConfiguration>\r
- <FileConfiguration\r
- Name="Debug|Win32"\r
- >\r
- <Tool\r
- Name="VCCLCompilerTool"\r
- Optimization="0"\r
- AdditionalIncludeDirectories=""\r
- PreprocessorDefinitions=""\r
- BasicRuntimeChecks="3"\r
- />\r
- </FileConfiguration>\r
- </File>\r
<File\r
RelativePath="compilerflag.cpp"\r
>\r