Unified · Split
| @@ -0,0 +1,9 @@ | ||
| 1 | +set /p VERSION= < %~dp0..\..\VERSION | |
| 2 | + | |
| 3 | +:config.h | |
| 4 | +echo> .\config.h #define TCC_VERSION "%VERSION%" | |
| 5 | +echo>> .\config.h #ifdef TCC_TARGET_X86_64 | |
| 6 | +echo>> .\config.h #define CONFIG_TCC_LIBPATHS "{B}/lib/64;{B}/lib" | |
| 7 | +echo>> .\config.h #else | |
| 8 | +echo>> .\config.h #define CONFIG_TCC_LIBPATHS "{B}/lib/32;{B}/lib" | |
| 9 | +echo>> .\config.h #endif | |
| @@ -71,15 +71,19 @@ · 70 unmodified lines | ||
| 71 | 71 | <PropertyGroup Label="UserMacros" /> |
| 72 | 72 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> |
| 73 | 73 | <LinkIncremental>true</LinkIncremental> |
| 74 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 74 | 75 | </PropertyGroup> |
| 75 | 76 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
| 76 | 77 | <LinkIncremental>true</LinkIncremental> |
| 78 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 77 | 79 | </PropertyGroup> |
| 78 | 80 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> |
| 79 | 81 | <LinkIncremental>false</LinkIncremental> |
| 82 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 80 | 83 | </PropertyGroup> |
| 81 | 84 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
| 82 | 85 | <LinkIncremental>false</LinkIncremental> |
| 86 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 83 | 87 | </PropertyGroup> |
| 84 | 88 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> |
| 85 | 89 | <ClCompile> |
| @@ -88,6 +92,7 @@ · 2 unmodified lines | ||
| 88 | 92 | <WarningLevel>Level3</WarningLevel> |
| 89 | 93 | <Optimization>Disabled</Optimization> |
| 90 | 94 | <PreprocessorDefinitions>ONE_SOURCE;LIBTCC_AS_DLL;TCC_TARGET_PE;TCC_TARGET_I386;WIN32;_DEBUG;_WINDOWS;_USRDLL;LIBTCC_EXPORTS;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions> |
| 95 | + <DebugInformationFormat>EditAndContinue</DebugInformationFormat> | |
| 91 | 96 | </ClCompile> |
| 92 | 97 | <Link> |
| 93 | 98 | <SubSystem>Windows</SubSystem> |
| @@ -96,6 +101,12 @@ · 2 unmodified lines | ||
| 96 | 101 | <PostBuildEvent> |
| 97 | 102 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 98 | 103 | </PostBuildEvent> |
| 104 | + <PreBuildEvent> | |
| 105 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 106 | + </PreBuildEvent> | |
| 107 | + <PreBuildEvent> | |
| 108 | + <Message>Generate config.h</Message> | |
| 109 | + </PreBuildEvent> | |
| 99 | 110 | </ItemDefinitionGroup> |
| 100 | 111 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
| 101 | 112 | <ClCompile> |
| @@ -104,6 +115,7 @@ · 2 unmodified lines | ||
| 104 | 115 | <WarningLevel>Level3</WarningLevel> |
| 105 | 116 | <Optimization>Disabled</Optimization> |
| 106 | 117 | <PreprocessorDefinitions>ONE_SOURCE;LIBTCC_AS_DLL;TCC_TARGET_PE;TCC_TARGET_X86_64;_DEBUG;_WINDOWS;_USRDLL;LIBTCC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions> |
| 118 | + <DebugInformationFormat>EditAndContinue</DebugInformationFormat> | |
| 107 | 119 | </ClCompile> |
| 108 | 120 | <Link> |
| 109 | 121 | <SubSystem>Windows</SubSystem> |
| @@ -112,6 +124,12 @@ · 2 unmodified lines | ||
| 112 | 124 | <PostBuildEvent> |
| 113 | 125 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 114 | 126 | </PostBuildEvent> |
| 127 | + <PreBuildEvent> | |
| 128 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 129 | + </PreBuildEvent> | |
| 130 | + <PreBuildEvent> | |
| 131 | + <Message>Generate config.h</Message> | |
| 132 | + </PreBuildEvent> | |
| 115 | 133 | </ItemDefinitionGroup> |
| 116 | 134 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> |
| 117 | 135 | <ClCompile> |
| @@ -132,6 +150,12 @@ · 14 unmodified lines | ||
| 132 | 150 | <PostBuildEvent> |
| 133 | 151 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 134 | 152 | </PostBuildEvent> |
| 153 | + <PreBuildEvent> | |
| 154 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 155 | + </PreBuildEvent> | |
| 156 | + <PreBuildEvent> | |
| 157 | + <Message>Generate config.h</Message> | |
| 158 | + </PreBuildEvent> | |
| 135 | 159 | </ItemDefinitionGroup> |
| 136 | 160 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
| 137 | 161 | <ClCompile> |
| @@ -152,6 +176,12 @@ · 14 unmodified lines | ||
| 152 | 176 | <PostBuildEvent> |
| 153 | 177 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 154 | 178 | </PostBuildEvent> |
| 179 | + <PreBuildEvent> | |
| 180 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 181 | + </PreBuildEvent> | |
| 182 | + <PreBuildEvent> | |
| 183 | + <Message>Generate config.h</Message> | |
| 184 | + </PreBuildEvent> | |
| 155 | 185 | </ItemDefinitionGroup> |
| 156 | 186 | <ItemGroup> |
| 157 | 187 | <ClCompile Include="..\..\libtcc.c" /> |
| @@ -71,15 +71,19 @@ · 70 unmodified lines | ||
| 71 | 71 | <PropertyGroup Label="UserMacros" /> |
| 72 | 72 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> |
| 73 | 73 | <LinkIncremental>true</LinkIncremental> |
| 74 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 74 | 75 | </PropertyGroup> |
| 75 | 76 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
| 76 | 77 | <LinkIncremental>true</LinkIncremental> |
| 78 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 77 | 79 | </PropertyGroup> |
| 78 | 80 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> |
| 79 | 81 | <LinkIncremental>false</LinkIncremental> |
| 82 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 80 | 83 | </PropertyGroup> |
| 81 | 84 | <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
| 82 | 85 | <LinkIncremental>false</LinkIncremental> |
| 86 | + <IncludePath>$(ProjectDir);$(VC_IncludePath);$(WindowsSDK_IncludePath);</IncludePath> | |
| 83 | 87 | </PropertyGroup> |
| 84 | 88 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> |
| 85 | 89 | <ClCompile> |
| @@ -88,6 +92,7 @@ · 2 unmodified lines | ||
| 88 | 92 | <WarningLevel>Level3</WarningLevel> |
| 89 | 93 | <Optimization>Disabled</Optimization> |
| 90 | 94 | <PreprocessorDefinitions>TCC_TARGET_PE;TCC_TARGET_I386;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> |
| 95 | + <DebugInformationFormat>EditAndContinue</DebugInformationFormat> | |
| 91 | 96 | </ClCompile> |
| 92 | 97 | <Link> |
| 93 | 98 | <SubSystem>Console</SubSystem> |
| @@ -98,6 +103,10 @@ · 4 unmodified lines | ||
| 98 | 103 | <PostBuildEvent> |
| 99 | 104 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 100 | 105 | </PostBuildEvent> |
| 106 | + <PreBuildEvent> | |
| 107 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 108 | + <Message>Generate config.h</Message> | |
| 109 | + </PreBuildEvent> | |
| 101 | 110 | </ItemDefinitionGroup> |
| 102 | 111 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
| 103 | 112 | <ClCompile> |
| @@ -106,6 +115,7 @@ · 2 unmodified lines | ||
| 106 | 115 | <WarningLevel>Level3</WarningLevel> |
| 107 | 116 | <Optimization>Disabled</Optimization> |
| 108 | 117 | <PreprocessorDefinitions>TCC_TARGET_PE;TCC_TARGET_X86_64;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> |
| 118 | + <DebugInformationFormat>EditAndContinue</DebugInformationFormat> | |
| 109 | 119 | </ClCompile> |
| 110 | 120 | <Link> |
| 111 | 121 | <SubSystem>Console</SubSystem> |
| @@ -116,6 +126,10 @@ · 4 unmodified lines | ||
| 116 | 126 | <PostBuildEvent> |
| 117 | 127 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 118 | 128 | </PostBuildEvent> |
| 129 | + <PreBuildEvent> | |
| 130 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 131 | + <Message>Generate config.h</Message> | |
| 132 | + </PreBuildEvent> | |
| 119 | 133 | </ItemDefinitionGroup> |
| 120 | 134 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> |
| 121 | 135 | <ClCompile> |
| @@ -138,6 +152,10 @@ · 16 unmodified lines | ||
| 138 | 152 | <PostBuildEvent> |
| 139 | 153 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 140 | 154 | </PostBuildEvent> |
| 155 | + <PreBuildEvent> | |
| 156 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 157 | + <Message>Generate config.h</Message> | |
| 158 | + </PreBuildEvent> | |
| 141 | 159 | </ItemDefinitionGroup> |
| 142 | 160 | <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
| 143 | 161 | <ClCompile> |
| @@ -160,6 +178,10 @@ · 16 unmodified lines | ||
| 160 | 178 | <PostBuildEvent> |
| 161 | 179 | <Command>copy $(TargetPath) $(SolutionDir)..</Command> |
| 162 | 180 | </PostBuildEvent> |
| 181 | + <PreBuildEvent> | |
| 182 | + <Command>$(ProjectDir)PreBuild.bat</Command> | |
| 183 | + <Message>Generate config.h</Message> | |
| 184 | + </PreBuildEvent> | |
| 163 | 185 | </ItemDefinitionGroup> |
| 164 | 186 | <ItemGroup> |
| 165 | 187 | <ClCompile Include="..\..\tcc.c" /> |