Cruisers Forum
 


Join CruisersForum Today

Reply
 
Thread Tools Rate Thread Display Modes
Old 08-11-2014, 06:40   #211
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Trying to get setup using a REMOTE CaesarSchinas/OpenCPN.git and his branch 'mac-menus' so I can compile it.

This is what I did so far:
git remote add caesar git://github.com/CaesarSchinas/OpenCPN.git
git fetch --all
git branch -a
git checkout caesar/mac-menus
cd build
cmake ..
cmake --build .
cmake --build . --config release

The HEAD is at (no branch) bc8253f "Unique ids for Menu items, separate from toolbar items."
(how do I end up with this style? --how to strip the style? nothing works in edit mode.)
Caesar also says:
Quote:
Sorry, I forgot to say; you need to fetch from the remote before you can checkout:
$ git fetch caesar
Also, you may want to check it out into a local branch:
$ git checkout -b menus caesar/mac-menus

Also, it doesn't matter for this, but normally your origin remote would be github.com/rgleason/OpenCPN.git and you would have a remote called upstream for github.com/OpenCPN/OpenCPN.git
I suppose I should be setting it up this way, but I am not contributing code....but I should get in the habit and mindset

This is good info re remotes
Development Debugging Environment - Setup Help
__________________

__________________
rgleason is online now   Reply With Quote
Old 16-12-2014, 08:26   #212
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Trying to setup GIT properly, using
Quote:
1. Forked https://github.com/rgleason/OpenCPN
[A personal Repository Setup and Created sometime ago]
2. Cloned to Desktop using Github Desktop software.

Deleted my local PC cloned directory "opencpn-git"
which had been direct cloned from https://github.com/OpenCPN/OpenCPN
Sometime ago I had installed Github and Git Bash and initialized and set up [Windows7pro]
Went to https://github.com/rgleason/OpenCPN [Created sometime ago]
Selected "Clone in Desktop" at the lower right which launches Github.
Created Local "Opencpn" repository and then a big "clone" occured.
Then went online to
https://github.com/rgleason/OpenCPN and tried "Synching" in upper right
Then from the local pc Command window "Windows PowerShell"

Quote:
C:\Users\Rick\Documents\GitHub\OpenCPN [master]> git fetch
C:\Users\Rick\Documents\GitHub\OpenCPN [master]> git pull
Already up-to-date.
C:\Users\Rick\Documents\GitHub\OpenCPN [master]> git branch -v
beta30_stable e48b97d 3.0.2
* master 8aafcca Fix an assert and subsequent crash on Mac OSX with wxWidgets 3.1
opencpn-3.2.0 daf4214 Merge pull request #74 from Ptizef/master
stable e48b97d 3.0.2
C:\Users\Rick\Documents\GitHub\OpenCPN [master]>
mkdir build
cd build
cmake ..
cmake --build . 36 warnings
cmake --build . 0 warnings
cmake --build . --config release 36 warnings
cmake --build . --config release 0 warnings
cpack
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]> cpack
CPack: Create package using NSIS
CPack: Install projects
CPack: - Install project: opencpn
CPack: Create package
CPack: - package: C:/Users/Rick/Documents/GitHub/OpenCPN/build/opencpn_3.3.1117_
setup.exe generated.
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]>

Everything worked, however this is compiled for Opencpn_3.3.1117_
How do I get current??
I am on [master +17 ~0 -0 !] <--- don't know what +17 means, or the rest.
Do I update https://github.com/rgleason/OpenCPN [Created sometime ago]
Or do I issue some command from my local pc command window?

More information:
Quote:
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]> git remote -v
origin https://github.com/rgleason/OpenCPN.git (fetch)
origin https://github.com/rgleason/OpenCPN.git (push)
upstream https://github.com/OpenCPN/OpenCPN.git (fetch)
upstream https://github.com/OpenCPN/OpenCPN.git (push)
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]>
__________________

__________________
rgleason is online now   Reply With Quote
Old 16-12-2014, 08:34   #213
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Ah I think I found it
https://help.github.com/articles/syncing-a-fork/

Quote:
git fetch upstream
downloading lots of files to local repository.


