Bug 186670 - [patch] astro/foxtrotgps: wrong paths in pkg-plist causes install to fail
Summary: [patch] astro/foxtrotgps: wrong paths in pkg-plist causes install to fail
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Thierry Thomas
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-12 03:00 UTC by Florian Degner
Modified: 2014-03-04 15:40 UTC (History)
0 users

See Also:


Attachments
file.diff (2.96 KB, patch)
2014-02-12 03:00 UTC, Florian Degner
no flags Details | Diff
foxtrotgps.patch (3.38 KB, patch)
2014-02-20 15:12 UTC, Florian Degner
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Degner 2014-02-12 03:00:01 UTC
pkg-plist contains several wrong directories:

% make install
===>  Installing for foxtrotgps-1.1.1_4
..
===>  Checking if astro/foxtrotgps already installed
===>   Registering installation for foxtrotgps-1.1.1_4
pkg-static: lstat(/usr/ports/astro/foxtrotgps/work/stage/usr/local/lib/locale/bg/LC_MESSAGES/foxtrotgps.mo): No such file or directory
pkg-static: lstat(/usr/ports/astro/foxtrotgps/work/stage/usr/local/lib/locale/cs/LC_MESSAGES/foxtrotgps.mo): No such file or directory
pkg-static: lstat(/usr/ports/astro/foxtrotgps/work/stage/usr/local/lib/locale/de/LC_MESSAGES/foxtrotgps.mo): No such file or directory
..
pkg-static: lstat(/usr/ports/astro/foxtrotgps/work/stage/usr/local/lib/locale/sr/LC_MESSAGES/): No such file or directory
pkg-static: lstat(/usr/ports/astro/foxtrotgps/work/stage/usr/local/lib/locale/sr/): No such file or directory
pkg-static: lstat(/usr/ports/astro/foxtrotgps/work/stage/usr/local/lib/locale/): No such file or directory
*** [fake-pkg] Error code 74

Stop in /usr/ports/astro/foxtrotgps.
%

Fix: The attached patch fixes the problem.

Patch attached with submission follows:
How-To-Repeat: % make -C /usr/ports/astro/foxtrotgps install
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2014-02-12 03:35:48 UTC
Maintainer of astro/foxtrotgps,

Please note that PR ports/186670 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/186670

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2014-02-12 03:35:49 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 3 crwhipp 2014-02-12 04:39:53 UTC
I am unable to duplicate this install error, either building
"naturally", or building in poudriere. 

Does the submitter have anything non-standard in /etc/make.conf?
Comment 4 Florian Degner 2014-02-20 15:12:05 UTC
On Thu, 13 Feb 2014 16:44:05 +0100, Craig Whipp <crwhipp@gmail.com> wrote:

> Florian,
>
> Can you provide me with more details on what your configuration was
> when you were building this?  I've been unable to duplicate the error
> on a 10.0-RELEASE machine, and applying your patch results in a
> failure similar to what you reported in the pr.
>
> What FreeBSD version, output of 'uname -a', any locales configured (I
> see you have a .de top level domain in your email), customizations to
> make.conf, etc.
>
> Thanks,
> Craig


Craig,

there's indeed something non-standard in my /etc/make.conf. The problem is
triggered by compiling astro/foxtrotgps with gcc46.

When CC=gcc46 ./configure generates different Makefiles. Things break
because it sets DATADIRNAME=share (it's DATADIRNAME=lib when $CC is "cc" or
"clang"). DATADIRNAME is used to determine where the locale files go:

% find work -name "Makefile" | xargs grep DATADIRNAME
...
work/foxtrotgps-1.1.1/po/Makefile:itlocaledir =
$(prefix)/$(DATADIRNAME)/locale
...
%

The interesting part is that "share" is actually the correct value. So the
real problem is that we get DATADIRNAME=lib by default. This in turn can
be fixed in a compiler-independent fashion by setting DATADIRNAME via
CONFIGURE_ENV (see attached patch).


Cheers,
Flo
Comment 5 crwhipp 2014-02-24 03:32:29 UTC
On Thu, 20 Feb 2014 16:12:05 +0100
"Florian Degner" <f.degner@gmx.de> wrote:

