Cruisers Forum
 


Join CruisersForum Today

Reply
 
Thread Tools Rate Thread Display Modes
Old 28-09-2010, 14:31   #106
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
I believe the way to do it is to version as 2.2~918-1

then 2.2 is > 2.2~xyz

where the ending -1 is our first package upload. Perhaps keep that at -0 until the first real upload to the ftp masters?


Hamish
__________________

__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 00:23   #107
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

Hi,

I'd like to get back to preparing OpenCPN for upload as an official Debian package. (and thus onflow to Ubuntu and derivs) I hadn't realized how much time had passed!

We were doing pretty well, but debian was frozen last time we attacked it. Debian's open for new stuff again so it seems like a good time. Since we last visited this DebianGIS has started to migrate to a new Git repo*, although the OpenCPN control files are still held in the Alioth Subversion repo**.

* git.debian.org Git (debianGIS packages all fall under the "pkg-grass/" name)
** [pkg-grass] Index of /packages/opencpn

see here for DebianGIS Svn->Git migration notes: DebianGis/Svn2Git - Debian Wiki


I think the first step in waking this effort back up is to modify trunk/ in alioth svn to reflect the latest opencpn git-head package requirements and get it working again.

The next step I think is to get the last stable release (2.3.1 at this point) built, and to publish .debs for Debian/stable 32 bit i686 and 64bit amd64 on the SourceForge site (or if just of interest to devs I can probably find a spot on a OSGeo server for that).

After we are back to operational status the next step would be to get back to flushing out the last of the lintian errors and reviving the Debian ITP:
#538067 - ITP: opencpn -- A concise ChartPlotter/Navigator - Debian Bug report logs

I think a necessary hurdle to overcome is to donate some code to allow OpenCPN to read from the GMT flavour of the GSHHS world coastline data, so that they (and ZyGrib, and other packages which use that coastline data) can all share the common data packages.

This will take a bit of effort, but I believe that 90% of it is done and we have already gotten past the worst road block (code license provenance review), and the rest is just, as they say, details.


thanks,
Hamish
--
DebianGIS Team
__________________

__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 01:04   #108
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

well, step one passed. git 2.4.412 built successfully on Debian/stable
amd64.

Code:
cd git/opencpn/
git pull
svn co svn://svn.debian.org/pkg-grass/packages/opencpn/trunk/debian debian
debuild clean
debuild binary
dpkg -i ../opencpn_2.4.412-1_amd64.deb
and it works!


Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 01:19   #109
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

The Lintian version 2.4.3 (debian/squeeze) check is relatively clean, only 3 errors:

Code:
$ lintian --pedantic opencpn_2.4.412-1_amd64.deb 
P: opencpn: no-upstream-changelog
E: opencpn: arch-dependent-file-in-usr-share ./usr/share/opencpn/plugins/libdashboard_pi.so
E: opencpn: arch-dependent-file-in-usr-share ./usr/share/opencpn/plugins/libgrib_pi.so
E: opencpn: embedded-library ./usr/share/opencpn/plugins/libgrib_pi.so: bzip2

Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 01:23   #110
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

The correct place to install the plugins on a debian system is /usr/lib/opencpn-plugins/. (see the GDAL package for an example)

Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 03:56   #111
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

ok, not exactly sure I've got the plugin patch perfect, but it's a start. The embedded-library bzip2 lintian error remains.

Hamish
[pkg-grass] Index of /packages/opencpn
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 04:47   #112
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

Ok, with respect to the last remaining lintian error:
Code:
E: opencpn: embedded-library ./usr/share/opencpn/plugins/libgrib_pi.so: bzip2
I've prepared the following patch:
Code:
Use system's zlib, bzip2 instead of embedded copy.
Index: opencpn/plugins/grib_pi/CMakeLists.txt
===================================================================
--- opencpn.orig/plugins/grib_pi/CMakeLists.txt 2011-04-15 23:16:33.320574276 +1200
+++ opencpn/plugins/grib_pi/CMakeLists.txt      2011-04-15 23:18:35.165862744 +1200
@@ -79,18 +79,18 @@
             src/GribRecord.cpp  
             src/zuFile.cpp 
             src/IsoLine.cpp 
