Cruisers Forum
 


Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 17-02-2014, 07:33   #1
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,147
Plugin Distribution

This thread is for discussing a plugin distribution handling. Initially started on another thread so the history is from here: http://www.cruisersforum.com/forums/...ml#post1468541 to include http://www.cruisersforum.com/forums/...ml#post1470242

Primary we need a language files installation rutine so that the work done by the translators really will be used by all users and not only by them capable to download the source. But that will also lead to a proper plugin installation as well. Not less important for those plugins that needs additional files.

My opinion so far is that we shall use the same script based system as for OpenCPN itself. That is the NSIS.
I've now played with WMM plugin in order to understand the NSIS. This little test is a shell-test to see if it works on a Windows system at all. I've run it on: XP, W7_32 and W7_64 but please verify.
The next step is to include the language .mo-files and distribute them to there corresponding directories.

The attached exe file is copying "wmm_pi.dll" to the plugins directory. To check its function you can rename or delete any existing similar file.
Discard the .pdf extension before use.

Håkan
Attached Files
File Type: pdf WMM_pi_Win_Test.exe.pdf (168.8 KB, 88 views)
Hakan is offline   Reply With Quote
Old 17-02-2014, 08:07   #2
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,147
Re: Plugin distribution

What I've done so far:
I followed the instructions about installing NSIS here: Compiling - Windows | Official OpenCPN Homepage the install NSIS part.

