summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Gladman <brg@gladman.plus.com>2010-07-27 18:20:22 +0000
committerBrian Gladman <brg@gladman.plus.com>2010-07-27 18:20:22 +0000
commit71afeff2ebb636e5300fc29df8497e38bb3f88fe (patch)
tree15840633982e6dbd7420967475354810861d84b2
parentea41f1e4e52de81112770694a408ca3af6dd0932 (diff)
downloadyasm-71afeff2ebb636e5300fc29df8497e38bb3f88fe.tar.gz
Remove some causes of unnecessary rebuilds on Windows (VC10 only)
svn path=/trunk/yasm/; revision=2342
-rw-r--r--Mkfiles/vc10/genperf/genperf.vcxproj4
-rw-r--r--Mkfiles/vc10/genperf/run.bat14
-rw-r--r--Mkfiles/vc10/libyasm/libyasm.vcxproj4
-rw-r--r--Mkfiles/vc10/libyasm/libyasm.vcxproj.filters12
-rw-r--r--Mkfiles/vc10/out_copy_rename.bat42
-rw-r--r--Mkfiles/vc10/vsyasm.vcxproj6
6 files changed, 59 insertions, 23 deletions
diff --git a/Mkfiles/vc10/genperf/genperf.vcxproj b/Mkfiles/vc10/genperf/genperf.vcxproj
index 3ca1fb45..b94d5a2b 100644
--- a/Mkfiles/vc10/genperf/genperf.vcxproj
+++ b/Mkfiles/vc10/genperf/genperf.vcxproj
@@ -44,6 +44,10 @@
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Platform)\$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
+ <PreBuildEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</PreBuildEventUseInBuild>
+ <PreBuildEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</PreBuildEventUseInBuild>
+ <PreLinkEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</PreLinkEventUseInBuild>
+ <PreLinkEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</PreLinkEventUseInBuild>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
diff --git a/Mkfiles/vc10/genperf/run.bat b/Mkfiles/vc10/genperf/run.bat
index 9c22b57e..5827138b 100644
--- a/Mkfiles/vc10/genperf/run.bat
+++ b/Mkfiles/vc10/genperf/run.bat
@@ -16,7 +16,13 @@ call %_python_% modules\arch\x86\gen_x86_insn.py
:therest
@echo on
-%1 x86insn_nasm.gperf x86insn_nasm.c
-%1 x86insn_gas.gperf x86insn_gas.c
-%1 modules\arch\x86\x86cpu.gperf x86cpu.c
-%1 modules\arch\x86\x86regtmod.gperf x86regtmod.c
+call :update %1 x86insn_nasm.gperf x86insn_nasm.c
+call :update %1 x86insn_gas.gperf x86insn_gas.c
+call :update %1 modules\arch\x86\x86cpu.gperf x86cpu.c
+call :update %1 modules\arch\x86\x86regtmod.gperf x86regtmod.c
+goto :eof
+
+:update
+%1 %2 tf
+call mkfiles\vc10\out_copy_rename tf .\ %3
+del tf
diff --git a/Mkfiles/vc10/libyasm/libyasm.vcxproj b/Mkfiles/vc10/libyasm/libyasm.vcxproj
index a480d2a6..af67e44d 100644
--- a/Mkfiles/vc10/libyasm/libyasm.vcxproj
+++ b/Mkfiles/vc10/libyasm/libyasm.vcxproj
@@ -229,15 +229,12 @@
<ClInclude Include="..\..\..\libyasm\file.h" />
<ClInclude Include="..\..\..\libyasm\arch.h" />
<ClInclude Include="..\..\..\libyasm\assocdat.h" />
- <ClInclude Include="..\..\..\libyasm\bc-int.h" />
<ClInclude Include="..\..\..\libyasm\bitvect.h" />
<ClInclude Include="..\..\..\libyasm\bytecode.h" />
<ClInclude Include="..\..\..\libyasm\compat-queue.h" />
- <ClInclude Include="config.h" />
<ClInclude Include="..\..\..\libyasm\coretype.h" />
<ClInclude Include="..\..\..\libyasm\dbgfmt.h" />
<ClInclude Include="..\..\..\libyasm\errwarn.h" />
- <ClInclude Include="..\..\..\libyasm\expr-int.h" />
<ClInclude Include="..\..\..\libyasm\expr.h" />
<ClInclude Include="..\..\..\libyasm\floatnum.h" />
<ClInclude Include="..\..\..\libyasm\hamt.h" />
@@ -252,7 +249,6 @@
<ClInclude Include="..\..\..\libyasm\preproc.h" />
<ClInclude Include="..\..\..\libyasm\section.h" />
<ClInclude Include="..\..\..\libyasm\symrec.h" />
- <ClInclude Include="..\..\..\libyasm\util.h" />
<ClInclude Include="..\..\..\libyasm\valparam.h" />
<ClInclude Include="..\..\..\libyasm\value.h" />
</ItemGroup>
diff --git a/Mkfiles/vc10/libyasm/libyasm.vcxproj.filters b/Mkfiles/vc10/libyasm/libyasm.vcxproj.filters
index aaad93d7..6385583d 100644
--- a/Mkfiles/vc10/libyasm/libyasm.vcxproj.filters
+++ b/Mkfiles/vc10/libyasm/libyasm.vcxproj.filters
@@ -106,9 +106,6 @@
<ClInclude Include="..\..\..\libyasm\assocdat.h">
<Filter>Header Files</Filter>
</ClInclude>
- <ClInclude Include="..\..\..\libyasm\bc-int.h">
- <Filter>Header Files</Filter>
- </ClInclude>
<ClInclude Include="..\..\..\libyasm\bitvect.h">
<Filter>Header Files</Filter>
</ClInclude>
@@ -127,9 +124,6 @@
<ClInclude Include="..\..\..\libyasm\errwarn.h">
<Filter>Header Files</Filter>
</ClInclude>
- <ClInclude Include="..\..\..\libyasm\expr-int.h">
- <Filter>Header Files</Filter>
- </ClInclude>
<ClInclude Include="..\..\..\libyasm\expr.h">
<Filter>Header Files</Filter>
</ClInclude>
@@ -175,18 +169,12 @@
<ClInclude Include="..\..\..\libyasm\symrec.h">
<Filter>Header Files</Filter>
</ClInclude>
- <ClInclude Include="..\..\..\libyasm\util.h">
- <Filter>Header Files</Filter>
- </ClInclude>
<ClInclude Include="..\..\..\libyasm\valparam.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\..\libyasm\value.h">
<Filter>Header Files</Filter>
</ClInclude>
- <ClInclude Include="config.h">
- <Filter>Header Files</Filter>
- </ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="..\..\..\libyasm\module.in" />
diff --git a/Mkfiles/vc10/out_copy_rename.bat b/Mkfiles/vc10/out_copy_rename.bat
new file mode 100644
index 00000000..349ee330
--- /dev/null
+++ b/Mkfiles/vc10/out_copy_rename.bat
@@ -0,0 +1,42 @@
+@echo off
+if not exist %1 goto nofile
+if exist %2 goto copy
+
+echo creating directory %2
+md %2 > nul
+
+:copy
+set str=%2
+for /f "useback tokens=*" %%a in ('%str%') do set str=%%~a
+set str=%str:~-1%
+if %str% == "\" goto hasbackslash
+
+if not exist %2\%3 goto cpy
+fc %1 %2\%3 > nul && if not %errorlevel 1 goto exit
+echo overwriting %2\%3 with %1
+copy %1 %2\%3 > nul
+goto exit
+
+:cpy
+echo copying %1 to %2\%3
+copy %1 %2\%3 > nul
+goto exit
+
+:hasbackslash
+if not exist %2%3 goto cpy2
+fc %1 %2%3 > nul && if not %errorlevel 1 goto exit
+echo overwriting %2%3 with %1
+copy %1 %2%3 > nul
+goto exit
+
+:cpy2
+echo copying %1 to %2%3
+copy %1 %2%3 > nul
+goto exit
+
+:nofile
+echo %1 not found
+
+:exit
+
+
diff --git a/Mkfiles/vc10/vsyasm.vcxproj b/Mkfiles/vc10/vsyasm.vcxproj
index 7decc5bc..0c6e22a2 100644
--- a/Mkfiles/vc10/vsyasm.vcxproj
+++ b/Mkfiles/vc10/vsyasm.vcxproj
@@ -252,9 +252,6 @@
<ClCompile Include="..\..\frontends\yasm\yasm-options.c" />
</ItemGroup>
<ItemGroup>
- <ClInclude Include="..\..\frontends\vsyasm\yasm-options.h" />
- </ItemGroup>
- <ItemGroup>
<ProjectReference Include="libyasm\libyasm.vcxproj">
<Project>{29fe7874-1256-4ad6-b889-68e399dc9608}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
@@ -264,6 +261,9 @@
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
+ <ItemGroup>
+ <ClInclude Include="..\..\frontends\yasm\yasm-options.h" />
+ </ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>