pcb

The maintainer mode mess.

Bug #1496105 reported by Traumflug
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
pcb
Fix Released
High
Unassigned

Bug Description

Let me open a bug to track this. Also to allow a LPxxx branch in the repo.

4 weeks ago I removed AM_MAINTAINER_MODE, because this prohibited rebuilding some files, e.g. parse_y.c on source changes.

Today I removed all files not coming with Git. Many of them manually, because not catched by a 'make maintainer-clean'. Since this cleaning, a 'make distcheck' fails entirely. The same worked before.

A regular build ('./autogen.sh && ./configure && make') still works.

- - - - - -
To be more precise, this does not work:

./autogen.sh && ./configure && make
make distcheck

It fails with
[... deliberately cut off ...]ter-statement ../../intl/plural.c
In file included from plural.y:35:0:
../../intl/plural-exp.h:94:23: error: conflicting types for ‘libintl_gettextparse’
 # define PLURAL_PARSE libintl_gettextparse
                       ^
plural.y:40:25: note: in expansion of macro ‘PLURAL_PARSE’
plural.c:185:5: note: in expansion of macro ‘__gettextparse’

- - - - - -
This sequence was found to WORK:

./autogen.sh && ./configure && make
make distcheck
./autogen.sh && ./configure && make
make distcheck

==> Yes, that's double the work, but the second 'make distcheck' completes.

Tags: build-system
Revision history for this message
Traumflug (mah-jump-ing) wrote :
Revision history for this message
Traumflug (mah-jump-ing) wrote :

[21:54] <bert> configure: error:
[21:54] <bert> You have requested to build with the toporouter. For this to work you
[21:54] <bert> must have the GTS library installed, typically found in packages named
[21:54] <bert> 'libgts-dev' or similar.
[21:54] <bert> Alternatively you can disable the toporouter with --disable-toporouter.
[21:54] <bert> make: *** [distcheck] Error 1
[21:55] <bert> distcheck doesn't respect the --disable-toporouter directive !

[22:03] <felixs_> you can pass configure options through the distcheck target by overriding DISTCHECK_CONFIGURE_FLAGS
[22:03] <felixs_> distcheck will use these options to configure for the test build

Traumflug (mah-jump-ing)
Changed in geda-project:
importance: Undecided → Medium
status: New → Confirmed
tags: added: build-system
Changed in pcb:
status: New → Confirmed
Revision history for this message
Chad Parker (parker-charles) wrote :

I ran into this while working on a release. It appears to be a problem with Bison 3. Here are a few related references:
https://github.com/openwrt/packages/issues/2664
http://stackoverflow.com/questions/33562051/conflicting-types-for-libintl-gettextparse
https://sourceware.org/ml/binutils/2014-12/msg00114.html