-            src/bzip2/bzlib.c 
-            src/bzip2/blocksort.c 
-            src/bzip2/compress.c 
-            src/bzip2/crctable.c 
-            src/bzip2/decompress.c 
-            src/bzip2/huffman.c 
-            src/bzip2/randtable.c
+#            src/bzip2/bzlib.c 
+#            src/bzip2/blocksort.c 
+#            src/bzip2/compress.c 
+#            src/bzip2/crctable.c 
+#            src/bzip2/decompress.c 
+#            src/bzip2/huffman.c 
+#            src/bzip2/randtable.c
        )
 ADD_LIBRARY(${PACKAGE_NAME} SHARED ${SRC_GRIB})
 
-INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/zlib-1.2.3)
-INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/bzip2)
+#INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/zlib-1.2.3)
+#INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/bzip2)
 
 IF(WIN32)
   SET(OPENCPN_IMPORT_LIB "../../${CMAKE_CFG_INTDIR}/${PARENT}")
and it builds, but at run-time the plugin fails with this error message in opencpn.log:
Code:
15:25:21: PlugInManager searching for PlugIns in location /usr/lib/opencpn-plugins
15:25:21: PlugInManager: Loading PlugIn: /usr/lib/opencpn-plugins/libgrib_pi.so
15:25:21: Error: /usr/lib/opencpn-plugins/libgrib_pi.so: undefined symbol: BZ2_bzReadClose
15:25:21:    PlugInManager: Cannot load library: /usr/lib/opencpn-plugins/libgrib_pi.so
the Build-depends in debian/control does contain libbz2-dev (which supplies libbz2.a) but I'm missing how to link against that in the CMakeLists.txt file. (I'm no cmake expert)


any ideas?
Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 05:37   #113
Registered User

Join Date: Feb 2010
Location: On the go. Not in Prague.
Posts: 2,554
Re: OpenCPN Build on Debian

Hamish...
Certainly not perfect, but could serve you some
Code:
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6a80b69..eb5f692 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -111,6 +111,13 @@ INCLUDE_DIRECTORIES(${OPENGL_INCLUDE_DIR})
 
 FIND_PACKAGE(Gettext REQUIRED)
 
+IF(UNIX)
+FIND_PACKAGE(BZip2 REQUIRED)
+INCLUDE_DIRECTORIES(${BZIP2_INCLUDE_DIR})
+FIND_PACKAGE(ZLIB REQUIRED)
+INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR})
+ENDIF(UNIX)
+
 # For convenience we define the sources as a variable. You can add 
 # header files and cpp/c files and CMake will sort them out
 
@@ -500,6 +507,8 @@ IF(UNIX)
 TARGET_LINK_LIBRARIES(${PACKAGE_NAME}
       ${OPENGL_LIBRARIES}
       ${GETTEXT_LIBRARY}
+      ${BZIP2_LIBRARIES}
+      ${ZLIB_LIBRARY}
 )
 ENDIF(UNIX)
 
diff --git a/plugins/grib_pi/CMakeLists.txt b/plugins/grib_pi/CMakeLists.txt
index 6b998c0..63ea8a0 100644
--- a/plugins/grib_pi/CMakeLists.txt
+++ b/plugins/grib_pi/CMakeLists.txt
@@ -79,6 +79,10 @@ SET(SRC_GRIB
             src/GribRecord.cpp  
             src/zuFile.cpp 
             src/IsoLine.cpp 
+)
+ADD_LIBRARY(${PACKAGE_NAME} SHARED ${SRC_GRIB})
+IF(!UNIX)
+SET(SRC_BZIP
             src/bzip2/bzlib.c 
             src/bzip2/blocksort.c 
             src/bzip2/compress.c 
@@ -86,11 +90,14 @@ SET(SRC_GRIB
             src/bzip2/decompress.c 
             src/bzip2/huffman.c 
             src/bzip2/randtable.c
-    )
-ADD_LIBRARY(${PACKAGE_NAME} SHARED ${SRC_GRIB})
+)
+ADD_LIBRARY(${PACKAGE_NAME} SHARED ${SRC_BZIP})
+ENDIF(!UNIX)
 
-INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/zlib-1.2.3)
-INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/bzip2)
+IF(!UNIX)
+  INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/zlib-1.2.3)
+  INCLUDE_DIRECTORIES(${PLUGIN_SOURCE_DIR}/src/bzip2)
+ENDIF(!UNIX)
 
 IF(WIN32)
   SET(OPENCPN_IMPORT_LIB "../../${CMAKE_CFG_INTDIR}/${PARENT}")
Pavel
__________________
nohal is offline   Reply With Quote
Old 15-04-2011, 07:53   #114
Registered User
 
antonm's Avatar