> On Thu, 13 Feb 2014 16:44:05 +0100, Craig Whipp <crwhipp@gmail.com>
> wrote:
> 
> > Florian,
> >
> > Can you provide me with more details on what your configuration was
> > when you were building this?  I've been unable to duplicate the
> > error on a 10.0-RELEASE machine, and applying your patch results in
> > a failure similar to what you reported in the pr.
> >
> > What FreeBSD version, output of 'uname -a', any locales configured
> > (I see you have a .de top level domain in your email),
> > customizations to make.conf, etc.
> >
> > Thanks,
> > Craig
> 
> 
> Craig,
> 
> there's indeed something non-standard in my /etc/make.conf. The
> problem is triggered by compiling astro/foxtrotgps with gcc46.
> 
> When CC=gcc46 ./configure generates different Makefiles. Things break
> because it sets DATADIRNAME=share (it's DATADIRNAME=lib when $CC is
> "cc" or "clang"). DATADIRNAME is used to determine where the locale
> files go:
> 
> % find work -name "Makefile" | xargs grep DATADIRNAME
> ...
> work/foxtrotgps-1.1.1/po/Makefile:itlocaledir =
> $(prefix)/$(DATADIRNAME)/locale
> ...
> %
> 
> The interesting part is that "share" is actually the correct value.
> So the real problem is that we get DATADIRNAME=lib by default. This
> in turn can be fixed in a compiler-independent fashion by setting
> DATADIRNAME via CONFIGURE_ENV (see attached patch).
> 
> 
> Cheers,
> Flo

Florian,

This latest patch looks good, thank you.

Could a commiter please apply the patch commit this?

Thanks,
Craig
Comment 6 Mark Linimon freebsd_committer freebsd_triage 2014-02-24 05:40:06 UTC
State Changed
From-To: feedback->open

Maintainer approved.
Comment 7 Thierry Thomas freebsd_committer freebsd_triage 2014-03-04 14:59:03 UTC
Responsible Changed
From-To: freebsd-ports-bugs->thierry


Take it.
Comment 8 dfilter service freebsd_committer freebsd_triage 2014-03-04 15:34:20 UTC
Author: thierry
Date: Tue Mar  4 15:34:12 2014
New Revision: 347022
URL: http://svnweb.freebsd.org/changeset/ports/347022
QAT: https://qat.redports.org/buildarchive/r347022/

Log:
  Fix installation of locale files.
  
  PR:		ports/186670
  Submitted by:	Florian Degner <f.degner (at) gmx.de>
  Approved by:	maintainer

Modified:
  head/astro/foxtrotgps/Makefile
  head/astro/foxtrotgps/pkg-descr
  head/astro/foxtrotgps/pkg-plist

Modified: head/astro/foxtrotgps/Makefile
==============================================================================
--- head/astro/foxtrotgps/Makefile	Tue Mar  4 14:47:57 2014	(r347021)
+++ head/astro/foxtrotgps/Makefile	Tue Mar  4 15:34:12 2014	(r347022)
@@ -3,7 +3,7 @@
 
 PORTNAME=	foxtrotgps
 PORTVERSION=	1.1.1
-PORTREVISION=	4
+PORTREVISION=	5
 CATEGORIES=	astro geography
 MASTER_SITES=	http://www.foxtrotgps.org/releases/
 
@@ -16,6 +16,7 @@ LIB_DEPENDS=	libcurl.so:${PORTSDIR}/ftp/
 		libgps.so:${PORTSDIR}/astro/gpsd
 
 GNU_CONFIGURE=	yes
+CONFIGURE_ENV=	DATADIRNAME=share
 CONFIGURE_ARGS=	--disable-schemas-install
 USES=		gettext gmake pkgconfig shebangfix
 SHEBANG_FILES=	contrib/convert2gpx \

Modified: head/astro/foxtrotgps/pkg-descr
==============================================================================
--- head/astro/foxtrotgps/pkg-descr	Tue Mar  4 14:47:57 2014	(r347021)
+++ head/astro/foxtrotgps/pkg-descr	Tue Mar  4 15:34:12 2014	(r347022)
@@ -6,4 +6,4 @@ are available, and new ones may be added
 
 Map areas may be downloaded and cached for use while offline.
 
-WWW:  http://www.foxtrotgps.org
+WWW: http://www.foxtrotgps.org

Modified: head/astro/foxtrotgps/pkg-plist
==============================================================================
--- head/astro/foxtrotgps/pkg-plist	Tue Mar  4 14:47:57 2014	(r347021)
+++ head/astro/foxtrotgps/pkg-plist	Tue Mar  4 15:34:12 2014	(r347022)
@@ -4,18 +4,18 @@ bin/foxtrotgps
 bin/georss2foxtrotgps-poi
 bin/osb2foxtrot
 bin/poi2osm
