seandepagnier / celestial_navigation_pi

celestial navigation plugin for opencpn
17 stars 21 forks source link

os50 - wxWidgets problems - after revert android changes #34

Closed rgleason closed 5 years ago

rgleason commented 5 years ago
CelestialNavigationDialog.cpp(56): error C3861: 'GetpPrivateApplicationDataLocation': identifier not found
CelestialNavigationDialog.cpp(163): error C2143: syntax error : missing ';' before '<<' 
CelestialNavigationDialog.cpp(167): error C2065: 'filename' : undeclared identifier 
CelestialNavigationDialog.cpp(169): error C2065: 'filename' : undeclared identifier CelestialNavigationDialog.cpp(171): error C2065: 'filename' : undeclared identifier CelestialNavigationDialog.cpp(171): error C2228: left of '.mb_str' must have class/struct/union CelestialNavigationDialog.cpp(213): error C2143: syntax error : missing ';' before '==' 
Sight.cpp(135): error C2143: syntax error : missing ';' before '<<' 
Sight.cpp(138): error C2143: syntax error : missing ';' before '==' 
Sight.cpp(142): error C2143: syntax error : missing ';' before '>>' 
Sight.cpp(142): error C2059: syntax error : 'bad suffix on number' 
Sight.cpp(147): error C2143: syntax error : missing ';' before '>>' 
Sight.cpp(147): error C2059: syntax error : 'bad suffix on number' 
Sight.cpp(171): error C2143: syntax error : missing ';' before '<<' 
Sight.cpp(176): error C2065: 'mdlg' : undeclared identifier 
Sight.cpp(176): error C2228: left of '.ShowModal' must have class/struct/union 
Sight.cpp(178): error C2143: syntax error : missing ';' before '==' 
Sight.cpp(180): error C2059: syntax error : 'bad suffix on number' 
Sight.cpp(185): error C2065: 'mdlg' : undeclared identifier 
Sight.cpp(185): error C2228: left of '.ShowModal' must have class/struct/union 
Sight.cpp(187): error C2143: syntax error : missing ';' before '<<' 
Sight.cpp(188): error C2059: syntax error : 'bad suffix on number' 
Sight.cpp(190): error C2059: syntax error : 'bad suffix on number' 
rgleason commented 5 years ago

Ok now the errors are down to 2.

CelestialNavigationDialog.cpp(56): error C3861: 'GetpPrivateApplicationDataLocation': identifier not found

Sight.cpp(184): error C2374: 'mdlg' : redefinition; multiple initialization [C:\project\celestial_navigation_pi\build\celestial_navigation_pi.vcxproj]

CelestialNavigationDialog.cpp File

Sight.cpp File

rgleason commented 5 years ago

Now it is down to one error....

CelestialNavigationDialog.cpp(56): error C3861: 'GetpPrivateApplicationDataLocation': identifier not found

Perhaps someone can provide a suggestion?

CelestialNavigationDialog.cpp File

nohal commented 5 years ago

You have included a prehistoric version of ocpn_plugin.h file for some reason I do not understand, use the current one corresponding to O5.

You should also shift the required API version to 1.16, but first make it work like this, do not intend both at the same time.

rgleason commented 5 years ago

Thank you.

rgleason commented 5 years ago

Copied over ocpn_plugin.h

 c:\project\celestial_navigation_pi\src\ocpn_plugin.h(7): error C2059: syntax error : '<' [C:\project\celestial_navigation_pi\build\celestial_navigation_pi.vcxproj]
  c:\project\celestial_navigation_pi\src\ocpn_plugin.h(62): error C2332: 'class' : missing tag name [C:\project\celestial_navigation_pi\build\celestial_navigation_pi.vcxproj]

dozens of errors, all like the last one above, but different lines. 714 errors.

nohal commented 5 years ago

Rick...

Open that file you commited to the repository for some reason and have a look at it. Then have a look at https://github.com/OpenCPN/OpenCPN/blob/master/include/ocpn_plugin.h and as yourself: "Do they contain the same stuff"?

rgleason commented 5 years ago

Correct. It is not at all the same file. Its Html from my download of Opencpn/Opencpn. Will try this again. Thanks. Right-click Save link as does not work here. I guess copy to clipboard and paste into Notepad++ ocpn_plugin.h is the best way to do this.

rgleason commented 5 years ago

It completed the build. just 24 errors.