Join Date: Feb 2010
Location: Saint Petersburg, Russia
Posts: 66
Re: OpenCPN Build on Debian

Quote:
Originally Posted by nohal View Post
Hamish...
Certainly not perfect, but could serve you some
Thanks. Last time I also has been stucked with cmake as I am not cmake expert either. Will probably have to learn it anyway :-)
__________________
antonm is offline   Reply With Quote
Old 15-04-2011, 08:49   #115
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

Quote:
Originally Posted by nohal View Post
Hamish...
Certainly not perfect, but could serve you some
thanks. applied in DebianGIS svn r2978.

[pkg-grass] View of /packages/opencpn/trunk/debian/patches/rm_embedded_zlib.patch

we are now lintian clean! Another hurdle past.


Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 09:52   #116
Registered User

Join Date: Feb 2010
Location: On the go. Not in Prague.
Posts: 2,554
Re: OpenCPN Build on Debian

Hamish, Anton...
I've finished the patch so that it doesn't break the Windows build and posted it to flyspray at FS#407 : Build process change to allow inclusion in Debian
You can watch that task to see when it gets included upstream.

Pavel
__________________
nohal is offline   Reply With Quote
Old 15-04-2011, 18:52   #117
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

Quote:
Originally Posted by nohal View Post
Hamish, Anton...
I've finished the patch so that it doesn't break the Windows build and posted it to flyspray at FS#407 : Build process change to allow inclusion in Debian
You can watch that task to see when it gets included upstream.
great, thanks. for the patch in the Debian package it doesn't matter if it works outside of Debian/Ubuntu, so I'll be lazy and leave that as-is until the upstream patch is in place.

Note two changes I made to your patch: applied indentation and combined the two consecutive if(NOT UNIX) statements into a single one.


Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 18:57   #118
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

A question on the version numbers, as I haven't been following that too closely.

Is it expected there will be a 2.4.0, and 2.4.1, ... releases after the beta cycle?
Or will version numbers look like 2.4.412 from now on? I ask because if there will be a 2.4.0 then to avoid automated upgrade/downgrade problems we'd have to set the debian package version as 2.4.0~412 or similar as 2.4.412 >> 2.4.0 to the computer.

thanks,
Hamish
__________________
HamishB is offline   Reply With Quote
Old 15-04-2011, 19:08   #119
Registered User

Join Date: Jun 2010
Location: St. Petersburg, Florida
Boat: Gemini 3200
Posts: 431
Re: OpenCPN Build on Debian

Quote:
Originally Posted by HamishB View Post
A question on the version numbers, as I haven't been following that too closely.

Is it expected there will be a 2.4.0, and 2.4.1, ... releases after the beta cycle?
Or will version numbers look like 2.4.412 from now on? I ask because if there will be a 2.4.0 then to avoid automated upgrade/downgrade problems we'd have to set the debian package version as 2.4.0~412 or similar as 2.4.412 >> 2.4.0 to the computer.

thanks,
Hamish
I think the scheme is that even numbers following the decimal point are beta versions. Full releases will have odd numbers following the decimal point. So, for example, 2.4.412 is a beta version. The three digit build number following the second decimal point is the month and day it was released. The next stable release will be 2.5.n.

Fabbian
__________________
fgd3 is offline   Reply With Quote
Old 18-04-2011, 02:58   #120
Registered User
 
HamishB's Avatar

Join Date: Jan 2010
Location: New Zealand
Posts: 286
Re: OpenCPN Build on Debian

ok, it's back to 2.4.412 in DebianGIS SVN and (!UNIX) changed to (NOT UNIX) in the zlib patch.

so now that it's lintian-clean what's the next step? resubmit to the mentors area for another review? have we ticked all the boxes from their last look at it?


Hamish
__________________

__________________
HamishB is offline   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 Build on Win32 Thorac OpenCPN 108 13-06-2011 05:56
OpenCPN bdbcat OpenCPN 1343 19-09-2009 15:59
OpenCPN with BSB v4 selkie Navigation 4 03-08-2009 11:32


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

RV & Travel Trailer Communities

Our RV & Travel Trailer sites encompasses virtually all types of Recreational Vehicles, from brand-specific to general RV communities.

» More about our RV 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-2012 Social Knowledge, LLC All Rights Reserved.

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


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

Sailing News Delivered to your Email!

Stay up-to-date with the latest cruising news.

unsusbcribe at anytime with one click

Close [X]


ShowCase vBulletin Plugins by Drive Thru Online, Inc.