mirror of
https://github.com/moparisthebest/curl
synced 2024-12-22 16:18:48 -05:00
build: Added VC11 support to the project file generator
This commit is contained in:
parent
c64370dccd
commit
925c11b545
@ -22,40 +22,45 @@ rem *
|
|||||||
rem ***************************************************************************
|
rem ***************************************************************************
|
||||||
setlocal ENABLEDELAYEDEXPANSION
|
setlocal ENABLEDELAYEDEXPANSION
|
||||||
|
|
||||||
rem Generate VC8 project files
|
echo Generating VC8 project files
|
||||||
call :generate vc8 Windows\VC8\src\curlsrc.tmpl Windows\VC8\src\curlsrc.vcproj
|
call :generate vcproj Windows\VC8\src\curlsrc.tmpl Windows\VC8\src\curlsrc.vcproj
|
||||||
call :generate vc8 Windows\VC8\lib\libcurl.tmpl Windows\VC8\lib\libcurl.vcproj
|
call :generate vcproj Windows\VC8\lib\libcurl.tmpl Windows\VC8\lib\libcurl.vcproj
|
||||||
|
|
||||||
rem Generate VC9 project files
|
echo.
|
||||||
call :generate vc9 Windows\VC9\src\curlsrc.tmpl Windows\VC9\src\curlsrc.vcproj
|
echo Generating VC9 project files
|
||||||
call :generate vc9 Windows\VC9\lib\libcurl.tmpl Windows\VC9\lib\libcurl.vcproj
|
call :generate vcproj Windows\VC9\src\curlsrc.tmpl Windows\VC9\src\curlsrc.vcproj
|
||||||
|
call :generate vcproj Windows\VC9\lib\libcurl.tmpl Windows\VC9\lib\libcurl.vcproj
|
||||||
|
|
||||||
rem Generate VC10 project files
|
echo.
|
||||||
call :generate vc10 Windows\VC10\src\curlsrc.tmpl Windows\VC10\src\curlsrc.vcxproj
|
echo Generating VC10 project files
|
||||||
call :generate vc10 Windows\VC10\lib\libcurl.tmpl Windows\VC10\lib\libcurl.vcxproj
|
call :generate vcxproj Windows\VC10\src\curlsrc.tmpl Windows\VC10\src\curlsrc.vcxproj
|
||||||
|
call :generate vcxproj Windows\VC10\lib\libcurl.tmpl Windows\VC10\lib\libcurl.vcxproj
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo Generating VC11 project files
|
||||||
|
call :generate vcxproj Windows\VC11\src\curlsrc.tmpl Windows\VC11\src\curlsrc.vcxproj
|
||||||
|
call :generate vcxproj Windows\VC11\lib\libcurl.tmpl Windows\VC11\lib\libcurl.vcxproj
|
||||||
|
|
||||||
goto exit
|
goto exit
|
||||||
|
|
||||||
rem Main generate function.
|
rem Main generate function.
|
||||||
rem
|
rem
|
||||||
rem %1 - IDE
|
rem %1 - Project Type (dsp, vcproj or vcxproj)
|
||||||
rem %2 - Input template file
|
rem %2 - Input template file
|
||||||
rem %3 - Output project file
|
rem %3 - Output project file
|
||||||
rem
|
rem
|
||||||
:generate
|
:generate
|
||||||
echo.
|
|
||||||
|
|
||||||
if not exist %2 (
|
if not exist %2 (
|
||||||
|
echo.
|
||||||
echo Error: Cannot open %CD%\%2
|
echo Error: Cannot open %CD%\%2
|
||||||
exit /B
|
exit /B
|
||||||
)
|
)
|
||||||
|
|
||||||
if exist %3 (
|
if exist %3 (
|
||||||
echo Deleting %3
|
|
||||||
del %3
|
del %3
|
||||||
)
|
)
|
||||||
|
|
||||||
echo Generating %3
|
echo * %CD%\%3
|
||||||
for /f "delims=" %%i in (%2) do (
|
for /f "delims=" %%i in (%2) do (
|
||||||
if "%%i" == "CURL_SRC_C_FILES" (
|
if "%%i" == "CURL_SRC_C_FILES" (
|
||||||
for /f %%c in ('dir /b ..\src\*.c') do call :element %1 src %%c %3
|
for /f %%c in ('dir /b ..\src\*.c') do call :element %1 src %%c %3
|
||||||
@ -81,8 +86,8 @@ rem
|
|||||||
|
|
||||||
rem Generates a single file xml element.
|
rem Generates a single file xml element.
|
||||||
rem
|
rem
|
||||||
rem %1 - IDE
|
rem %1 - Project Type (dsp, vcproj or vcxproj)
|
||||||
rem %2 - Directory (eg src, lib or lib\vtls)
|
rem %2 - Directory (src, lib or lib\vtls)
|
||||||
rem %3 - Source filename
|
rem %3 - Source filename
|
||||||
rem %4 - Output project file
|
rem %4 - Output project file
|
||||||
rem
|
rem
|
||||||
@ -96,7 +101,12 @@ rem
|
|||||||
|
|
||||||
call :extension %3 ext
|
call :extension %3 ext
|
||||||
|
|
||||||
if "%1" == "vc10" (
|
if "%1" == "vcproj" (
|
||||||
|
echo %TABS%^<File>> %4
|
||||||
|
echo %TABS% RelativePath="..\..\..\..\%2\%3">> %4
|
||||||
|
echo %TABS%^>>> %4
|
||||||
|
echo %TABS%^</File^>>> %4
|
||||||
|
) else if "%1" == "vcxproj" (
|
||||||
if "%ext%" == "c" (
|
if "%ext%" == "c" (
|
||||||
echo %SPACES%^<ClCompile Include=^"..\..\..\..\%2\%3^" /^>>> %4
|
echo %SPACES%^<ClCompile Include=^"..\..\..\..\%2\%3^" /^>>> %4
|
||||||
) else if "%ext%" == "h" (
|
) else if "%ext%" == "h" (
|
||||||
@ -104,11 +114,6 @@ rem
|
|||||||
) else if "%ext%" == "rc" (
|
) else if "%ext%" == "rc" (
|
||||||
echo %SPACES%^<ResourceCompile Include=^"..\..\..\..\%2\%3^" /^>>> %4
|
echo %SPACES%^<ResourceCompile Include=^"..\..\..\..\%2\%3^" /^>>> %4
|
||||||
)
|
)
|
||||||
) else (
|
|
||||||
echo %TABS%^<File>> %4
|
|
||||||
echo %TABS% RelativePath="..\..\..\..\%2\%3">> %4
|
|
||||||
echo %TABS%^>>> %4
|
|
||||||
echo %TABS%^</File^>>> %4
|
|
||||||
)
|
)
|
||||||
|
|
||||||
exit /B
|
exit /B
|
||||||
@ -138,4 +143,5 @@ rem
|
|||||||
|
|
||||||
:exit
|
:exit
|
||||||
echo.
|
echo.
|
||||||
|
endlocal
|
||||||
pause
|
pause
|
||||||
|
Loading…
Reference in New Issue
Block a user