Sight.cpp(460): error C2065: 'GL_POLYGON' : undeclared identifier 
Sight.cpp(460): error C3861: 'glBegin': identifier not found 
Sight.cpp(462): error C3861: 'glVertex2i': identifier not found 
Sight.cpp(463): error C3861: 'glEnd': identifier not found 
Sight.cpp(488): error C3861: 'glColor4ub': identifier not found
Sight.cpp(489): error C2065: 'GL_COLOR_BUFFER_BIT' : undeclared identifier 
Sight.cpp(489): error C2065: 'GL_POLYGON_BIT' : undeclared identifier 
Sight.cpp(489): error C3861: 'glPushAttrib': identifier not found 
Sight.cpp(491): error C2065: 'GL_POLYGON_SMOOTH' : undeclared identifier 
Sight.cpp(491): error C3861: 'glEnable': identifier not found 
Sight.cpp(492): error C2065: 'GL_BLEND' : undeclared identifier
Sight.cpp(492): error C3861: 'glEnable': identifier not found 
Sight.cpp(493): error C2065: 'GL_SRC_ALPHA' : undeclared identifier 
Sight.cpp(493): error C2065: 'GL_ONE_MINUS_SRC_ALPHA' : undeclared identifier 
Sight.cpp(493): error C3861: 'glBlendFunc': identifier not found 
Sight.cpp(503): error C3861: 'glPopAttrib': identifier not found 
celestial_navigation_pi.cpp(229): error C3861: 'glColor3d': identifier not found 
celestial_navigation_pi.cpp(230): error C2065: 'GL_LINES' : undeclared identifier 
celestial_navigation_pi.cpp(230): error C3861: 'glBegin': identifier not found
celestial_navigation_pi.cpp(231): error C3861: 'glVertex2i': identifier not found 
celestial_navigation_pi.cpp(232): error C3861: 'glVertex2i': identifier not found 
celestial_navigation_pi.cpp(233): error C3861: 'glVertex2i': identifier not found 
celestial_navigation_pi.cpp(234): error C3861: 'glVertex2i': identifier not found 
celestial_navigation_pi.cpp(235): error C3861: 'glEnd': identifier not found 
24 Error(s)

https://github.com/rgleason/celestial_navigation_pi/blob/ov50/src/Sight.cpp

https://github.com/rgleason/celestial_navigation_pi/blob/ov50/src/celestial_navigation_pi.cpp

nohal commented 5 years ago

The upstream version you started with builds as far as I remember, so you have broken the OpenGL support only here. Review your changes and revert what needed.

rgleason commented 5 years ago

Yes. What I was thinking too. Thanks. (I think Sean was messing around with Android and it was partially done with commented out, and other stuff. I think he was using something else for android gl.)

I guess I'll look back. Maybe there is a file missing.

rgleason commented 5 years ago

These were removed in this Revert Android Changes https://github.com/rgleason/celestial_navigation_pi/commit/832341e04fc9a27785b63161f5477916a0a91816 INCLUDE("cmake/PluginXML.cmake") INCLUDE("cmake/PluginGL.cmake")

rgleason commented 5 years ago
CMake Error at CMakeLists.txt:51 (INCLUDE):
  INCLUDE could not find load file:
    cmake/PluginXML.cmake
CMake Error at CMakeLists.txt:52 (INCLUDE):
  INCLUDE could not find load file:
    cmake/PluginGL.cmake

Those files are missing.

rgleason commented 5 years ago

Well, I am giving up now. Those files were probably meant for the Android. There are GL files in include directory.

rgleason commented 5 years ago

Actually, the fact is Sean's version is broken (for Windows and Linux) too! - but not Android Otherwise this would have been very easy! So I am quitting on this now.

nohal commented 5 years ago

I see an installer for Windows on the release page, it did not fall out of the sky, so you must have built it somehow, you need to get back to that point and see what has changed to break it since...

rgleason commented 5 years ago

None of the appveyor builds worked ever on this plugin. Under Releases the most recent version is March 30 2018 Celestial_navigation_pi-2.3-win32 v2.3 Commit acd6520

So that's the last working version that we know of. Merge branch 'master' of ssh://github.com/seandepagnier/celestial_navigation_pi March 29 2018

Thats just before Sean made a commit for "android build" in June

Ok, I will use that one. I'll make a new branch "ov50-n" and revert using the command line to that commit exactly. Then go from there.

rgleason commented 5 years ago

git checkout -b ov50-n git reset --hard acd6520fdd6213560844b1b9ec882e67820c33a8 git push --force origin ov50-n

I think it worked. Yes it did.

rgleason commented 5 years ago

So easy, if you go about it the easy way! Thanks Pavel. https://ci.appveyor.com/project/rgleason/celestial-navigation-pi/builds/22952158/artifacts

Travis built too but Skipping a deployment releases provider because repo's name does not match. deploy.on.repo: nohal/celestial_navigation_pi. Skipping a deployment with the releases provider because this is not a tagged commit

rgleason commented 5 years ago

ov50 - Celestial_navigation_pi-2.3-ov50-win32

Thank you Pavel. Closing

Note: This compile does not have "Android" stuff!