remote: Counting objects: 8316, done.
remote: Compressing objects: 100% (3094/3094), done.
remote: Total 8316 (delta 6381), reused 6939 (delta 5213)
Receiving objects: 100% (8316/8316), 14.09 MiB | 1.15 MiB/s, done.
Resolving deltas: 100% (6381/6381), done.
From https://github.com/OpenCPN/OpenCPN
* [new branch] beta30_stable -> upstream/beta30_stable
* [new branch] beta31_stable -> upstream/beta31_stable
* [new branch] master -> upstream/master
* [new branch] region -> upstream/region
* [new branch] release32_stable -> upstream/release32_stable
* [new branch] service_release321 -> upstream/service_release321
* [new branch] stable -> upstream/stable
* [new branch] wxqt -> upstream/wxqt
* [new tag] opencpn-3.3.2316 -> opencpn-3.3.2316
* [new tag] opencpn-3.3.2330 -> opencpn-3.3.2330
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]>
__________________
rgleason is online now   Reply With Quote
Old 16-12-2014, 08:42   #214
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Here are the branches now. Still on OLD -->* master 8aafcca Fix an assert
Quote:
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]> git branch -
all
beta30_stable
* master
opencpn-3.2.0
stable
remotes/origin/HEAD -> origin/master
remotes/origin/beta30_stable
remotes/origin/beta31_stable
remotes/origin/master
remotes/origin/opencpn-3.2.0
remotes/origin/release32_stable
remotes/origin/service_release321
remotes/origin/stable
remotes/upstream/beta30_stable
remotes/upstream/beta31_stable
remotes/upstream/master
remotes/upstream/region
remotes/upstream/release32_stable
remotes/upstream/service_release321
remotes/upstream/stable
remotes/upstream/wxqt

C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]> git branch -v

beta30_stable e48b97d 3.0.2
* master 8aafcca Fix an assert and subsequent crash on Mac OSX with wxWid
gets 3.1
opencpn-3.2.0 daf4214 Merge pull request #74 from Ptizef/master
stable e48b97d 3.0.2
C:\Users\Rick\Documents\GitHub\OpenCPN\build [master +17 ~0 -0 !]>
__________________
rgleason is online now   Reply With Quote
Old 20-12-2014, 08:38   #215
Registered User

Join Date: Feb 2013
Location: Gothenburg, Sweden
Boat: Allegro 33
Posts: 194
Re: Development Debugging Environment - Setup Help

Having trouble linking wxWidgets-2.8.12.
OS : win7 64 bit.

The make command as given in the manual :
nmake -f makefile.vc BUILD=release MONOLITHIC=0 SHARED=1 UNICODE=1 USE_GDIPLUS=1 USE_OPENGL=1

gives me linker error. See attachment.

If I set SHARED=0 then it seems to compile and link ok.
Has anyone seen this and is it ok to have SHARED=0 ?

/Hans
Attached Thumbnails
Click image for larger version

Name:	Linker_error.jpg
Views:	62
Size:	98.1 KB
ID:	93999  
__________________
hasse_A is offline   Reply With Quote
Old 20-12-2014, 08:51   #216
Registered User

Join Date: Feb 2010
Location: On the go. Not in Prague.
Posts: 3,927
Re: Development Debugging Environment - Setup Help

Hans...
It is not OK to build static libraries instead of the DLLs. Your problem could be similar to Error &#39;LINK : fatal error LNK1123: failure during conversion to COFF: file invalid or corrupt&#39; after installing Visual Studio 2012 Release Preview - Stack Overflow

Pavel
__________________
nohal is offline   Reply With Quote
Old 20-12-2014, 14:38   #217
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Hans, You're probably way over my head on this, because nmake never worked for me, I think that is a linux command or something, but I use
cmake ..
cmake --build .
cmake --build . --config release
cpack [When NSIS is setup]
__________________
rgleason is online now   Reply With Quote
Old 20-12-2014, 15:37   #218
Registered User

Join Date: Feb 2013
Location: Gothenburg, Sweden
Boat: Allegro 33
Posts: 194
Re: Development Debugging Environment - Setup Help

Thanks Pavel for leading me in the right direction.
Installing VS SP1 did the thing.
/Hans
__________________
hasse_A is offline   Reply With Quote
Old 30-12-2014, 11:23   #219
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

I forked Opencpn to my github repository and am trying to find the best way to make it current with Opencpn/master

From within my Github Opencpn repository, I have been
  1. Making a "Pull request" and configuring with the "Edit" button and dropdown selections to set one side of the compare
  2. Then select "Compare Branches" to set the second side of the comparison
  3. To get this: Comparing "rgleason:master ..... OpenCPN:master"
  4. You will then see below a number of commits by date in the comparison and a line that summarizes "Showing with 112,926 additions and 85,270 deletions".Then type something like "Merge commits from Dec 28 to Dec 30" in the top line.
  5. Then hit "Create Pull request" green button at lower right
  6. You will see something like : "rgleason wants to merge 7 commits into rgleason:master from OpenCPN:master".
  7. Look over the list of commits and if ok.
  8. Select green button "Merge pull request"
  9. Then "Confirm Merge".
Is there a better way to accomplish this?


Then from my local repository on my computer when I issue a git fetch --all or git pull (if not coding)
my local repository is updated and I can compile the more recent code changes.
__________________
rgleason is online now   Reply With Quote
Old 30-12-2014, 11:26   #220
Registered User

Join Date: Feb 2010
Location: On the go. Not in Prague.
Posts: 3,927
Re: Development Debugging Environment - Setup Help

Code:
git push rgleason master
__________________
nohal is offline   Reply With Quote
Old 30-12-2014, 12:21   #221
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Oh I like that! Thank you Pavel.
__________________
rgleason is online now   Reply With Quote
Old 30-12-2014, 12:42   #222
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

