swesterfeld / liquidsfz

SFZ Sampler
Mozilla Public License 2.0
87 stars 12 forks source link

0.2.1 fails to configure: automake: error: undefined condition 'TRUE' for 'RECURSIVE_TARGETS' #15

Closed yurivict closed 4 years ago

yurivict commented 4 years ago
===>  Configuring for liquidsfz-0.2.1
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'build-aux'.
libtoolize: copying file 'build-aux/ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
configure.ac:9: installing 'build-aux/compile'
configure.ac:9: installing 'build-aux/config.guess'
configure.ac:9: installing 'build-aux/config.sub'
configure.ac:6: installing 'build-aux/install-sh'
configure.ac:6: installing 'build-aux/missing'
Makefile.am:22: error: unterminated conditionals: COND_WITH_LV2_TRUE
Makefile.am:9: warning: SUBDIRS was already defined in condition TRUE, which includes condition COND_WITH_LV2 ...
Makefile.am:1: ... 'SUBDIRS' previously defined here
Makefile.am:11: warning: 'AUTOMAKE_OPTIONS' cannot have conditional contents
automake: error: undefined condition 'TRUE' for 'RECURSIVE_TARGETS'
automake: RECURSIVE_TARGETS: 
automake:   {
automake:     COND_WITH_LV2 => {
automake:       type: +=
automake:       where: /usr/local/share/automake-1.16/am/texinfos.am:
automake:       comment: 
automake:       value: dvi-recursive html-recursive info-recursive pdf-recursive ps-recursive \
automake:   install-dvi-recursive \
automake:   install-html-recursive \
automake:   install-info-recursive \
automake:   install-pdf-recursive \
automake:   install-ps-recursive all-recursive check-recursive installcheck-recursive
automake:       owner: Automake
automake:     }
automake:   }
automake: 
automake: Please contact <bug-automake@gnu.org>.
 at /usr/local/share/automake-1.16/Automake/Channels.pm line 662.
    Automake::Channels::msg("automake", "", "undefined condition 'TRUE' for 'RECURSIVE_TARGETS'\x{a}RECURSIVE_"...) called at /usr/local/share/automake-1.16/Automake/ChannelDefs.pm line 212
    Automake::ChannelDefs::prog_error("undefined condition 'TRUE' for 'RECURSIVE_TARGETS'\x{a}RECURSIVE_"...) called at /usr/local/share/automake-1.16/Automake/Item.pm line 95
    Automake::Item::rdef(Automake::Variable=HASH(0x801d28168), Automake::Condition=HASH(0x8016e8348)) called at /usr/local/bin/automake line 3969
    Automake::handle_subdirs() called at /usr/local/bin/automake line 7951
    Automake::generate_makefile("Makefile.am", "Makefile.in") called at /usr/local/bin/automake line 8229
    Automake::handle_makefile("Makefile.in") called at /usr/local/bin/automake line 8241
    Automake::handle_makefiles_serial() called at /usr/local/bin/automake line 8373
autoreconf-2.69: automake failed with exit status: 255
*** Error code 1

FreeBSD 12.2 autoconf-2.69_3 autoconf-wrapper-20131203 automake-1.16.2

swesterfeld commented 4 years ago

How can I reproduce this? I have a Freebsd 12.2-RC2 VM here now. I tried both:

I saw that the code doesn't build though, so besides configure there there are further portability issues to fix before it will build on FreeBSD.

yurivict commented 4 years ago

To reproduce:

swesterfeld commented 4 years ago

Ok, I can reproduce this, but I don't fully understand what the problem is. It seems to be all about the toplevel Makefile.am. My Makefile.am from git contains

SUBDIRS = lib tests

if COND_WITH_JACK
SUBDIRS += src
endif

if COND_WITH_LV2
SUBDIRS += lv2
endif
[...]

Now the work/liquidsfz-0.2.1 contains this Makefile.am under the name Makefile.am.orig. But the new Makefile.am is now:

SUBDIRS = lib tests

if COND_WITH_JACK
SUBDIRS += src
endif

if COND_WITH_LV2
SUBDIRS += lv2
SUBDIRS = lib src lv2
[...]

This doesn't work (note the missing endif), and this is not the Makefile.am I provided (which works if you call autogen.sh on a git checkout from my github repo). All that ports packaging via Makefile is nice, but there must be a magic step somewhere that I don't see that replaces my Makefile.am with a broken one.

yurivict commented 4 years ago

Thanks for your troubleshooting. This is a patch failure https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=250511 The patch files/patch-Makefile.am needs to be removed or regenerated.

Now it fails like this:

libtool:   error: CURRENT '' must be a nonnegative integer
libtool:   error: ':0.2.1:0' is not valid version information
swesterfeld commented 4 years ago

It seems that the sed expression I used for splitting "0.2.1" into 0, 2 and 1 didn't work with FreeBSD sed. I've replaced this with cut which works on FreeBSD and Linux. https://github.com/swesterfeld/liquidsfz/commit/18e59d6784f32e4d9c25c0f8ccbc9e7d9cd4c865

I also added the include for voice.cc: https://github.com/swesterfeld/liquidsfz/commit/217b71d4d8e931e8dd4954a3b1e1e58d8cb5f585

yurivict commented 4 years ago

It builds now. Thank you!