mz-automation / libiec61850

Official repository for libIEC61850, the open-source library for the IEC 61850 protocols
http://libiec61850.com/libiec61850
GNU General Public License v3.0
828 stars 444 forks source link

libiec61850-1.5 goose build fail #508

Closed chenjing1294 closed 4 weeks ago

chenjing1294 commented 4 weeks ago

version: libiec61850-1.5 I have installed winpcap as required and Copy the folders Lib and Include from the WpdPack directory in the third_party/winpcap directory of libiec61850

C:\Users\chenjing\Desktop\libiec61850-1.5\sol2>cmake -G "Visual Studio 17 2022" .. -A x64
-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.19045.
-- The C compiler identification is MSVC 19.40.33811.0
-- The CXX compiler identification is MSVC 19.40.33811.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for clock_gettime in rt
-- Looking for clock_gettime in rt - not found
-- Performing Test SUPPORT_REDUNDANT_DECLS
-- Performing Test SUPPORT_REDUNDANT_DECLS - Failed
Found winpcap -> compile ethernet HAL layer (required for GOOSE/SV support)
Found winpcap -> can compile with GOOSE support
server-example-logging: sqlite not found
Found winpcap -> compile examples for GOOSE and SV
Found winpcap -> can compile with GOOSE support
-- Generating RC file : C:/Users/chenjing/Desktop/libiec61850-1.5/sol2/src/version.rc
-- Performing Test COMPILER_HAS_DEPRECATED_ATTR
-- Performing Test COMPILER_HAS_DEPRECATED_ATTR - Failed
-- Performing Test COMPILER_HAS_DEPRECATED
-- Performing Test COMPILER_HAS_DEPRECATED - Success
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
-- Configuring done (12.3s)
-- Generating done (2.2s)
-- Build files have been written to: C:/Users/chenjing/Desktop/libiec61850-1.5/sol2

C:\Users\chenjing\Desktop\libiec61850-1.5\sol2>

When I build iec61850-shared I get an error

LNK2019 unresolved external symbol pcap_close, Ethernet_destroySocket   iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_open_live, Ethernet_createSocket    iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_next_ex, Ethernet_receivePacket     iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_setfilter, Ethernet_setProtocolFilter   iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_sendpacket, Ethernet_sendPacket     iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_geterr, Ethernet_sendPacket     iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_compile, Ethernet_setProtocolFilter     iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_freealldevs, "char * __cdecl getInterfaceName(int)" (?getInterfaceName@@YAPEADH@Z)  iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
LNK2019 unresolved external symbol pcap_findalldevs_ex, "char * __cdecl getInterfaceName(int)" (?getInterfaceName@@YAPEADH@Z)   iec61850-shared C:\Users\chenjing\Desktop\libiec61850-1.5\sol2\src\hal-shared.lib(ethernet_win32.obj)   1       
chenjing1294 commented 4 weeks ago

From this package copy the "Lib" and "Include" folders in this directory. On 64 bit systems you have to replace the lib files from the "Lib" folder by the files in "Lib\x64".