So Pavel, is this the workflow?

1. Direct from Opencpn Master to Local PC
Opencpn/master ----> My local machine repository c:/github/opencpn-git
. Use git fetch --all to bring my local repository current with c:/github/opencpn master

2. Push up to Personnal repository on Github
Local machine repository c:/github/opencpn-git ----->github.com/rgleason
. Use "git push rgleason master" from the local directory.
. Updates personal master branch to github.com/rgleason/OpenCPN

3. If coding, certain "Commits" submited or Pushed to github.com/OpenCPN
github.com/rgleason/Opencpn ----> github.com/Opencpn

Is this the workflow as most people use git?

https://help.github.com/articles/pushing-to-a-remote/
__________________
rgleason is online now   Reply With Quote
Old 30-12-2014, 13:03   #223
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Code:
C:\Users\Rick\Documents\GitHub\OpenCPN>git remote -v
origin  https://github.com/rgleason/OpenCPN.git (fetch)
origin  https://github.com/rgleason/OpenCPN.git (push)
upstream        https://github.com/OpenCPN/OpenCPN.git (fetch)
upstream        https://github.com/OpenCPN/OpenCPN.git (push)

C:\Users\Rick\Documents\GitHub\OpenCPN>git branch -v
  beta30_stable e48b97d 3.0.2
* master        13db1d3 [ahead 4] Merge branch 'master' of https://github.com/rg
leason/OpenCPN
  opencpn-3.2.0 daf4214 Merge pull request #74 from Ptizef/master
  stable        e48b97d 3.0.2
I seem to be "ahead 4" and would like to make my local PC identical to upstream.
__________________
rgleason is online now   Reply With Quote
Old 30-12-2014, 14:52   #224
Registered User

Join Date: Feb 2010
Location: On the go. Not in Prague.
Posts: 3,927
Re: Development Debugging Environment - Setup Help

rick...
In you particular case
Set your local master branch to track the upstream master (just once)
Code:
git branch -u upstream/master master
Every time you need to update, do
Code:
git pull
To update your copy on github
Code:
git push origin master
All the answers to your questions are in Git - Book - The first three chapters are really essential to understand what's going on, just copy pasting the commands without understanding why is not going to survive the first change in anything involved...

Pavel
__________________
nohal is offline   Reply With Quote
Old 30-12-2014, 16:24   #225
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 7,821
Re: Development Debugging Environment - Setup Help

Thank you Pavel,

Using Run "Cmd" did not recognize
Code:
git branch -u upstream/master master
However going to Start > All Programs > Git Shell which brought up
"Windows PowerShell" resulted in the following response after the above command

Code:
Identity added:  [ssh identity location]
C:\Users\..\GitHub [master +4 ~0 -0 !]> cd C:\Users\Rick\Documents\GitHub\OpenCPN
C:\Users\..\GitHub\OpenCPN [master +18 ~0 -0 !]> git branch -u upstream/master master
Branch master set up to track remote branch master from upstream.
Code:
 C:\Users\..\GitHub\OpenCPN [master +18 ~0 -0 !]>git pull
and there was a considerable download.

Code:
C:\Users\Rick\Documents\GitHub\OpenCPN [master +18 ~0 -0 !]> git branch -v
  beta30_stable e48b97d 3.0.2
* master        1dc1dbb [ahead 12] Merge branch 'master' of https://github.com/OpenCPN/OpenCPN
  opencpn-3.2.0 daf4214 Merge pull request #74 from Ptizef/master
  stable        e48b97d 3.0.2
It appears my local master branch was merged and is now "ahead 12" I may have to simply rebuild this to make it clean.

Quote:
C:\Users\Rick\Documents\GitHub\OpenCPN [master +18 ~0 -0 !]> git push origin master
Counting objects: 815, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (498/498), done.
Writing objects: 100% (507/507), 10.05 MiB | 38.00 KiB/s, done.
Total 507 (delta 9), reused 502 (delta 9)
To https://github.com/rgleason/OpenCPN.git
caf20d1..1dc1dbb master -> master
It appears the latest commit on github.com/opencpn is a30206d4c6
So I am almost there, but need to do this all again, starting with a clean git clone I think.
__________________

__________________
rgleason is online now   Reply With Quote
Reply

Tags
environment

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



Our Communities

Our communities encompass many different hobbies and interests, but each one is built on friendly, intelligent membership.

» More about our Communities

Automotive Communities

Our Automotive communities encompass many different makes and models. From U.S. domestics to European Saloons.

» More about our Automotive Communities

Marine Communities

Our Marine websites focus on Cruising and Sailing Vessels, including forums and the largest cruising Wiki project on the web today.

» More about our Marine Communities


Copyright 2002- Social Knowledge, LLC All Rights Reserved.

All times are GMT -7. The time now is 13:08.


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.