I found some examples in the program files and on the the net to "borrow" from. Eventually I got a working script to start with.
I'm sure someone else already now how to handle this program so please add or run over whenever suitably. But if my code is of interest its here:
(Discard .pdf as usual then it's a text file)
Håkan
Attached Files
File Type: pdf wmm_pi_test.nsi.pdf (2.8 KB, 64 views)
Hakan is offline   Reply With Quote
Old 17-02-2014, 11:30   #3
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,632
Images: 2
Re: Plugin distribution

Hakan, will try tonight.
rgleason is offline   Reply With Quote
Old 17-02-2014, 16:21   #4
Registered User
 
Gilletarom's Avatar

Join Date: Mar 2010
Location: France
Boat: 10.50 mètres
Posts: 2,988
Re: Plugin distribution

hello Hakan,

Quote:
Originally Posted by Hakan View Post
.....

The attached exe file is copying "wmm_pi.dll" to the plugins directory. To check its function you can rename or delete any existing similar file.
Discard the .pdf extension before use.

Håkan
Your dll.exe install run correctly with W7.
Gilletarom is offline   Reply With Quote
Old 17-02-2014, 17:17   #5
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,147
Re: Plugin distribution

Thanks Gille..

And here is next version. Now it shall install also those .mo file available in the Git source (+the Swedish one)

Next step...?

Håkan
Attached Files
File Type: pdf WMM_pi_Win_0.1.exe.pdf (175.4 KB, 102 views)
Hakan is offline   Reply With Quote
Old 18-02-2014, 01:23   #6
Registered User
 
Gilletarom's Avatar

Join Date: Mar 2010
Location: France
Boat: 10.50 mètres
Posts: 2,988
Re: Plugin distribution

Hello Hakan,

Quote:
Originally Posted by Hakan View Post
Thanks Gille..

And here is next version. Now it shall install also those .mo file available in the Git source (+the Swedish one)

Next step...?

Håkan
Where is the git that you use here for WMM ?

B.R. Gilletarom
Gilletarom is offline   Reply With Quote
Old 18-02-2014, 02:01   #7
Registered User
 
Gilletarom's Avatar

Join Date: Mar 2010
Location: France
Boat: 10.50 mètres
Posts: 2,988
Re: Plugin distribution

Hello Hakan,

Quote:
Originally Posted by Hakan View Post
Thanks Gille..

And here is next version. Now it shall install also those .mo file available in the Git source (+the Swedish one)

Next step...?

Håkan
This second version do not run correctly.

I choice to install in opencpn 3.3.1328 folder. I try twice and in each case, it create a new sub folder opencpn in the folder opencpn 3.3.1328. And, in this sub folder, it create two sub-folder :
- "Plugins" that contains wmm dll.
- "Share" that contains a sub folder "Locale"
In this sub folder "locale", there is some other sub-folders. One of these is fr folder..
And, in this fr folder, there is a FILE named LC_MESSAGES.

See screen copy
Attached Thumbnails
Click image for larger version

Name:	2014-02-18_Plugin_install.jpg
Views:	171
Size:	14.2 KB
ID:	76360  
Gilletarom is offline   Reply With Quote
Old 18-02-2014, 02:11   #8
Registered User
 
Gilletarom's Avatar

Join Date: Mar 2010
Location: France
Boat: 10.50 mètres
Posts: 2,988
Re: Plugin distribution

Screen copy another because it seem that it is go away ... ?
Attached Thumbnails
Click image for larger version

Name:	2014-02-18_Plugin_install.jpg
Views:	169
Size:	14.2 KB
ID:	76361  
Gilletarom is offline   Reply With Quote
Old 18-02-2014, 03:24   #9
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,147
Re: Plugin distribution

Quote:
Originally Posted by Gilletarom View Post
Hello Hakan,
This second version do not run correctly.
I choice to install in opencpn 3.3.1328 folder................
Gille...
Well - I would claim the installation program does exactly what it's told to!
OpenCPN is normally installed in the directory "\program files\opencpn"
But I think you have used a parallel installation of the beta version 3.3.1328 as offered in the OCPN installation procedure.

So - shall we try to adapt to that also for the plugins or shall we claim a beta tester is more of a "hacker" and can copy the files him/her-self?

Well - I can have look and see. Somewhat I agree that we shall follow what OCPN does?

As you can see from the installation window where I changed the installation location (screenshot) it's rather clear that the result will be as you described.

Quote:
In this sub folder "locale", there is some other sub-folders. One of these is fr folder..
And, in this fr folder, there is a FILE named LC_MESSAGES.
Yes- and in the folder LC_MESSAGES are your French .mo files. That's the structure in OCPN.

Quote:
Where is the git that you use here for WMM ?
git://github.com/nohal/wmm_pi.git

Thanks/ Håkan
Attached Thumbnails
Click image for larger version

Name:	wmm_install.jpg
Views:	226
Size:	80.0 KB
ID:	76364  
Hakan is offline   Reply With Quote
Old 18-02-2014, 04:06   #10
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,632
Images: 2
Re: Plugin distribution

Hakan it worked beautifullly. First license, then action, then can see path and what file was expanded and copied. This was on Win7 x 64
Quote:
The attached exe file is copying "wmm_pi.dll" to the plugins directory. To check its function you can rename or delete any existing similar file.
Discard the .pdf extension before use.

Håkan Attached Files WMM_pi_Win_Test.exe.pdf (168.8 KB, 4 views)
Later: I don't find it under Control Panel > Programs & Features list.
rgleason is offline   Reply With Quote
Old 18-02-2014, 04:28   #11
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,632
Images: 2
Re: Plugin distribution

Ran WMM_pi_Win_0.1.exe from http://www.cruisersforum.com/forums/...ml#post1470634

1. Found wmm_pi.dll in opencpn\plugins
2. Found "opencpn-wmm_pi.mo" in path C:\Program Files (x86)\OpenCPN\share\locale\fr\LC_MESSAGES

So it worked on Win7x64!!! Great job Hakan.

Is there any way to be able to scroll across to see the full set of actions taken? ....However this is very nice!

Questions:
How hard would it be to include the "Data" files for
Climatology
Celestial Navigation
Weather_routing
Weatherfax
etc?
Is it possible to have this show up in the Control Panel > Programs and Features? - Not necessary, and would like all plugins to start with Opencpn - [Plugin Name] but just wondering.

I might need a little training....quidance.


---I guess the png attachment is acting up again!!! It says "Rotate Image". There is no image. I've tried twice, two different ways, with renaming. This forum's image attachments are not working for me. How about others? Should we advise them?
Attached Thumbnails
Click image for larger version

Name:	Opencpn-Setup-WMM.png
Views:	223
Size:	23.7 KB
ID:	76373  
rgleason is offline   Reply With Quote
Old 18-02-2014, 06:22   #12
Registered User
 
Gilletarom's Avatar

Join Date: Mar 2010
Location: France
Boat: 10.50 mètres
Posts: 2,988
Re: Plugin distribution

Hello Hakan,

Quote:
Originally Posted by Hakan View Post
.....


Yes- and in the folder LC_MESSAGES are your French .mo files. That's the structure in OCPN.

git://github.com/nohal/wmm_pi.git

Thanks/ Håkan
Thank for the git link.

1° Yesterday, with the firts version, when I try, I try immediately to install in O 3.3.1328. And Yesterday, all was OK with the first version.

2° This day,I try immediately to install in O 3.3.1328 with the second version. There is no LC_MESSAGES folder. There is a strange LC_MESSAGES file. And the content of this file is the content of the french mo file.

B.R. Gilletarom.
Gilletarom is offline   Reply With Quote
Old 18-02-2014, 06:26   #13
Registered User
 
Gilletarom's Avatar

Join Date: Mar 2010
Location: France
Boat: 10.50 mètres
Posts: 2,988
Re: Plugin distribution

Hello hakan,

But I do not understand why you recreate everything. Konny, author of Find It plugin and plugin LogbookKonni has already created an installer and an uninstaller software plugin that work very well.

Why you do not leave what he has already done?

B.R. Gilletarom
Gilletarom is offline   Reply With Quote
Old 18-02-2014, 11:56   #14
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,632
Images: 2
Re: Plugin distribution

Gille... I don't think Hakan has gotten to touching Logbook Konni.... he is just using Wmm_pi as an example, ....testing the script.... it takes some time and some work ... so we need to help him as you are doing.

I found both versions worked for me, creating the file
opencpn-wmm_pi.mo" in path C:\Program Files (x86)\OpenCPN\share\locale\fr\LC_MESSAGES
rgleason is offline   Reply With Quote
Old 18-02-2014, 12:05   #15
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,147
Re: Plugin distribution

Quote:
Originally Posted by Gilletarom View Post
Hello hakan,

But I do not understand why you recreate everything. Konny, author of Find It plugin and plugin LogbookKonni has already created an installer and an uninstaller software plugin that work very well.

Why you do not leave what he has already done?

B.R. Gilletarom
Gillle.. If its like that I really don't understand either. So why is it not used? So why was the discussion started at all? In that respect I'm rather new in this game and don't have clue of the history you refer to.

And I really agree to not "invent the wheel" again and will stop it immediately.
Then - We may instead discus how to use the existing tools.
1. Where are the tools?
2. Why is it not used?
3. In some way it may be up to the plugin author to support a proper distribution to the presumed users? - or anyone else? Are you using it?

Håkan
Hakan is offline   Reply With Quote
Reply

Tags
plug, rib


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 1918 20-04-2024 07:12
OpenCPN not recognising Virtual COM port LifePart2 OpenCPN 92 24-04-2014 10:08
OpenCPN Beta Version 3.3.814 Released bdbcat OpenCPN 64 06-10-2013 17:08
GRIB Weather Mark Ward OpenCPN 26 12-02-2012 21:33
Route Properties, Missing Functions James Baines OpenCPN 13 13-07-2011 04:31

Advertise Here


All times are GMT -7. The time now is 05:50.


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

ShowCase vBulletin Plugins by Drive Thru Online, Inc.