Author Topic: Compilation Issue using VS 2015  (Read 1338 times)

Long

  • Newbie
  • *
  • Posts: 3
Compilation Issue using VS 2015
« on: February 01, 2017, 01:46:35 PM »
Hi,

I am trying compile Kratos using VS2015.
The configuration I have used are:
- Windows 7
- VS 2015 community
- Python 3.4.3
- Boost 1.59

I successfully configured Kratos without error, which I also checked against the figure shown in the KratosWiki guide page for Windows installation.
After complilation I got 2 errors:

1.

Error   C3016   'i': index variable in OpenMP 'for' statement must have signed integral type   
Project:KratosMeshingApplication
File:   E:\Kratos\kratos\applications\MeshingApplication\custom_utilities\metrics_utility.h   
Line: 273

2.

Error   MSB3073   The command "setlocal
C:\CMake\bin\cmake.exe -DBUILD_TYPE=Release -P cmake_install.cmake
if %errorlevel% neq 0 goto :cmEnd
:cmEnd
endlocal & call :cmErrorLevel %errorlevel% & goto :cmDone
:cmErrorLevel
exit /b %1
:cmDone
if %errorlevel% neq 0 goto :VCEnd
:VCEnd" exited with code 1.   
Project: INSTALL   
File: C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targets   
Line:133

Can you please tell me how to solve this issue?
Thank you.

Long





pooyan

  • Global Moderator
  • Newbie
  • *****
  • Posts: 33
Re: Compilation Issue using VS 2015
« Reply #1 on: February 01, 2017, 04:42:02 PM »
I have just committed a fix for this error. Please let us know if it works. The problem comes from the fact that VS does not support OpenMP loop with unsigned int.

Bests,

Pooyan.

Long

  • Newbie
  • *
  • Posts: 3
Re: Compilation Issue using VS 2015
« Reply #2 on: February 01, 2017, 06:39:39 PM »
Hello Pooyan,

I fetched the new code and it works now. Thanks very much.

Best,
Long

Long

  • Newbie
  • *
  • Posts: 3
Re: Compilation Issue using VS 2015
« Reply #3 on: February 02, 2017, 02:55:05 PM »
Hello,

I am trying to compile Kratos in debug mode using VS2015.
For this purpose, I installed the Python version 3.5.3 together with the debug binaries. After that I compiled the boost 1.59 in debug mode. I created a new folder cmake_build_debug and I modified my configure file as follows:

-DBOOST_ROOT="E:\Kratos_Libs\boost_1_59_0_debug\boost_1_59_0"              ^
-DPYTHON_LIBRARY="C:\Python35\libs\python35.lib"                                        ^
-DPYTHON_INCLUDE_PATH="C:\Python35\include"                                            ^
-DLAPACK_LIBRARIES="E:\Kratos_Libs\BLASandLAPACK\liblapack.lib"                 ^
-DBLAS_LIBRARIES="E:\Kratos_Libs\BLASandLAPACK\libblas.lib"                        ^

here I changed the boost_root to the new boost libraries compiled in debug mode, and adjust the python libraries as well as its path to version 3.5.

After compiling, I got 3 errors shown below:

1.
Error   D8016   '/O2' and '/RTC1' command-line options are incompatible   
project:tetgen
File:   E:\kratos\cmake_build_debug\applications\MeshingApplication\custom_external_libraries\tetgen\tetgen1.4.3\cl
Line:   1

2.

Error   LNK1104   cannot open file 'custom_external_libraries\tetgen\tetgen1.4.3\Debug\tetgen.lib'   
project: KratosMeshingApplication   
file: E:\kratos\cmake_build_debug\applications\MeshingApplication\LINK   
line: 1

3.
Error   LNK1104   cannot open file 'python35_d.lib'   runkratos   
file: E:\kratos\cmake_build_debug\embedded_python\LINK   
line: 1

For the error 3: I checked in my "PYTHON_INCLUDE_PATH" (C:\Python35\libs) and the file "python35_d.lib" does exist. I also added this directory to the system PATH for all users.

Can you please tell me how I can fix this issue?
Thanks in advance.

Best,
Long