Open sbfreddie opened 8 years ago
Windows did not show up any problem and I failed to compile with Linux (Ubuntu).
GitHub now updated with a small change to NavFunc.cpp. Should compile/run ok.
Mike
I can confirm that version 1.0 does not compile on linuy while master does...
Would you mind to create a new release to make a released linux version possible? Thanks in advance
While trying to build this plugin the build stops with this error:
`Building Dead Reckoning Plugin..... Checking for Pre-Existing Dead Reckoning Plugin Folder..... Checking to see if you have the latest updates... From git://github.com/Rasbats/DR_pi d110497..4b3dc7e master -> origin/master
-- Looking for XOpenDisplay in /usr/lib/arm-linux-gnueabihf/libX11.so;/usr/lib/arm-linux-gnueabihf/libXext.so -- Looking for XOpenDisplay in /usr/lib/arm-linux-gnueabihf/libX11.so;/usr/lib/arm-linux-gnueabihf/libXext.so - found -- Looking for gethostbyname -- Looking for gethostbyname - found -- Looking for connect -- Looking for connect - found -- Looking for remove -- Looking for remove - found -- Looking for shmat -- Looking for shmat - found -- Looking for IceConnectionNumber in ICE -- Looking for IceConnectionNumber in ICE - found -- Found X11: /usr/lib/arm-linux-gnueabihf/libX11.so -- Found OpenGL: /usr/lib/arm-linux-gnueabihf/libGL.so
-- Found OpenGL... -- Lib: /usr/lib/arm-linux-gnueabihf/libGLU.so/usr/lib/arm-linux-gnueabihf/libGL.so/usr/lib/arm-linux-gnueabihf/libSM.so/usr/lib/arm-linux-gnueabihf/libICE.so/usr/lib/arm-linux-gnueabihf/libX11.so/usr/lib/arm-linux-gnueabihf/libXext.so -- Include: /usr/include -- Found Gettext: /usr/bin/msgmerge (found version "0.19.3") -- Found BZip2: /usr/lib/arm-linux-gnueabihf/libbz2.so (found version "1.0.6") -- Looking for BZ2_bzCompressInit in /usr/lib/arm-linux-gnueabihf/libbz2.so -- Looking for BZ2_bzCompressInit in /usr/lib/arm-linux-gnueabihf/libbz2.so - found -- Found ZLIB: /usr/lib/arm-linux-gnueabihf/libz.so (found version "1.2.8") -- Configuring done -- Generating done -- Build files have been written to: /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/build Configuring with cmake of Dead Reckoning Plugin was Successful...
Scanning dependencies of target DR-i18n [ 3%] DR_pi-i18n: Done. [ 74%] Built target DR-i18n Scanning dependencies of target DR_pi [ 77%] Building CXX object CMakeFiles/DR_pi.dir/src/DR_pi.cpp.o [ 80%] Building CXX object CMakeFiles/DR_pi.dir/src/DRgui_impl.cpp.o /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp: In member function ‘bool Dlg::OpenXML()’: /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:112:33: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if(response = wxID_CANCEL){ ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:94:6: warning: unused variable ‘my_count’ [-Wunused-variable] int my_count = 0; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp: In member function ‘void Dlg::Calculate(wxCommandEvent&, bool, int)’: /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:294:7: warning: unused variable ‘routepoints’ [-Wunused-variable] int routepoints = n+1; //3 ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:299:26: warning: variable ‘myLast’ set but not used [-Wunused-but-set-variable] double remaining_dist, myLast, route_dist; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:306:8: warning: unused variable ‘skip’ [-Wunused-variable] bool skip = false; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:307:8: warning: unused variable ‘inloop’ [-Wunused-variable] bool inloop = false; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:308:8: warning: unused variable ‘setF’ [-Wunused-variable] bool setF = false; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/DRgui_impl.cpp:187:6: warning: variable ‘num_hours’ set but not used [-Wunused-but-set-variable] int num_hours; ^ [ 83%] Building CXX object CMakeFiles/DR_pi.dir/src/NavFunc.cpp.o /home/pi/GitOpenCPN/Seans_Plugins/DRpi/src/NavFunc.cpp: In function ‘double fromDMStodouble(char)’: /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:125:19: error: ‘abs’ is not a member of ‘std’ s = (double) (std::abs(d)) + ((double) m + s / 60.0) / 60.0; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:125:19: note: suggested alternative: In file included from /usr/include/wx-3.0/wx/string.h:42:0, from /usr/include/wx-3.0/wx/memory.h:15, from /usr/include/wx-3.0/wx/object.h:19, from /usr/include/wx-3.0/wx/event.h:16, from /usr/include/wx-3.0/wx/window.h:18, from /usr/include/wx-3.0/wx/nonownedwnd.h:14, from /usr/include/wx-3.0/wx/toplevel.h:20, from /usr/include/wx-3.0/wx/dialog.h:14, from /usr/include/wx-3.0/wx/msgdlg.h:18, from /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.h:36, from /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:27: /usr/include/stdlib.h:775:12: note: ‘abs’ extern int abs (int x) THROW attribute ((const)) wur; ^ /home/pi/GitOpenCPN/Seans_Plugins/DRpi/src/NavFunc.cpp: In function ‘bool destLoxodrome(double, double, double, double, double, double_)’: /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:282:7: error: ‘abs’ is not a member of ‘std’ if (std::abs(brng - 90)< 1e-10) { ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:282:7: note: suggested alternative: In file included from /usr/include/wx-3.0/wx/string.h:42:0, from /usr/include/wx-3.0/wx/memory.h:15, from /usr/include/wx-3.0/wx/object.h:19, from /usr/include/wx-3.0/wx/event.h:16, from /usr/include/wx-3.0/wx/window.h:18, from /usr/include/wx-3.0/wx/nonownedwnd.h:14, from /usr/include/wx-3.0/wx/toplevel.h:20, from /usr/include/wx-3.0/wx/dialog.h:14, from /usr/include/wx-3.0/wx/msgdlg.h:18, from /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.h:36, from /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:27: /usr/include/stdlib.h:775:12: note: ‘abs’ extern int abs (int **x) THROW attribute ((const)) wur; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:286:7: error: ‘abs’ is not a member of ‘std’ if (std::abs(brng - 270) < 1e-10) {
^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:286:7: note: suggested alternative: In file included from /usr/include/wx-3.0/wx/string.h:42:0, from /usr/include/wx-3.0/wx/memory.h:15, from /usr/include/wx-3.0/wx/object.h:19, from /usr/include/wx-3.0/wx/event.h:16, from /usr/include/wx-3.0/wx/window.h:18, from /usr/include/wx-3.0/wx/nonownedwnd.h:14, from /usr/include/wx-3.0/wx/toplevel.h:20, from /usr/include/wx-3.0/wx/dialog.h:14, from /usr/include/wx-3.0/wx/msgdlg.h:18, from /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.h:36, from /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:27: /usr/include/stdlib.h:775:12: note: ‘abs’ extern int abs (int x) THROW attribute ((const)) __wur; ^ /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp: In function ‘void toSMECC(double, double, double, double, double, double_)’: /home/pi/GitOpenCPN/Seans_Plugins/DR_pi/src/NavFunc.cpp:379:15: warning: unused variable ‘y4’ [-Wunused-variable] const double y4 = y3 - y30; ^ CMakeFiles/DR_pi.dir/build.make:146: recipe for target 'CMakeFiles/DRpi.dir/src/NavFunc.cpp.o' failed make[2]: ** [CMakeFiles/DR_pi.dir/src/NavFunc.cpp.o] Error 1 CMakeFiles/Makefile2:153: recipe for target 'CMakeFiles/DR_pi.dir/all' failed make[1]: * [CMakeFiles/DR_pi.dir/all] Error 2 Makefile:127: recipe for target 'all' failed make: *\ [all] Error 2 Building Dead Reckoning Plugin Failed
Any advice on how to fix this problem?
Thanks, Freddie