-lib/locale/bg/LC_MESSAGES/foxtrotgps.mo
-lib/locale/cs/LC_MESSAGES/foxtrotgps.mo
-lib/locale/de/LC_MESSAGES/foxtrotgps.mo
-lib/locale/es/LC_MESSAGES/foxtrotgps.mo
-lib/locale/fi/LC_MESSAGES/foxtrotgps.mo
-lib/locale/fr/LC_MESSAGES/foxtrotgps.mo
-lib/locale/hu/LC_MESSAGES/foxtrotgps.mo
-lib/locale/nl/LC_MESSAGES/foxtrotgps.mo
-lib/locale/ru/LC_MESSAGES/foxtrotgps.mo
-lib/locale/sk/LC_MESSAGES/foxtrotgps.mo
-lib/locale/ja/LC_MESSAGES/foxtrotgps.mo
-lib/locale/sr/LC_MESSAGES/foxtrotgps.mo
+share/locale/bg/LC_MESSAGES/foxtrotgps.mo
+share/locale/cs/LC_MESSAGES/foxtrotgps.mo
+share/locale/de/LC_MESSAGES/foxtrotgps.mo
+share/locale/es/LC_MESSAGES/foxtrotgps.mo
+share/locale/fi/LC_MESSAGES/foxtrotgps.mo
+share/locale/fr/LC_MESSAGES/foxtrotgps.mo
+share/locale/hu/LC_MESSAGES/foxtrotgps.mo
+share/locale/nl/LC_MESSAGES/foxtrotgps.mo
+share/locale/ru/LC_MESSAGES/foxtrotgps.mo
+share/locale/sk/LC_MESSAGES/foxtrotgps.mo
+share/locale/ja/LC_MESSAGES/foxtrotgps.mo
+share/locale/sr/LC_MESSAGES/foxtrotgps.mo
 man/man1/convert2gpx.1.gz
 man/man1/convert2osm.1.gz
 man/man1/foxtrotgps.1.gz
@@ -38,28 +38,28 @@ share/pixmaps/foxtrotgps-wp.png
 share/pixmaps/foxtrotgps.png
 @dirrm %%DATADIR%%
 @dirrm %%DOCSDIR%%
-@dirrmtry lib/locale/sk/LC_MESSAGES
-@dirrmtry lib/locale/sk
-@dirrmtry lib/locale/ru/LC_MESSAGES
-@dirrmtry lib/locale/ru
-@dirrmtry lib/locale/nl/LC_MESSAGES
-@dirrmtry lib/locale/nl
-@dirrmtry lib/locale/hu/LC_MESSAGES
-@dirrmtry lib/locale/hu
-@dirrmtry lib/locale/fr/LC_MESSAGES
-@dirrmtry lib/locale/fr
-@dirrmtry lib/locale/fi/LC_MESSAGES
-@dirrmtry lib/locale/fi
-@dirrmtry lib/locale/es/LC_MESSAGES
-@dirrmtry lib/locale/es
-@dirrmtry lib/locale/de/LC_MESSAGES
-@dirrmtry lib/locale/de
-@dirrmtry lib/locale/cs/LC_MESSAGES
-@dirrmtry lib/locale/cs
-@dirrmtry lib/locale/bg/LC_MESSAGES
-@dirrmtry lib/locale/bg
-@dirrmtry lib/locale/ja/LC_MESSAGES
-@dirrmtry lib/locale/ja
-@dirrmtry lib/locale/sr/LC_MESSAGES
-@dirrmtry lib/locale/sr
-@dirrmtry lib/locale
+@dirrmtry share/locale/sk/LC_MESSAGES
+@dirrmtry share/locale/sk
+@dirrmtry share/locale/ru/LC_MESSAGES
+@dirrmtry share/locale/ru
+@dirrmtry share/locale/nl/LC_MESSAGES
+@dirrmtry share/locale/nl
+@dirrmtry share/locale/hu/LC_MESSAGES
+@dirrmtry share/locale/hu
+@dirrmtry share/locale/fr/LC_MESSAGES
+@dirrmtry share/locale/fr
+@dirrmtry share/locale/fi/LC_MESSAGES
+@dirrmtry share/locale/fi
+@dirrmtry share/locale/es/LC_MESSAGES
+@dirrmtry share/locale/es
+@dirrmtry share/locale/de/LC_MESSAGES
+@dirrmtry share/locale/de
+@dirrmtry share/locale/cs/LC_MESSAGES
+@dirrmtry share/locale/cs
+@dirrmtry share/locale/bg/LC_MESSAGES
+@dirrmtry share/locale/bg
+@dirrmtry share/locale/ja/LC_MESSAGES
+@dirrmtry share/locale/ja
+@dirrmtry share/locale/sr/LC_MESSAGES
+@dirrmtry share/locale/sr
+@dirrmtry share/locale
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 9 Thierry Thomas freebsd_committer freebsd_triage 2014-03-04 15:35:15 UTC
State Changed
From-To: open->closed


Committed, thanks! 

To maintainer: I'd like to set the license as GPLv2; would you approve 
it?