1

I cannot get running POCO into my already created project. I did new project with example Websocket, tried to configurate it to success build => app is able to start and working. But when I am trying to implement with same steps into my another project with OpenCV, I have a lot of errors.

Code I am using for both projects to build:

#define POCO_STATIC
#include "pocoWebSocket.h"

#include <iostream>
#include <string>
using namespace std;

int main(int argc, char** argv)
{
    std::cout << std::endl<< "I am alive!" << std::endl;
    WebSocketServer app;
    std::cout << "app run" << std::endl;
    return app.run(argc, argv);
    //visit http://localhost:9980
}

The project setup is:

  • C/C++ / code generation / runtime library: /MT
  • C/C++ / General / Additional Include Directories: C:\src\POCO\Foundation\include;C:\src\POCO\Net\include;C:\src\POCO\Util\include;%(AdditionalIncludeDirectories)

in Linker:

  • General / Additional Library Directories: C:\src\POCO\buildMT\lib\Debug;C:\src\POCO\buildMT\lib\Release;%(AdditionalLibraryDirectories)
  • Input / Additional Dependencies: crypt32.lib ws2_32.lib iphlpapi.lib PocoNetmt.lib PocoFoundationmt.lib

When I will do the same with project with OpenCV I will get these errors: Any advice?

Build started...
1>------ Build started: Project: StitchingApp, Configuration: Debug x64 ------
1>main.cpp
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(190,3): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(192,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(193,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,13): error C3646: 'szlDevice': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,13): error C3646: 'szlMillimeters': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ')' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ';' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7718,36): error C2059: syntax error: ')'
1>trStitcher.cpp
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(190,3): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(192,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(193,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,13): error C3646: 'szlDevice': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,13): error C3646: 'szlMillimeters': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ')' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ';' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7718,36): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(879,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(879,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(902,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(902,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1262,34): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1266,36): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,11): error C3646: 'sizel': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(2668,24): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(3207,36): error C2061: syntax error: identifier 'LPSIZEL'
1>trStitcher_calculation.cpp
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(190,3): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(192,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(193,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,13): error C3646: 'szlDevice': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,13): error C3646: 'szlMillimeters': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1113,13): error C3646: 'szlMicrometers': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1113,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(4009,67): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5143,98): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5612,13): error C3646: 'szlExtent': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5612,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ')' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ';' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7718,36): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(879,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(879,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(902,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(902,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1262,34): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1266,36): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,11): error C3646: 'sizel': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(2668,24): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(3207,36): error C2061: syntax error: identifier 'LPSIZEL'
1>trStitcher_core.cpp
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(190,3): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(192,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(193,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,13): error C3646: 'szlDevice': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,13): error C3646: 'szlMillimeters': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1113,13): error C3646: 'szlMicrometers': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1113,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(4009,67): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(4033,71): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5143,98): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5612,13): error C3646: 'szlExtent': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5612,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5666,13): error C3646: 'szlCorner': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5666,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5777,13): error C3646: 'szlStroke': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5777,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(4547,14): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(4562,11): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(4562,11): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(4562,22): error C2238: unexpected token(s) preceding ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ')' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ';' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7718,36): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(879,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(879,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(902,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(902,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1262,34): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1266,36): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,11): error C3646: 'sizel': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(2668,24): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(3207,36): error C2061: syntax error: identifier 'LPSIZEL'
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_core.cpp(15,29): warning C4267: '=': conversion from 'size_t' to 'int', possible loss of data
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_core.cpp(281,102): warning C4244: 'argument': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=int
1>        ]
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_core.cpp(281,70): warning C4244: 'argument': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=int
1>        ]
1>trStitcher_IO_processing.cpp
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(190,3): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(192,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(193,9): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,13): error C3646: 'szlDevice': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1102,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,13): error C3646: 'szlMillimeters': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1103,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1113,13): error C3646: 'szlMicrometers': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(1113,27): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(4009,67): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(4033,71): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5143,98): error C2061: syntax error: identifier 'LPSIZE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5612,13): error C3646: 'szlExtent': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5612,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5666,13): error C3646: 'szlCorner': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\wingdi.h(5666,22): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(4562,11): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(4562,22): error C2238: unexpected token(s) preceding ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ')' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2143: syntax error: missing ';' before 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7715,16): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winuser.h(7718,36): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,13): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(873,17): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,25): error C3646: 'Size': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winspool.h(914,29): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1262,34): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1266,36): error C2061: syntax error: identifier 'SIZEL'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,11): error C3646: 'sizel': unknown override specifier
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(1524,16): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(2668,24): error C2059: syntax error: 'constant'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\oleidl.h(3207,36): error C2061: syntax error: identifier 'LPSIZEL'
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_IO_processing.cpp(15,34): warning C4244: '=': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=float
1>        ]
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_IO_processing.cpp(21,30): warning C4244: '=': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=float
1>        ]
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_IO_processing.cpp(33,62): warning C4244: 'argument': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=int
1>        ]
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_IO_processing.cpp(33,36): warning C4244: 'argument': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=int
1>        ]
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_IO_processing.cpp(201,116): warning C4244: 'argument': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=int
1>        ]
1>E:\JOB\StitchingProject\StitchingApp\src\trStitcher_IO_processing.cpp(201,77): warning C4244: 'argument': conversion from 'double' to '_Tp', possible loss of data
1>        with
1>        [
1>            _Tp=int
1>        ]
1>Generating Code...
1>Done building project "StitchingApp.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Jan Retych
  • 53
  • 8
  • 1
    *In Linker:* -- All of those errors are compiler errors. There are no linker errors, so linker settings play no role in the issues you're having. – PaulMcKenzie Mar 27 '21 at 17:04
  • @PaulMcKenzie /MT and /MD are compiler options and enable different sets of defined macros. – 273K Mar 27 '21 at 17:05
  • I know that -- it is the `In Linker` settings that were posted. The issues haven't even gotten to the link stage. – PaulMcKenzie Mar 27 '21 at 17:06
  • In the body of the post: `in Linker:`. Trying to inform the @OP that those settings do not come into play at the stage where they are being stuck on. – PaulMcKenzie Mar 27 '21 at 17:08
  • Is `pocoWebSocket.h` an actual header from the POCO library, or is it something you created? – PaulMcKenzie Mar 27 '21 at 17:13
  • @PaulMcKenzie it is copied from POCO example, I only renamed it, link here: https://github.com/pocoproject/poco/blob/master/Net/samples/WebSocketServer/src/WebSocketServer.cpp – Jan Retych Mar 27 '21 at 17:44
  • Cannot be problem I´ve build two POCO versions? I tried delete POCO from project, but the errors are still in, I have two system PATHS to the libraries, one for without MT and second with MT. – Jan Retych Mar 27 '21 at 18:07

