TarlogicSecurity / PLCTool

GNU General Public License v2.0
145 stars 55 forks source link

PLCTool doesn't compile #1

Closed adriangc24 closed 2 years ago

adriangc24 commented 2 years ago

Following the tutorial from your website to compile PLCTool i have encountered this error, after executing make inside PLCTool folder downloaded by github.

Makefile:2319: warning: overriding commands for target `moc_MainWindow.cpp'
Makefile:1778: warning: ignoring old commands for target `moc_MainWindow.cpp'
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -O2 -std=gnu++1z  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk -mmacosx-version-min=12 -Wall -Wextra -fPIC -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I. -Igurux/include -I/usr/local/lib/QtWidgets.framework/Headers -I/usr/local/lib/QtGui.framework/Headers -I/usr/local/lib/QtCore.framework/Headers -I. -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I. -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/AGL.framework/Headers -I/usr/local/share/qt/mkspecs/macx-clang -F/usr/local/lib -o Attack.o Attacks/Attack.cpp
In file included from Attacks/Attack.cpp:30:
In file included from ./Attacks/AttackFactory.h:33:
In file included from ./Attacks/Attack.h:33:
In file included from ./PRIME/PrimeAdapter.h:33:
In file included from ./Topology/Adapter.h:36:
In file included from ./Topology/SubNet.h:36:
In file included from ./Topology/Node.h:35:
./Topology/StringParams.h:44:5: error: unknown type name 'ulong'; did you mean 'long'?
    ulong asULong(void) const;
    ^~~~~
    long
1 error generated.
make: *** [Attack.o] Error 1
antoniovazquezblanco commented 2 years ago

From your error it seems that ulong is not a very portable type. Seems that replacing 'ulong' with 'unsigned long' may fix your issue here.

The code is provided "AS IS" and it has only been tested for the compilers stated in the latest version of the README.md file. If this solves your issue we would really appreciate a pull request with the fixes. Thank you

antoniovazquezblanco commented 2 years ago

Latest release should have fixed this. Please reopen if the problem persists.

Thanks