One solution is to remove the --with-included-gettext option from the distcheck configure line (easiest, unless there's a reason its there). Another is to break some of the files up and select which to use depending on which version of Bison is used.

I've confirmed that getting rid of the option solves the problem. I'm not sure where the option comes from though, or if there's a reason it's there.

Revision history for this message
Bert Timmerman (bert-timmerman) wrote :

Hi Chad,

I can only think of one reason for the "--with-included-gettext option" to be in the "make distcheck" target, and that is for building pcb with gettext language support in an environment where there is no gettext package installed.

By removing some of the files needed by this option, we probably got into this mess.

Some files were probably removed (as mentioned in the opening #0 comment), although I haven't checked this in the pcb repository yet (back tracing git master).

I think that retrieving the required files from oblivion is the way to go here.

Kind regards,

Bert Timmerman.

Changed in pcb:
importance: Undecided → High
milestone: none → next-bug-release
Revision history for this message
Chad Parker (parker-charles) wrote :

I've been looking at this a little more.

This is what happens when I build in a Debian VM:
The first time that autogen.sh is run, autopoint copies everything into the intl/ directory.
The second time that autogen.sh is run, autopoint only copies intl/plural.c and po/Makefile.in.in.
So, since plural.c is newer than plural.y, make wont regenerate plural.c from plural.y and the new plural.c is used. The two plural.c files aren't the same, they're generated from two different version of Bison. From the diff:

-/* A Bison parser, made by GNU Bison 2.7. */ (build by make from plural.y)
+/* A Bison parser, made from plural.y (2nd invocation overwrites built version with this,)
+ by GNU bison 1.35. */ (this version works)

which is still strange since bison on the Debian VM is version 3.0.2...

Revision history for this message
Chad Parker (parker-charles) wrote :

Another possible solution is to upgrade gettext to a more current version, 0.19.3, (released in 2014). Then distcheck works the first time. The plural.c reports bison version 3.0.2.

Revision history for this message
Dan McMahill (dmcmahill) wrote :

By "upgrade gettext", do you just mean bump the minimum required in autogen.sh from 0.14 to 0.18 or 0.19? Do we need to change anything else? If that is all we need to do then sure, lets bump it up but perhaps we can use the minimum version we actually need.

The reason for the old maintainer mode stuff was to try and minimize extra tools users needed to build.

I'd assume the reason for the with included gettext bit is for helping reduce dependencies on external libs.

Revision history for this message
Chad Parker (parker-charles) wrote : Re: [Bug 1496105] Re: The maintainer mode mess.

A couple things. First, you bump the version in configure.ac in the
AM_GNU_GETTEXT_VERSION macro. Then when autogen.sh is run, autopoint
automake, etc. read that version from configure.ac. autopoint then will
actually copy many of the gettext source files into the intl/ and po/
directories, that correspond to the version of gettext that you specify.

So, it's a little more than just bumping the required version of gettext,
because you're also bumping the version of gettext that's "included".

But yes, this all happens just by changing the one number in configure.ac.

--Chad

On Jan 7, 2017 6:44 PM, "Dan McMahill" <email address hidden> wrote:

> By "upgrade gettext", do you just mean bump the minimum required in
> autogen.sh from 0.14 to 0.18 or 0.19? Do we need to change anything
> else? If that is all we need to do then sure, lets bump it up but
> perhaps we can use the minimum version we actually need.
>
> The reason for the old maintainer mode stuff was to try and minimize
> extra tools users needed to build.
>
> I'd assume the reason for the with included gettext bit is for helping
> reduce dependencies on external libs.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1496105
>
> Title:
> The maintainer mode mess.
>
> Status in gEDA project:
> Confirmed
> Status in pcb:
> Confirmed
>
> Bug description:
> Let me open a bug to track this. Also to allow a LPxxx branch in the
> repo.
>
> 4 weeks ago I removed AM_MAINTAINER_MODE, because this prohibited
> rebuilding some files, e.g. parse_y.c on source changes.
>
> Today I removed all files not coming with Git. Many of them manually,
> because not catched by a 'make maintainer-clean'. Since this cleaning,
> a 'make distcheck' fails entirely. The same worked before.
>
> A regular build ('./autogen.sh && ./configure && make') still works.
>
> - - - - - -
> To be more precise, this does not work:
>
> ./autogen.sh && ./configure && make
> make distcheck
>
> It fails with
> [... deliberately cut off ...]ter-statement ../../intl/plural.c
> In file included from plural.y:35:0:
> ../../intl/plural-exp.h:94:23: error: conflicting types for
> ‘libintl_gettextparse’
> # define PLURAL_PARSE libintl_gettextparse
> ^
> plural.y:40:25: note: in expansion of macro ‘PLURAL_PARSE’
> plural.c:185:5: note: in expansion of macro ‘__gettextparse’
>
> - - - - - -
> This sequence was found to WORK:
>
> ./autogen.sh && ./configure && make
> make distcheck
> ./autogen.sh && ./configure && make
> make distcheck
>
> ==> Yes, that's double the work, but the second 'make distcheck'
> completes.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/geda-project/+bug/1496105/+subscriptions
>

Revision history for this message
Chad Parker (parker-charles) wrote :

P.S. I tried with version 0.19.3 first (because it came with Debian, it
works), skipped 0.19 because the release date was basically the same, and
went to 0.18 and that didn't work. I didn't try any of the intermediates
though. I suppose I could go back and try to find the first minor version
that works, but I think it's also dependent on what version of bison is
installed, so, it might not be the same for different systems.

On Jan 7, 2017 6:44 PM, "Dan McMahill" <email address hidden> wrote:

By "upgrade gettext", do you just mean bump the minimum required in
autogen.sh from 0.14 to 0.18 or 0.19? Do we need to change anything
else? If that is all we need to do then sure, lets bump it up but
perhaps we can use the minimum version we actually need.

The reason for the old maintainer mode stuff was to try and minimize
extra tools users needed to build.

I'd assume the reason for the with included gettext bit is for helping
reduce dependencies on external libs.

--
You received this bug notification because you are subscribed to the bug
report.
https://bugs.launchpad.net/bugs/1496105

Title:
  The maintainer mode mess.

Status in gEDA project:
  Confirmed
Status in pcb:
  Confirmed

Bug description:
  Let me open a bug to track this. Also to allow a LPxxx branch in the
  repo.

  4 weeks ago I removed AM_MAINTAINER_MODE, because this prohibited
  rebuilding some files, e.g. parse_y.c on source changes.

  Today I removed all files not coming with Git. Many of them manually,
  because not catched by a 'make maintainer-clean'. Since this cleaning,
  a 'make distcheck' fails entirely. The same worked before.

  A regular build ('./autogen.sh && ./configure && make') still works.

  - - - - - -
  To be more precise, this does not work:

  ./autogen.sh && ./configure && make
  make distcheck

  It fails with
  [... deliberately cut off ...]ter-statement ../../intl/plural.c
  In file included from plural.y:35:0:
  ../../intl/plural-exp.h:94:23: error: conflicting types for
‘libintl_gettextparse’
   # define PLURAL_PARSE libintl_gettextparse
                         ^
  plural.y:40:25: note: in expansion of macro ‘PLURAL_PARSE’
  plural.c:185:5: note: in expansion of macro ‘__gettextparse’

  - - - - - -
  This sequence was found to WORK:

  ./autogen.sh && ./configure && make
  make distcheck
  ./autogen.sh && ./configure && make
  make distcheck

  ==> Yes, that's double the work, but the second 'make distcheck'
  completes.

To manage notifications about this bug go to:
https://bugs.launchpad.net/geda-project/+bug/1496105/+subscriptions

Changed in pcb:
status: Confirmed → Fix Committed
Changed in pcb:
status: Fix Committed → Fix Released
Changed in geda-project:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.