2 Answers2

2

C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\shared\windef.h(190,3):

186: typedef struct tagSIZE
187: {
188:    LONG        cx;
189:    LONG        cy;
190: } SIZE, *PSIZE, *LPSIZE;
     ^ ^
     1 3

Somewhere in your code or used libraries, the conflicting macro SIZE is defined.

273K
  • 29,503
  • 10
  • 41
  • 64
  • I tried to add #pragma once but it is not solving the problem. Have you any idea how to solve it? – Jan Retych Mar 27 '21 at 17:53
  • The issue will not be solved with `#pragma once`. According to the answer given, you have somewhere where `SIZE` is being defined, and then it clashes with the posted answer. If it's in the POCO libraries, then that is a very poor name to be using for a macro (`SIZE`), since there is a high chance that it will clash somewhere. – PaulMcKenzie Mar 27 '21 at 18:04
0

Big slap from someone please to me... I accidently define SIZE and other stuff when I was teaching my friend how to code and accidently save it to my solution.... I also had to comment some more stuff to make it work.

Thanks for little push I needed from you guys, appreciate it.

Here is my file I had to edit, commented ones werent commented, config.h:

#pragma once
#ifndef STITCHING_CONFIG
#define STITCHING_CONFIG
#include <stdio.h>
#include <iostream> 
#include <string>
#include <vector>
//static const uint32_t SupportedWidth[] = { 320, 480, 640, 800, 960, 1120, 1600, 1920, 2048, 2592, 3264, 3840, 4224 };
//static const uint32_t SupportedHeight[] = { 240, 360, 480, 600, 720, 840,  1200, 1080, 1536, 1944, 2448, 2160, 3156 };


//#define PORT 8004
//#define FPS 1.0
//#define SIZE 7
#define INPUTRESIZE 0.5
#define OUTPUTRESIZE 1.0
#define NUMBEROFIMAGES 3

#define DEBUGID 0
#define DEBUGON false
#define DEBUGTIMESON false
#define DEBUGSTITCHINGINFO true
#define SLOWDEBUGON false
#define RUNVAL 0

#if RUNVAL == 0
#define DEBUGMODESTITCHINGAPP
#elif RUNVAL == 1
#define TESTING
#elif RUNVAL == 2
#define RUNCALIBRATION
#else 
#define RUNSTITCHINGAPP 
#endif
#endif
Jan Retych
  • 53
  • 8