Cruisers Forum
 


Join CruisersForum Today

Reply
 
Thread Tools Rate Thread Display Modes
Old 16-05-2010, 02:10   #46
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
Hi Bart and all,
Quote:
Originally Posted by champ8242 View Post
Hi all,

Just as a note. OpenCPN doesn't work (jet) in VS2010. It compiles OK but a lot of unhandled assertions in wxwidgets
I am writing a tutorial on the German OpenCPN website and encountered the same problems.
Maybe this sentence from the wxWiki is helpful?
Quote:
Open all project files (.vcxproj) in a text editor and use Find & Replace to replace all occurances of $(Input) with %(Identity).
See: Microsoft Visual C++ Guide - WxWiki
Quote:
I've downloaded VS2008 express and no problems
I cannot confirm this.
But there is only one error:
Quote:
"..\src\sercomm.cpp": No such file or directory
I have checked the Repository at SF.net but there is no such file.
So anyone could give me a tip/ hint what to do?

And one more suggestion:
Things would become a lot easier, if there were pre-compiled versions of the wxWidgets libraries for downloading (at least for VS C++ 2008 and in the future VS C++ 2010).

Gunther
__________________

__________________
Netsurfer is offline   Reply With Quote
Old 16-05-2010, 02:20   #47
Registered User

Join Date: Oct 2009
Location: Lelystad, The Netherlands
Boat: vd Stadt 44, Ben the Boat
Posts: 195
Hi Gunther,

Thanx for the quote on the WIKI. I will try today to change the projectfile and see if there are differences.
sercomm.cpp is not a separate file anymore. As far as I know it's integrated.

Bart
__________________

__________________
champ8242 is offline   Reply With Quote
Old 16-05-2010, 02:27   #48
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
Hi Bart!

Quote:
Originally Posted by champ8242 View Post
sercomm.cpp is not a separate file anymore. As far as I know it's integrated.
OK. That means I just can remove it from the Resource Files in VS C++ 2008?
Sorry for asking such questions but as you may know I am not quite familiar with the whole process of compiling a Windows version (yet).

Gunther
__________________
Netsurfer is offline   Reply With Quote
Old 16-05-2010, 02:30   #49
Registered User

Join Date: Oct 2009
Location: Lelystad, The Netherlands
Boat: vd Stadt 44, Ben the Boat
Posts: 195
Quote:
OK. That means I just can remove it from the Resource Files in VS C++ 2008?
That's correct Gunther
__________________
champ8242 is offline   Reply With Quote
Old 16-05-2010, 02:57   #50
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
It is me again ...!

After removing sercomm.cpp the error has gone.
But unfortunately there are still 2 errors left:
Quote:
nmea0183.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ""public: virtual __thiscall GSV::~GSV(void)" (??1GSV@@UAE@XZ)" in Funktion "__unwindfunclet$??0NMEA0183@@QAE@XZ$0".
nmea0183.obj : error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ""public: __thiscall GSV::GSV(void)" (??0GSV@@QAE@XZ)" in Funktion ""public: __thiscall NMEA0183::NMEA0183(void)" (??0NMEA0183@@QAE@XZ)".
Debug\opencpn.exe : fatal error LNK1120: 2 nicht aufgelöste externe Verweise.
Translation: link to an unresolved external symbol
I have no idea what the problem is.
Seems still to be extremely tricky to compile ones own Windows version ...

Gunther

BTW: I have already added the routemanagerdialog.cpp as described in the other post.
__________________
Netsurfer is offline   Reply With Quote
Old 16-05-2010, 03:32   #51
Registered User

Join Date: Oct 2009
Location: Lelystad, The Netherlands
Boat: vd Stadt 44, Ben the Boat
Posts: 195
Did you add gsv.cpp as Dave stated in his Beta 514 message?
__________________
champ8242 is offline   Reply With Quote
Old 16-05-2010, 03:47   #52
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
Quote:
Originally Posted by champ8242 View Post
Did you add gsv.cpp as Dave stated in his Beta 514 message?
Of course not!
Thought downloading the files from the CVS would do the trick.
So if anyone would update the opencpn.vcproj file at SF.net there would be no problem.

Thanks to your help Bart I finally made it :
Quote:
========== Erstellen: 1 erfolgreich, Fehler bei 0, 0 aktuell, 0 übersprungen ==========
But I am still interested in compiling it with the new Visual C++ 2010 Express. Would be great if you will post any new insight into this topic.

Addition:
Although I made it to compile a opencpn.exe file from the CVS source, there seems to be something wrong.
The downloaded version of the opencpn.exe file (build 514) is 5.116 KB of size whereas my version is 7.322 KB.
And my version crashes when I try to start the routemanager (no problem with the downloaded version).
Is there something else I have to do or to comply?

