Commit b106642f authored by Andreas Traczyk's avatar Andreas Traczyk

build: alterations for win32/uwp msc compliance

Change-Id: I02061e1319499e694817000e6184d1735c67261f
parent 04556ae8
:: Ring - native Windows fetch and build
@echo off
@setlocal
if "%1" == "/?" goto Usage
if "%~1" == "" goto Usage
set doFetch=N
set doBuildContrib=N
set doBuildDaemon=N
set SCRIPTNAME=%~nx0
if "%1"=="fetch" (
set doFetch=Y
) else if "%1"=="contrib" (
set doBuildContrib=Y
) else if "%1"=="daemon" (
set doBuildDaemon=Y
) else (
goto Usage
)
set BUILD.x86=N
set BUILD.x64=N
set BUILD.uwp=N
set BUILD.win32=N
shift
:ParseArgs
if "%1" == "" goto FinishedArgs
if /I "%1"=="x86" (
set BUILD.x86=Y
) else if /I "%1"=="x64" (
set BUILD.x64=Y
) else if /I "%1"=="uwp" (
set BUILD.uwp=Y
) else if /I "%1"=="win32" (
set BUILD.win32=Y
) else (
goto Usage
)
shift
goto ParseArgs
:FinishedArgs
set CONTRIB_DIR=%~dp0../contrib
set platform=N
set arch=N
if "%BUILD.x86%"=="Y" (
set arch=x86
) else if "%BUILD.x64%"=="Y" (
set arch=x64
)
if "%BUILD.uwp%"=="Y" (
set platform=uwp
if "%arch%"=="x86" (
set DAEMON_MSBUILD_ARGS=/nologo /p:useenv=true /p:Configuration=ReleaseLib /p:Platform=Win32 /verbosity:normal /maxcpucount:%NUMBER_OF_PROCESSORS%
) else if "%arch%"=="x64" (
set DAEMON_MSBUILD_ARGS=/nologo /p:useenv=true /p:Configuration=ReleaseLib /p:Platform=x64 /verbosity:normal /maxcpucount:%NUMBER_OF_PROCESSORS%
)
) else if "%BUILD.win32%"=="Y" (
set platform=win32
if "%arch%"=="x86" (
set DAEMON_MSBUILD_ARGS=/nologo /p:useenv=true /p:Configuration=ReleaseLib_win32 /p:Platform=Win32 /verbosity:normal /maxcpucount:%NUMBER_OF_PROCESSORS%
) else if "%arch%"=="x64" (
set DAEMON_MSBUILD_ARGS=/nologo /p:useenv=true /p:Configuration=ReleaseLib_win32 /p:Platform=x64 /verbosity:normal /maxcpucount:%NUMBER_OF_PROCESSORS%
)
)
if "%arch%" neq "N" (
if "%platform%" neq "N" (
if "%doFetch%" neq "N" (
call %CONTRIB_DIR%\src\fetch_all.bat %platform% %arch%
) else if "%doBuildContrib%" neq "N" (
call %CONTRIB_DIR%\build_all.bat %platform% %arch%
) else if "%doBuildDaemon%" neq "N" (
goto buildDaemon
)
goto :eof
)
)
goto Usage
:buildDaemon
@setlocal
set VSInstallerFolder="%ProgramFiles(x86)%\Microsoft Visual Studio\Installer"
if %PROCESSOR_ARCHITECTURE%==x86 set VSInstallerFolder="%ProgramFiles%\Microsoft Visual Studio\Installer"
pushd %VSInstallerFolder%
for /f "usebackq tokens=*" %%i in (`vswhere -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath`) do (
set VSLATESTDIR=%%i
)
popd
echo VS Installation folder: %VSLATESTDIR%
if not exist "%VSLATESTDIR%\VC\Auxiliary\Build\vcvarsall.bat" (
echo:
echo VSInstallDir not found or not installed correctly.
goto cleanup
)
if %PROCESSOR_ARCHITECTURE%==x86 (
if "%platform%"=="uwp" (
set Comp_x86=x86 uwp 10.0.15063.0
set Comp_x64=x86_amd64 uwp 10.0.15063.0
) else (
set Comp_x86=x86 10.0.15063.0
set Comp_x64=x86_amd64 10.0.15063.0
)
) else (
if "%platform%"=="uwp" (
set Comp_x86=amd64_x86 uwp 10.0.15063.0
set Comp_x64=amd64 uwp 10.0.15063.0
) else (
set Comp_x86=amd64_x86 10.0.15063.0
set Comp_x64=amd64 10.0.15063.0
)
)
set path=%path:"=%
if "%arch%"=="x86" (
call "%VSLATESTDIR%"\\VC\\Auxiliary\\Build\\vcvarsall.bat %Comp_x86%
) else if "%arch%"=="x64" (
call "%VSLATESTDIR%"\\VC\\Auxiliary\\Build\\vcvarsall.bat %Comp_x64%
)
::build the daemon
echo "building daemon..."
msbuild ring-daemon.vcxproj %DAEMON_MSBUILD_ARGS%
goto :eof
@endlocal
:Usage
echo:
echo The correct usage is:
echo:
echo %0 [action] [target platform] [architecture]
echo:
echo where
echo:
echo [action] is: fetch ^| build
echo [target platform] is: uwp ^| win32
echo [architecture] is: x86 ^| x64
echo:
echo For example:
echo %SCRIPTNAME% fetch win32 x86 - fetch contrib for a win32/x86 build
echo %SCRIPTNAME% contrib uwp x64 - build uwp(win10)/x64 contrib
echo %SCRIPTNAME% daemon uwp x64 - build uwp(win10)/x64 daemon
echo:
goto :eof
@endlocal
\ No newline at end of file
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.25420.1
# Visual Studio 15
VisualStudioVersion = 15.0.27703.2026
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ring-daemon", "ring-daemon.vcxproj", "{79F8DE42-595D-49D9-A66F-55244FD9DCC3}"
EndProject
......@@ -8,10 +8,14 @@ Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
DebugLib_win32|x64 = DebugLib_win32|x64
DebugLib_win32|x86 = DebugLib_win32|x86
DebugLib|x64 = DebugLib|x64
DebugLib|x86 = DebugLib|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
ReleaseLib_win32|x64 = ReleaseLib_win32|x64
ReleaseLib_win32|x86 = ReleaseLib_win32|x86
ReleaseLib|x64 = ReleaseLib|x64
ReleaseLib|x86 = ReleaseLib|x86
EndGlobalSection
......@@ -20,6 +24,10 @@ Global
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.Debug|x64.Build.0 = Debug|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.Debug|x86.ActiveCfg = Debug|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.Debug|x86.Build.0 = Debug|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib_win32|x64.ActiveCfg = DebugLib_win32|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib_win32|x64.Build.0 = DebugLib_win32|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib_win32|x86.ActiveCfg = DebugLib_win32|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib_win32|x86.Build.0 = DebugLib_win32|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib|x64.ActiveCfg = DebugLib|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib|x64.Build.0 = DebugLib|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.DebugLib|x86.ActiveCfg = DebugLib|Win32
......@@ -28,6 +36,10 @@ Global
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.Release|x64.Build.0 = Release|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.Release|x86.ActiveCfg = Release|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.Release|x86.Build.0 = Release|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib_win32|x64.ActiveCfg = ReleaseLib_win32|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib_win32|x64.Build.0 = ReleaseLib_win32|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib_win32|x86.ActiveCfg = ReleaseLib_win32|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib_win32|x86.Build.0 = ReleaseLib_win32|Win32
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib|x64.ActiveCfg = ReleaseLib|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib|x64.Build.0 = ReleaseLib|x64
{79F8DE42-595D-49D9-A66F-55244FD9DCC3}.ReleaseLib|x86.ActiveCfg = ReleaseLib|Win32
......@@ -36,4 +48,7 @@ Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {7505C3ED-E07A-48C4-BE60-8BD5A00CC85C}
EndGlobalSection
EndGlobal
This diff is collapsed.
......@@ -59,6 +59,9 @@
<Filter Include="Source Files\dring">
<UniqueIdentifier>{f137f8a1-8c2a-4e49-b73c-835f95507160}</UniqueIdentifier>
</Filter>
<Filter Include="Source Files\media\video\winvideo">
<UniqueIdentifier>{96b01e7f-7e05-480c-85a3-fa35ef5f8b87}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\src\hooks\urlhook.cpp">
......@@ -385,6 +388,12 @@
<ClCompile Include="..\src\media\media_recorder.cpp">
<Filter>Source Files\media</Filter>
</ClCompile>
<ClCompile Include="..\src\media\video\winvideo\video_device_impl.cpp">
<Filter>Source Files\media\video\winvideo</Filter>
</ClCompile>
<ClCompile Include="..\src\media\video\winvideo\video_device_monitor_impl.cpp">
<Filter>Source Files\media\video\winvideo</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\src\account.h">
......@@ -798,6 +807,9 @@
<ClInclude Include="..\src\media\media_stream.h">
<Filter>Source Files\media</Filter>
</ClInclude>
<ClInclude Include="..\src\media\video\winvideo\capture_graph_interfaces.h">
<Filter>Source Files\media\video\winvideo</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="..\src\ringdht\eth\libdevcore\Makefile.am">
......
This diff is collapsed.
......@@ -17,6 +17,6 @@ rename %BUILD%\phc-winner-argon2-%ARGON2_VERSION% argon2
cd %BUILD%\argon2
git apply --reject --whitespace=fix %SRC%\argon2\argon2-uwp.patch
%APPLY_CMD% %SRC%\argon2\argon2-vs2017.patch
cd %SRC%
\ No newline at end of file
@echo OFF
SETLOCAL EnableDelayedExpansion
@echo off
@setlocal enabledelayedexpansion
echo fetching and patching contrib for %1
if "%USE_CACHE%"=="" (
set USE_CACHE=0
......@@ -7,6 +9,17 @@ if "%USE_CACHE%"=="" (
set SRC=%~dp0
set WGET_CMD=wget --no-check-certificate --retry-connrefused --waitretry=1 --read-timeout=20 --timeout=15 --tries=4
set PATCH_CMD=patch -flp1 -i
set APPLY_CMD=git apply --reject --ignore-whitespace --whitespace=fix
if "%1"=="uwp" (
goto uwpDeps
) else if "%1"=="win32" (
goto win32Deps
)
:uwpDeps
set DEPENDENCIES=( ^
ffmpeg, ^
argon2, ^
......@@ -30,11 +43,39 @@ upnp, ^
x264, ^
yaml-cpp, ^
)
goto fetch
set WGET_CMD=wget --no-check-certificate --retry-connrefused --waitretry=1 --read-timeout=20 --timeout=15 --tries=4
set PATCH_CMD=patch -flp1 -i
set APPLY_CMD=git apply --reject --ignore-whitespace --whitespace=fix
:win32Deps
set DEPENDENCIES=( ^
ffmpeg, ^
argon2, ^
zlib ^
gmp, ^
iconv, ^
jsoncpp, ^
msgpack, ^
nettle, ^
gnutls, ^
opendht, ^
opus, ^
pcre, ^
pjproject, ^
portaudio, ^
pthreads, ^
restbed, ^
samplerate, ^
secp256k1, ^
sndfile, ^
upnp, ^
vpx, ^
x264, ^
yaml-cpp, ^
)
goto fetch
:fetch
for %%I in %DEPENDENCIES% do (
call %SRC%\%%I\fetch_and_patch.bat
)
\ No newline at end of file
call %SRC%\%%I\fetch_and_patch.bat %1 %2
)
@endlocal
\ No newline at end of file
#!/bin/bash
set +x
set +e
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
cd $DIR/../../build/ffmpeg
FFMPEGCONF='
--toolchain=msvc
--target-os=win32'
FFMPEGCONF+='
--disable-everything
--disable-programs
--disable-d3d11va
--disable-dxva2
--disable-postproc
--disable-filters'
FFMPEGCONF+='
--enable-shared
--enable-cross-compile
--enable-gpl
--enable-swscale
--enable-protocols
--enable-bsfs'
FFMPEGCONF+='
--enable-demuxers
--enable-muxers'
FFMPEGCONF+='
--enable-parser=h263
--enable-parser=h264
--enable-parser=mpeg4video
--enable-parser=vp8
--enable-parser=vp9
--enable-parser=opus'
FFMPEGCONF+='
--enable-libopus
--enable-encoder=libopus
--enable-decoder=libopus
--enable-encoder=adpcm_g722
--enable-decoder=adpcm_g722
--enable-encoder=pcm_alaw
--enable-decoder=pcm_alaw
--enable-encoder=pcm_mulaw
--enable-decoder=pcm_mulaw'
FFMPEGCONF+='
--enable-libx264
--enable-encoder=libx264
--enable-decoder=h264
--enable-encoder=rawvideo
--enable-decoder=rawvideo
--enable-encoder=mpeg4
--enable-decoder=mpeg4
--enable-encoder=h263
--enable-encoder=h263p
--enable-decoder=h263
--enable-encoder=mjpeg
--enable-decoder=mjpeg
--enable-decoder=mjpegb'
if [ "$1" == "uwp" ]; then
EXTRACFLAGS='-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00 -I../../../../../msvc/include -I../../../../../msvc/include/opus'
if [ "$2" == "x64" ]; then
echo "configure and make ffmpeg for UWP-x64..."
EXTRALDFLAGS='-APPCONTAINER WindowsApp.lib libopus.lib libx264.lib -LIBPATH:../../../../../msvc/lib/x64'
FFMPEGCONF+=' --arch=x86_64'
PREFIX=../../../Build/Windows10/x64
OUTDIR=Output/Windows10/x64
elif [ "$2" == "x86" ]; then
echo "configure and make ffmpeg for UWP-x86..."
EXTRALDFLAGS='-APPCONTAINER WindowsApp.lib libopus.lib libx264.lib -LIBPATH:../../../../../msvc/lib/x86'
FFMPEGCONF+=' --arch=x86'
PREFIX=../../../Build/Windows10/x86
OUTDIR=Output/Windows10/x86
fi
elif [ "$1" == "win32" ]; then
EXTRACFLAGS='-MD -D_WINDLL -I../../../../../msvc/include -I../../../../../msvc/include/opus -I../../../../../msvc/include/vpx'
FFMPEGCONF+='
--enable-libvpx
--enable-encoder=libvpx_vp8
--enable-decoder=vp8
--enable-decoder=vp9'
FFMPEGCONF+='
--enable-indev=dshow
--enable-indev=gdigrab
--enable-dxva2'
if [ "$2" == "x64" ]; then
echo "configure and make ffmpeg for win32-x64..."
EXTRALDFLAGS='-APPCONTAINER:NO -MACHINE:x64 Ole32.lib Kernel32.lib Gdi32.lib User32.lib Strmiids.lib OleAut32.lib Shlwapi.lib Vfw32.lib Secur32.lib libopus.lib libx264.lib libvpx.lib -LIBPATH:../../../../../msvc/lib/x64'
FFMPEGCONF+=' --arch=x86_64'
PREFIX=../../../Build/win32/x64
OUTDIR=Output/win32/x64
elif [ "$2" == "x86" ]; then
echo "configure and make ffmpeg for win32-x86..."
EXTRALDFLAGS='-APPCONTAINER:NO -MACHINE:x86 Ole32.lib Kernel32.lib Gdi32.lib User32.lib Strmiids.lib OleAut32.lib Shlwapi.lib Vfw32.lib Secur32.lib libopus.lib libx264.lib libvpx.lib -LIBPATH:../../../../../msvc/lib/x86'
FFMPEGCONF+=' --arch=x86'
PREFIX=../../../Build/win32/x86
OUTDIR=Output/win32/x86
fi
fi
rm -rf $OUTDIR
mkdir -p $OUTDIR
cd $OUTDIR
pwd
FFMPEGCONF=$(echo $FFMPEGCONF | sed -e "s/[[:space:]]\+/ /g")
set -x
set -e
../../../configure $FFMPEGCONF --extra-cflags="${EXTRACFLAGS}" --extra-ldflags="${EXTRALDFLAGS}" --prefix="${PREFIX}"
make -j8 install
cd ../../..
\ No newline at end of file
......@@ -27,6 +27,37 @@
for linkunit in $LIBRARY_LIST $PROGRAM_LIST $EXTRALIBS_LIST; do
eval ${linkunit}_extralibs=\$\(flatten_extralibs_wrapper ${linkunit}_extralibs\)
done
@@ -6068,29 +6068,7 @@ enabled libvo_amrwbenc && require libvo_amrwbenc vo-amrwbenc/enc_if.h E_IF_in
enabled libvorbis && require_pkg_config libvorbis vorbis vorbis/codec.h vorbis_info_init &&
require_pkg_config libvorbisenc vorbisenc vorbis/vorbisenc.h vorbis_encode_init
-enabled libvpx && {
- enabled libvpx_vp8_decoder && {
- check_pkg_config libvpx_vp8_decoder "vpx >= 1.4.0" "vpx/vpx_decoder.h vpx/vp8dx.h" vpx_codec_vp8_dx ||
- check_lib libvpx_vp8_decoder "vpx/vpx_decoder.h vpx/vp8dx.h" "vpx_codec_dec_init_ver VPX_IMG_FMT_HIGHBITDEPTH" -lvpx ||
- die "ERROR: libvpx decoder version must be >=1.4.0";
- }
- enabled libvpx_vp8_encoder && {
- check_pkg_config libvpx_vp8_encoder "vpx >= 1.4.0" "vpx/vpx_encoder.h vpx/vp8cx.h" vpx_codec_vp8_cx ||
- check_lib libvpx_vp8_encoder "vpx/vpx_encoder.h vpx/vp8cx.h" "vpx_codec_enc_init_ver VPX_IMG_FMT_HIGHBITDEPTH" -lvpx ||
- die "ERROR: libvpx encoder version must be >=1.4.0";
- }
- enabled libvpx_vp9_decoder && {
- check_pkg_config libvpx_vp9_decoder "vpx >= 1.4.0" "vpx/vpx_decoder.h vpx/vp8dx.h" vpx_codec_vp9_dx ||
- check_lib libvpx_vp9_decoder "vpx/vpx_decoder.h vpx/vp8dx.h" "vpx_codec_vp9_dx VPX_IMG_FMT_HIGHBITDEPTH" "-lvpx $libm_extralibs"
- }
- enabled libvpx_vp9_encoder && {
- check_pkg_config libvpx_vp9_encoder "vpx >= 1.4.0" "vpx/vpx_encoder.h vpx/vp8cx.h" vpx_codec_vp9_cx ||
- check_lib libvpx_vp9_encoder "vpx/vpx_encoder.h vpx/vp8cx.h" "vpx_codec_vp9_cx VPX_IMG_FMT_HIGHBITDEPTH" "-lvpx $libm_extralibs"
- }
- if disabled_all libvpx_vp8_decoder libvpx_vp9_decoder libvpx_vp8_encoder libvpx_vp9_encoder; then
- die "libvpx enabled but no supported decoders found"
- fi
-}
+
enabled libwavpack && require libwavpack wavpack/wavpack.h WavpackOpenFileOutput -lwavpack
enabled libwebp && {
--
2.10.2.windows.1
#!/bin/bash
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
echo "configure and make ffmpeg for UWP-x64..."
cd $DIR/../../build/ffmpeg
rm -rf Output/Windows10/x64
mkdir -p Output/Windows10/x64
cd Output/Windows10/x64
../../../configure \
--toolchain=msvc \
--enable-gpl \
--disable-programs \
--disable-d3d11va \
--disable-dxva2 \
--disable-debug \
--disable-postproc \
--arch=x86_64 \
--enable-shared \
--enable-cross-compile \
--target-os=win32 \
--enable-libopus \
--enable-encoder=libopus \
--enable-decoder=libopus \
--enable-encoder=libx264 \
--enable-decoder=h264 \
--enable-parser=h264 \
--enable-libx264 \
--extra-cflags="-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00 -I../../../../../msvc/include -I../../../../../msvc/include/opus" \
--extra-ldflags="-APPCONTAINER WindowsApp.lib libopus.lib libx264.lib -LIBPATH:../../../../../msvc/lib/x64" \
--prefix=../../../Build/Windows10/x64
make -j8 install
cd ../../..
\ No newline at end of file
......@@ -19,6 +19,11 @@ cd %BUILD%\gnutls
%APPLY_CMD% %SRC%\gnutls\gnutls-no-egd.patch
%APPLY_CMD% %SRC%\gnutls\read-file-limits.h.patch
%APPLY_CMD% %SRC%\gnutls\gnutls-uwp.patch
if "%1"=="uwp" (
%APPLY_CMD% %SRC%\gnutls\gnutls-uwp.patch
)
%APPLY_CMD% %SRC%\gnutls\gnutls-mscver.patch
cd %SRC%
This diff is collapsed.
This diff is collapsed.
set BUILD=%SRC%..\build
set OPENDHT_VERSION=1.7.3rc2
set OPENDHT_VERSION=7a961ffc517e7c5673aede79301ece2719ed3b45
set OPENDHT_URL=https://github.com/savoirfairelinux/opendht/archive/%OPENDHT_VERSION%.tar.gz
mkdir %BUILD%
......
......@@ -160,7 +160,7 @@
+ <Optimization>Disabled</Optimization>
+ <SDLCheck>true</SDLCheck>
+ <AdditionalIncludeDirectories>..\..\include;..\include;..\include\opendht;..\..\argon2\include;..\..\msgpack-c\include;..\..\..\msvc\include;..\..\jsoncpp\include;..\..\restbed\source</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>OPENDHT_JSONCPP;_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <DisableSpecificWarnings>4804;4800;4101;4267;4244;4503;</DisableSpecificWarnings>
+ <AdditionalOptions>-D_SCL_SECURE_NO_WARNINGS %(AdditionalOptions)</AdditionalOptions>
+ <SuppressStartupBanner>false</SuppressStartupBanner>
......@@ -183,7 +183,7 @@
+ <Optimization>Disabled</Optimization>
+ <SDLCheck>true</SDLCheck>
+ <AdditionalIncludeDirectories>..\..\include;..\include;..\include\opendht;..\..\argon2\include;..\..\msgpack-c\include;..\..\..\msvc\include;..\..\jsoncpp\include;..\..\restbed\source</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>OPENDHT_PROXY_CLIENT;OPENDHT_PROXY_SERVER;OPENDHT_PUSH_NOTIFICATIONS;_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>OPENDHT_JSONCPP;OPENDHT_PROXY_CLIENT;OPENDHT_PROXY_SERVER;OPENDHT_PUSH_NOTIFICATIONS;_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <DisableSpecificWarnings>4804;4800;4101;4267;4244;4503;</DisableSpecificWarnings>
+ <AdditionalOptions>-D_SCL_SECURE_NO_WARNINGS %(AdditionalOptions)</AdditionalOptions>
+ </ClCompile>
......@@ -207,7 +207,7 @@
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <AdditionalIncludeDirectories>..\..\include;..\include;..\include\opendht;..\..\argon2\include;..\..\msgpack-c\include;..\..\..\msvc\include;..\..\jsoncpp\include;..\..\restbed\source</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>OPENDHT_JSONCPP;_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <DisableSpecificWarnings>4804;4800;4101;4267;4244;4503;</DisableSpecificWarnings>
+ <AdditionalOptions>-D_SCL_SECURE_NO_WARNINGS %(AdditionalOptions)</AdditionalOptions>
+ <ProgramDataBaseFileName>$(OutDir)\lib\x86\$(TargetName).pdb</ProgramDataBaseFileName>
......@@ -237,7 +237,7 @@
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <AdditionalIncludeDirectories>..\..\include;..\include;..\include\opendht;..\..\argon2\include;..\..\msgpack-c\include;..\..\..\msvc\include;..\..\jsoncpp\include;..\..\restbed\source</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>OPENDHT_PROXY_CLIENT;OPENDHT_PROXY_SERVER;OPENDHT_PUSH_NOTIFICATIONS;_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>OPENDHT_JSONCPP;OPENDHT_PROXY_CLIENT;OPENDHT_PROXY_SERVER;OPENDHT_PUSH_NOTIFICATIONS;_CRT_SECURE_NO_WARNINGS;WIN32_NATIVE;WIN32_LEAN_AND_MEAN;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <DisableSpecificWarnings>4804;4800;4101;4267;4244;4503;4273;</DisableSpecificWarnings>
+ <AdditionalOptions>-D_SCL_SECURE_NO_WARNINGS %(AdditionalOptions)</AdditionalOptions>
+ <ProgramDataBaseFileName>$(OutDir)\lib\x64\$(TargetName).pdb</ProgramDataBaseFileName>
......
......@@ -17,7 +17,6 @@ rename %BUILD%\pjproject-%PJPROJECT_VERSION% pjproject
cd %BUILD%\pjproject
echo off
for /F "tokens=* usebackq" %%F in (`bash -c "pwd | grep /mnt/c/"`) do (
set NO_AUTO=%%F
)
......@@ -42,6 +41,8 @@ bash -c "%PATCH_CMD% %UNIXPATH%pjproject/rfc6062.patch"
%APPLY_CMD% %SRC%\pjproject\pj_vs_config.patch
%APPLY_CMD% %SRC%\pjproject\pj_vs2017_props.patch
%APPLY_CMD% %SRC%\pjproject\pj_uwp.patch
if "%1"=="uwp" (
%APPLY_CMD% %SRC%\pjproject\pj_uwp.patch
)
cd %SRC%
\ No newline at end of file
......@@ -17,6 +17,9 @@ del pa_stable_%PA_VERSION%.tgz && del pa_stable_%PA_VERSION%.tar
cd %BUILD%\portaudio
%APPLY_CMD% %SRC%\portaudio\pa-vs2017.patch
%APPLY_CMD% %SRC%\portaudio\pa-uwp.patch
if "%1"=="uwp" (
%APPLY_CMD% %SRC%\portaudio\pa-uwp.patch
)
cd %SRC%
\ No newline at end of file
......@@ -19,7 +19,11 @@ rename %BUILD%\%PTHREADS_VERSION2% pthreads
cd %BUILD%\pthreads
%APPLY_CMD% %SRC%\pthreads\pthreads-windows.patch
%APPLY_CMD% %SRC%\pthreads\pthreads-uwp.patch
if "%1"=="uwp" (
%APPLY_CMD% %SRC%\pthreads\pthreads-uwp.patch
)
%APPLY_CMD% %SRC%\pthreads\pthreads-vs2017.patch
cd %SRC%
\ No newline at end of file
......@@ -43,7 +43,11 @@ del %ASIO_VERSION%.tar && del %ASIO_VERSION%.tar.gz && del pax_global_header
rename asio-dependency-%ASIO_VERSION% asio
cd asio
%APPLY_CMD% %SRC%\restbed\asio-uwp.patch
if "%1"=="uwp" (
%APPLY_CMD% %SRC%\restbed\asio-uwp.patch
)
cd ..
rem ------------ catch ------------
......@@ -77,7 +81,11 @@ del %OPENSSL_VERSION%.tar && del %OPENSSL_VERSION%.tar.gz && del pax_global_head
rename openssl-%OPENSSL_VERSION% openssl
cd openssl
%APPLY_CMD% %SRC%\restbed\openssl-uwp.patch
if "%1"=="uwp" (
%APPLY_CMD% %SRC%\restbed\openssl-uwp.patch
)
cd ..
rem ------------ kashmir ------------
......
......@@ -17,6 +17,6 @@ rename %BUILD%\libsndfile-%SNDFILE_VERSION% sndfile
cd %BUILD%\sndfile
%APPLY_CMD% %SRC%\sndfile\vs2017.patch
%APPLY_CMD% %SRC%\sndfile\sndfile-vs2017.patch
cd %SRC%
\ No newline at end of file
--- /dev/null
+++ b/msvc/libsndfile.vcxproj
@@ -0,0 +1,212 @@
@@ -0,0 +1,210 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup Label="ProjectConfigurations">
......@@ -142,8 +142,6 @@
+ <ClCompile Include="..\src\file_io.c" />
+ <ClCompile Include="..\src\flac.c" />
+ <ClCompile Include="..\src\float32.c" />
+ <ClCompile Include="..\src\g72x.c" />
+ <ClCompile Include="..\src\gsm610.c" />
+ <ClCompile Include="..\src\htk.c" />
+ <ClCompile Include="..\src\id3.c" />
+ <ClCompile Include="..\src\ima_adpcm.c" />
......@@ -305,7 +303,7 @@
+#define HAVE_GMTIME 0
+
+/* Define to 1 if you have the `gmtime_r' function. */
+#define HAVE_GMTIME_R 0
+#undef HAVE_GMTIME_R
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#define HAVE_INTTYPES_H 1
......@@ -1223,6 +1221,89 @@
+
+#endif /* SNDFILE_H */
+
--- a/src/wav.c
+++ b/src/wav.c
@@ -272,14 +272,14 @@ wav_open (SF_PRIVATE *psf)
error = wav_w64_msadpcm_init (psf, blockalign, framesperblock) ;
break ;
- case SF_FORMAT_G721_32 :
+ /*case SF_FORMAT_G721_32 :
error = g72x_init (psf) ;
- break ;
+ break ;*/
/* Lite remove end */
- case SF_FORMAT_GSM610 :
+ /*case SF_FORMAT_GSM610 :
error = gsm610_init (psf) ;
- break ;
+ break ;*/
default : return SFE_UNIMPLEMENTED ;
} ;
--- a/src/aiff.c
+++ b/src/aiff.c
@@ -344,9 +344,9 @@ aiff_open (SF_PRIVATE *psf)
break ;
/* Lite remove end */
- case SF_FORMAT_GSM610 :
+ /*case SF_FORMAT_GSM610 :
error = gsm610_init (psf) ;
- break ;
+ break ;*/
default : return SFE_UNIMPLEMENTED ;
} ;
--- a/src/au.c
+++ b/src/au.c
@@ -161,7 +161,7 @@ au_open (SF_PRIVATE *psf)
error = double64_init (psf) ;
break ;
- case SF_FORMAT_G721_32 :
+ /*case SF_FORMAT_G721_32 :
error = g72x_init (psf) ;
psf->sf.seekable = SF_FALSE ;
break ;
@@ -174,7 +174,7 @@ au_open (SF_PRIVATE *psf)
case SF_FORMAT_G723_40 :
error = g72x_init (psf) ;