Windows build environment

- Added no_rs_cppwarning for build
- Added rs_use_native_dialogs with commandline "nativedialogs"
- Added copy of sounds from plugin VOIP
This commit is contained in:
thunder2 2020-11-29 22:05:03 +01:00
parent 38f9c81050
commit 5a4f33aa51
5 changed files with 19 additions and 7 deletions

View File

@ -13,11 +13,11 @@ call "%~dp0build-libs\build-libs.bat"
if errorlevel 1 %cecho% error "Failed to build libraries." & exit /B %ERRORLEVEL%
%cecho% info "Build %SourceName%"
call "%~dp0build\build.bat" release autologin jsonapi plugins
call "%~dp0build\build.bat" release autologin jsonapi plugins nativedialogs
if errorlevel 1 %cecho% error "Failed to build %SourceName%." & exit /B %ERRORLEVEL%
%cecho% info "Pack %SourceName%"
call "%~dp0build\pack.bat" release
call "%~dp0build\pack.bat" release plugins
if errorlevel 1 %cecho% error "Failed to pack %SourceName%." & exit /B %ERRORLEVEL%
%cecho% info "Build installer"

View File

@ -49,10 +49,11 @@ echo.
title Build - %SourceName%-%RsBuildConfig% [qmake]
set RS_QMAKE_CONFIG=%RsBuildConfig%
set RS_QMAKE_CONFIG=%RsBuildConfig% no_rs_cppwarning
if "%ParamAutologin%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_autologin
if "%ParamJsonApi%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_jsonapi
if "%ParamPlugins%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% retroshare_plugins
if "%ParamUseNativeDialogs%"=="1" set RS_QMAKE_CONFIG=%RS_QMAKE_CONFIG% rs_use_native_dialogs
qmake "%SourcePath%\RetroShare.pro" -r -spec win32-g++ "CONFIG+=%RS_QMAKE_CONFIG%" "EXTERNAL_LIB_DIR=%BuildLibsPath%\libs"
if errorlevel 1 goto error

View File

@ -4,6 +4,7 @@ set ParamDebug=0
set ParamAutologin=0
set ParamPlugins=0
set ParamJsonApi=0
set ParamUseNativeDialogs=0
set ParamTor=0
set NonInteractive=0
set CoreCount=%NUMBER_OF_PROCESSORS%
@ -27,6 +28,8 @@ if "%~1" NEQ "" (
set NonInteractive=1
) else if "%%~a"=="singlethread" (
set CoreCount=1
) else if "%%~a"=="nativedialogs" (
set ParamUseNativeDialogs=1
) else (
echo.
echo Unknown parameter %1
@ -96,7 +99,7 @@ exit /B 0
:usage
echo.
echo Usage: release^|debug [version autologin plugins]
echo Usage: release^|debug [^<optional parameters^>]
echo.
echo Mandatory parameter
echo release^|debug Build release or debug version
@ -105,6 +108,7 @@ echo Optional parameter (need clean when changed)
echo autologin Build with autologin
echo jsonapi Build with jsonapi
echo plugins Build plugins
echo nativedialogs Build with native dialogs
echo.
echo Optional parameter
echo singlethread Use only 1 thread for building

View File

@ -99,9 +99,11 @@ copy "%RsBuildPath%\retroshare-service\src\%RsBuildConfig%\retroshare*-service.e
if exist "%RsBuildPath%\libretroshare\src\lib\retroshare.dll" copy "%RsBuildPath%\libretroshare\src\lib\retroshare.dll" "%RsDeployPath%" %Quite%
echo copy extensions
for /D %%D in ("%RsBuildPath%\plugins\*") do (
call :copy_extension "%%D" "%RsDeployPath%\Data\%Extensions%"
call :copy_dependencies "%RsDeployPath%\Data\%Extensions%\%%~nxD.dll" "%RsDeployPath%"
if "%ParamPlugins%"=="1" (
for /D %%D in ("%RsBuildPath%\plugins\*") do (
call :copy_extension "%%D" "%RsDeployPath%\Data\%Extensions%"
call :copy_dependencies "%RsDeployPath%\Data\%Extensions%\%%~nxD.dll" "%RsDeployPath%"
)
)
echo copy external binaries
@ -141,6 +143,9 @@ rmdir /S /Q "%RsDeployPath%\stylesheets\__MACOSX__Bubble" %Quite%
echo copy sounds
xcopy /S "%SourcePath%\retroshare-gui\src\sounds" "%RsDeployPath%\sounds" %Quite%
if "%ParamPlugins%"=="1" (
xcopy /S "%SourcePath%\plugins\Voip\gui\sounds" "%RsDeployPath%\sounds" %Quite%
)
echo copy license
xcopy /S "%SourcePath%\retroshare-gui\src\license" "%RsDeployPath%\license" %Quite%

View File

@ -314,6 +314,8 @@ ${!defineifexist} PLUGIN_VOIP_EXISTS "${RELEASEDIR}\plugins\VOIP\lib\VOIP.dll"
Section $(Section_Plugin_VOIP) Section_Plugin_VOIP
SetOutPath "$DataDir\extensions6"
File "${RELEASEDIR}\plugins\VOIP\lib\VOIP.dll"
SetOutPath "$INSTDIR\sounds"
File /r "${SOURCEDIR}\plugins\VOIP\gui\sounds\*.*"
SectionEnd
!endif
SectionGroupEnd