Gunther
__________________
Netsurfer is offline   Reply With Quote
Old 17-05-2010, 06:00   #53
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
Sorry for bothering once again, but ...
Quote:
Originally Posted by Netsurfer View Post
Although I made it to compile a opencpn.exe file from the CVS source, there seems to be something wrong.
The downloaded version of the opencpn.exe file (build 514) is 5.116 KB of size whereas my version is 7.322 KB.
Well I think the difference in file size results from (different) configuration settings in VC++2008.

So it would be very nice, if someone who sucessfully compiled a version with the small file size, could post the/ his settings for VC++2008 - thanks!

Having a opencpn.vcproj file is already a big step forward , but does not really help, if the file is not up to date . I vote for keeping this file always updated. Perhaps there could be different versions (for each build) stored at some other location (opencpn.org? or here in the forum?).

Thanks for your support!

Gunther
__________________
Netsurfer is offline   Reply With Quote
Old 22-05-2010, 21:31   #54
Registered User
 
Psyches's Avatar

Join Date: Apr 2008
Location: SF Bay Area
Boat: Tartan 30 - Bluegrass
Posts: 187
Send a message via Yahoo to Psyches Send a message via Skype™ to Psyches
Vs proj

Quote:
Originally Posted by Netsurfer View Post
Sorry for bothering once again, but ...

Well I think the difference in file size results from (different) configuration settings in VC++2008.

So it would be very nice, if someone who sucessfully compiled a version with the small file size, could post the/ his settings for VC++2008 - thanks!

Having a opencpn.vcproj file is already a big step forward , but does not really help, if the file is not up to date . I vote for keeping this file always updated. Perhaps there could be different versions (for each build) stored at some other location (opencpn.org? or here in the forum?).

Thanks for your support!

Gunther
Gunther et al,

Sorry the file hasn't been updated recently...I have a new job and it's been taking more than all my time lately. I have not abandoned you all, but it may be awhile before I even get the time to pull & build the great new stuff Dave & team have done. Then, I'll update the vcproj (well, for vce8, all I have).

If anyone else has time, feel free to send the work in email & I can at least help check in.

Mark
__________________
Psyches is offline   Reply With Quote
Old 19-07-2010, 15:12   #55
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
changes for switching from CVS to GIT

Hi,

as the new beta developement has moved to git, maybe someone would be so nice and describe in a few words how to build ones own Windows version?

Or explain just the differences between the old way via CVS?

I have already a windows version of git and the git extensions installed, so I have a local clone of the git repository.

I guess it is "just" a new project file for VC++2008 missing (and some other minor things ).

Any help would be very much appreciated!

Thanks,

Gunther
__________________
Deutschsprachige Community- und Support-Website unter OpenCPN.de
Netsurfer is offline   Reply With Quote
Old 19-07-2010, 21:41   #56
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 4,879
VS build

Gunther...

Very quick and rough outline...

1. Run CMake GUI on the CMakeLists.txt in the opencpn project directory. This has two steps: a. configure and b. generate

2. Open VS2008. Find the opencpn solution. Select Release Mode

3. Build the subprojects in the following order:
a. opencpn
b. grib_pi
c. demo_pi
d. install

4. If all goes well you will find opencpn.exe in {Program Files}\OpenCPN

5. You may also build in Debug mode. In this case, the PlugIns will not be found or loaded unless manually copied into the right place. The PlugIn dlls need to be manually copied to
Code:
{project build directory}\plugins.
You will also need to copy the wxWidgets dlls to

Code:
{project build directory}\debug

Please feel free to amplify these instructions for the Wiki based on your actual experience.

Good Luck
Dave

ps You will need a new git clone as of 18 july, 0300GMT. Corrected some Windows build issues.
__________________
bdbcat is online now   Reply With Quote
Old 20-07-2010, 03:31   #57
Registered User
 
Netsurfer's Avatar

Join Date: Jan 2010
Location: Cologne, Germany
Boat: Beneteau Oceanis 331
Posts: 557
Dave,

thanks for the explanation.
Quote:
Originally Posted by bdbcat View Post
Very quick and rough outline...

1. Run CMake GUI on the CMakeLists.txt in the opencpn project directory. This has two steps: a. configure and b. generate
Ok so far, but ...
... it seems that there are many other applications needed to successfully proceed with this step.

First is GetText - downloaded gettext-tools-0.17 (as someone posted a link in another thread).

