Closed justln1113 closed 4 years ago
I don't have a windows machine and cannot test it locally. What I can say is that at least we have windows CI (e.g. https://ci.appveyor.com/project/r9y9/hts-engine-api/branch/master/job/9r2kcif83pkiqkbf) and it seems to work okay and there might be something you can learn from.
If you can give me more detailed information, I may help you.
Okay, I got it. Thank you so much for your reply. I really want NNSVS run on windows and maybe I can write a toolbox for it because my friends want to synthesize and make a voicebank for NNSVS, but they don't know how to use Linux or Google colab, although colab is already very easy to use. Maybe on my windows is using MSVC to compile it. Is there a way to force set waf compiler to gcc? Or can I build with bash and install in windows? I will try it later and continue to report to you. Thank you very much.
Ah, yes, that could be. I seemed to had the same problem quite a while ago https://github.com/r9y9/hts_engine_API/issues/4. Although I'd recommed you to learn how to use Linux and python, you could workaround on this by using mingw instead. See https://github.com/r9y9/hts_engine_API/blob/master/msys_build.sh.
With #13, you should be able to build hts_engine_API with msvc compilers.
Install success. Thank you for solving problems
PS E:\NNSVS\hts_engine_API\src> python ./waf configure --prefix=E:\NNSVS\NNSVS-ENV
Setting top to : E:\NNSVS\hts_engine_API\src
Setting out to : E:\NNSVS\hts_engine_API\src\build
Checking for waf version in 1.7.11-2.1.0 : ok
Checking for 'msvc' (C compiler) : C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX64\x64\CL.exe
Checking for header stdlib.h : yes
Checking for header string.h : yes
hts_engine_API has been configured as follows:
[Build information]
Package: hts_engine_API-1.0.9
build (compile on): amd64-win32
host endian: little
Compiler: msvc
Compiler version:
CFLAGS: /nologo
'configure' finished successfully (6.389s)
PS E:\NNSVS\hts_engine_API\src> python .\waf build
Waf: Entering directory `E:\NNSVS\hts_engine_API\src\build'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX64\x64\CL.exe
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX64\x64\CL.exe
[ 1/13] Compiling lib\HTS_pstream.c
[ 2/13] Compiling lib\HTS_gstream.c
[ 3/13] Compiling lib\HTS_audio.c
[ 4/13] Compiling lib\HTS_model.c
[ 5/13] Compiling lib\HTS_label.c
[ 6/13] Compiling lib\HTS_sstream.c
[ 7/13] Compiling lib\HTS_misc.c
[ 8/13] Compiling lib\HTS_engine.c
[ 9/13] Compiling lib\HTS_vocoder.c
[10/13] Compiling bin\hts_engine.c
[11/13] Compiling hts_engine_API.pc.in
hts_engine.c
HTS_pstream.c
HTS_vocoder.c
HTS_label.c
HTS_sstream.c
HTS_gstream.c
HTS_misc.c
HTS_model.c
HTS_engine.c
E:\NNSVS\hts_engine_API\src\lib\HTS_engine.c(610): warning C4477: 'fprintf' : 格式字串 '%8lu' 需要 'unsigned long' 類型 的引數,但 variadic 引數 1 的類型為 'size_t'
E:\NNSVS\hts_engine_API\src\lib\HTS_engine.c(610): note: 請考慮在格式字串中使用 '%zu'
E:\NNSVS\hts_engine_API\src\lib\HTS_engine.c(612): warning C4477: 'fprintf' : 格式字串 '%8lu' 需要 'unsigned long' 類型 的引數,但 variadic 引數 1 的類型為 'size_t'
E:\NNSVS\hts_engine_API\src\lib\HTS_engine.c(612): note: 請考慮在格式字串中使用 '%zu'
HTS_audio.c
[12/13] Linking build\lib\hts_engine_API-1.dll
正在建立程式庫 lib\hts_engine_API.lib 和物件 lib\hts_engine_API.exp
[13/13] Linking build\bin\hts_engine.exe
Waf: Leaving directory `E:\NNSVS\hts_engine_API\src\build'
'build' finished successfully (1.062s)
PS E:\NNSVS\hts_engine_API\src> python .\waf install
Waf: Entering directory `E:\NNSVS\hts_engine_API\src\build'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX64\x64\CL.exe
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX64\x64\CL.exe
- install E:\NNSVS\NNSVS-ENV\include\HTS_hidden.h (from lib\HTS_hidden.h)
+ install E:\NNSVS\NNSVS-ENV\include\HTS_engine.h (from include\HTS_engine.h)
+ install E:\NNSVS\NNSVS-ENV\bin\hts_engine.exe (from build\bin\hts_engine.exe)
+ install E:\NNSVS\NNSVS-ENV\lib\hts_engine_API-1.dll (from build\lib\hts_engine_API-1.dll)
+ install E:\NNSVS\NNSVS-ENV\lib\hts_engine_API.lib (from build\lib\hts_engine_API.lib)
+ install E:\NNSVS\NNSVS-ENV\lib\pkgconfig\hts_engine_API.pc (from build\hts_engine_API.pc)
Waf: Leaving directory `E:\NNSVS\hts_engine_API\src\build'
'install' finished successfully (0.081s)
I want to use powershell in windows to waf build hts_engine_API and use NNSVS. But I still got this error, seems like it doesn't create hts_engine_API.lib. Thank you very much.