Next is GTK2 or GTK+. I downloaded gtk+-bundle_2.20.0-20100406_win32 from GTK+ - Download for Windows
When unpacking the archive it seems that the directory structure is different from the one which is needed for the build process.

Quote:
2. Open VS2008. Find the opencpn solution.
Just to make things clear to a noob like me: We are talking about the file 'OpenCPN.sln', right?

Quote:
Select Release Mode

3. Build the subprojects in the following order:
a. opencpn
b. grib_pi
c. demo_pi
d. install

4. If all goes well you will find opencpn.exe in {Program Files}\OpenCPN

Please feel free to amplify these instructions for the Wiki based on your actual experience.
So I could not test the rest yet as I got stuck at point 2.
Can someone help me out, please?

Quote:
ps You will need a new git clone as of 18 july, 0300GMT. Corrected some Windows build issues.
Thanks for the hint - done.

Many thanks in advance,

Gunther
__________________
Deutschsprachige Community- und Support-Website unter OpenCPN.de
Netsurfer is offline   Reply With Quote
Old 26-07-2010, 11:51   #58
Registered User

Join Date: Feb 2010
Location: On the go. Not in Prague.
Posts: 4,016
Linker errors

Hi guys,
I'm really running out of ideas what could be wrong while trying to compile and link OCPN. Cmake passes ok and compilation goes fine until the linking, which dies with following errors:
Code:
Microsoft (R) Windows (R) Resource Compiler Version 6.1.6723.1
Copyright (C) Microsoft Corporation.  All rights reserved.
Linking...
   Creating library C:\opencpn\opencpn\build\Release\opencpn.lib and object C:\opencpn\opencpn\build\Release\opencpn.exp
navutil.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
routeman.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
tcmgr.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
ais.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
chart1.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ) referenced in function "private: void __thiscall MyFrame::PostProcessNNEA(bool,class wxString &)" (?PostProcessNNEA@MyFrame@@AAEX_NAAVwxString@@@Z)
chartdb.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
chartdbs.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
chcanv.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: long __thiscall wxDateTime::GetTicks(void)const " (__imp_?GetTicks@wxDateTime@@QBEJXZ)
chart1.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall wxLog::DoLog(unsigned long,char const *,long)" (?DoLog@wxLog@@MAEXKPBDJ@Z)
chart1.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall wxLogStderr::DoLogString(char const *,long)" (?DoLogString@wxLogStderr@@MAEXPBDJ@Z)
ais.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class wxDateTime & __thiscall wxDateTime::Set(long)" (__imp_?Set@wxDateTime@@QAEAAV1@J@Z) referenced in function "public: class wxString __thiscall AIS_Target_Data::BuildQueryResult(void)" (?BuildQueryResult@AIS_Target_Data@@QAE?AVwxString@@XZ)
C:\opencpn\opencpn\build\Release\opencpn.exe : fatal error LNK1120: 4 unresolved externals
Build log was saved at "file://c:\opencpn\opencpn\build\opencpn.dir\Release\BuildLog.htm"
opencpn - 12 error(s), 0 warning(s)
========== Build: 3 succeeded, 1 failed, 1 up-to-date, 0 skipped ==========
I have even tried to download wxPack to make sure my own compilation of WX is not screwed up and got the same result.
Thanks for any suggestions.

Pavel
__________________
nohal is offline   Reply With Quote
Old 26-07-2010, 14:25   #59
Registered User

Join Date: Apr 2009
Location: Marina Del Rey
Boat: Hylas 44
Posts: 387
Pavel

Try removing "_USE_32BIT_TIME_T" from the preprocessor definitions.

Chuck
__________________
ChuckSK is offline   Reply With Quote
Old 26-07-2010, 15:32   #60
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 4,879
Pavel...

Hmmm. I find that with VS2010, I need to make sure that _USE_32BIT_TIME_T is defined. Otherwise, I get similar errors. I have made a small change to cmake script to ensure that this is set correctly. Not in git yet, though.

Code:
IF(WIN32 AND NOT UNIX)
  ADD_DEFINITIONS(-D_USE_32BIT_TIME_T)
ENDIF(WIN32 AND NOT UNIX)
Try this, and let us know. What version of VS are you using?

Dave
__________________

__________________
bdbcat is online now   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenCPN General bdbcat OpenCPN 987 11-11-2017 07:00
OpenCPN on a Netbook wbickle OpenCPN 51 27-09-2010 16:10
OpenCPN bdbcat OpenCPN 1343 19-09-2009 16:59



Copyright 2002- Social Knowledge, LLC All Rights Reserved.

All times are GMT -7. The time now is 09:59.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2017, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.