sox-devel@lists.sourceforge.net unofficial mirror
 help / color / mirror / code / Atom feed
From: "Måns Rullgård" <mans@mansr.com>
To: Jan Stary <hans@stare.cz>
Cc: sox-devel@lists.sourceforge.net
Subject: Re: Build system cleanup
Date: Fri, 21 Aug 2020 14:32:29 +0100	[thread overview]
Message-ID: <yw1xo8n4nmz6.fsf@mansr.com> (raw)
In-Reply-To: <20200821124953.GC81576@www.stare.cz> (Jan Stary's message of "Fri, 21 Aug 2020 14:49:53 +0200")

Jan Stary <hans@stare.cz> writes:

> On Aug 21 11:33:08, mans@mansr.com wrote:
>> Jan Stary <hans@stare.cz> writes:
>> 
>> >> Testing on OpenBSD 6.7-current/amd64.
>> >> It eventually fails with lpc10.h not being found.
>> >> Full log below, comments inline.
>> >
>> > Trying agsin with ./configure --prefix=$HOME --disable-lpc10
>> > to make it finosh without the lpc10 fail. Mysteriously,
>> > it fails with standard C funcrtions not bewing found
>> 
>> I installed OpenBSD in a VM and noticed the same thing.  It seems to
>> have something to do with linking shared libraries.  Is OpenBSD doing
>> something bizarre there?
>
> Full log attached; these is the failing line
> (can we please make make V=1 the default,
> so that the actual commands can be seen?)

No.  That makes warnings almost impossible to notice.  It's easy enough
to add V=1 (it's THREE characters) on those rare occasions where the
command is interesting.  You can set it in your own environment if you
want.

> libtool: link: gcc -shared  -fPIC -DPIC -o .libs/libsox.so.3.0	.libs/libsox_la-adpcms.o .libs/libsox_la-aiff.o .libs/libsox_la-cvsd.o .libs/libsox_la-g711.o .libs/libsox_la-g721.o .libs/libsox_la-g723_24.o .libs/libsox_la-g723_40.o .libs/libsox_la-g72x.o .libs/libsox_la-vox.o .libs/libsox_la-raw.o .libs/libsox_la-formats.o .libs/libsox_la-formats_i.o .libs/libsox_la-skelform.o .libs/libsox_la-xmalloc.o .libs/libsox_la-getopt.o .libs/libsox_la-util.o .libs/libsox_la-libsox.o .libs/libsox_la-libsox_i.o .libs/libsox_la-sox-fmt.o .libs/libsox_la-bend.o .libs/libsox_la-biquad.o .libs/libsox_la-biquads.o .libs/libsox_la-chorus.o .libs/libsox_la-compand.o .libs/libsox_la-compandt.o .libs/libsox_la-contrast.o .libs/libsox_la-dcshift.o .libs/libsox_la-delay.o .libs/libsox_la-dft_filter.o .libs/libsox_la-dither.o .libs/libsox_la-divide.o .libs/libsox_la-downsample.o .libs/libsox_la-earwax.o .libs/libsox_la-echo.o .libs/libsox_la-echos.o .libs/libsox_la-effects.o .libs/libsox_la-effects_i.o .libs/libsox_la-effects_i_dsp.o .libs/libsox_la-fade.o .libs/libsox_la-fft4g.o .libs/libsox_la-fir.o .libs/libsox_la-firfit.o .libs/libsox_la-flanger.o .libs/libsox_la-gain.o .libs/libsox_la-hilbert.o .libs/libsox_la-input.o .libs/libsox_la-ladspa.o .libs/libsox_la-loudness.o .libs/libsox_la-mcompand.o .libs/libsox_la-noiseprof.o .libs/libsox_la-noisered.o .libs/libsox_la-output.o .libs/libsox_la-overdrive.o .libs/libsox_la-pad.o .libs/libsox_la-phaser.o .libs/libsox_la-rate.o .libs/libsox_la-remix.o .libs/libsox_la-repeat.o .libs/libsox_la-reverb.o .libs/libsox_la-reverse.o .libs/libsox_la-silence.o .libs/libsox_la-sinc.o .libs/libsox_la-skeleff.o .libs/libsox_la-speed.o .libs/libsox_la-splice.o .libs/libsox_la-stat.o .libs/libsox_la-stats.o .libs/libsox_la-stretch.o .libs/libsox_la-swap.o .libs/libsox_la-synth.o .libs/libsox_la-tempo.o .libs/libsox_la-tremolo.o .libs/libsox_la-trim.o .libs/libsox_la-upsample.o .libs/libsox_la-vad.o .libs/libsox_la-vol.o .libs/libsox_la-raw-fmt.o .libs/libsox_la-s1-fmt.o .libs/libsox_la-s2-fmt.o .libs/libsox_la-s3-fmt.o .libs/libsox_la-s4-fmt.o .libs/libsox_la-u1-fmt.o .libs/libsox_la-u2-fmt.o .libs/libsox_la-u3-fmt.o .libs/libsox_la-u4-fmt.o .libs/libsox_la-al-fmt.o .libs/libsox_la-la-fmt.o .libs/libsox_la-ul-fmt.o .libs/libsox_la-lu-fmt.o .libs/libsox_la-8svx.o .libs/libsox_la-aiff-fmt.o .libs/libsox_la-aifc-fmt.o .libs/libsox_la-au.o .libs/libsox_la-avr.o .libs/libsox_la-cdr.o .libs/libsox_la-cvsd-fmt.o .libs/libsox_la-dvms-fmt.o .libs/libsox_la-dat.o .libs/libsox_la-hcom.o .libs/libsox_la-htk.o .libs/libsox_la-maud.o .libs/libsox_la-prc.o .libs/libsox_la-sf.o .libs/libsox_la-smp.o .libs/libsox_la-sounder.o .libs/libsox_la-soundtool.o .libs/libsox_la-sphere.o .libs/libsox_la-tx16w.o .libs/libsox_la-voc.o .libs/libsox_la-vox-fmt.o .libs/libsox_la-ima-fmt.o .libs/libsox_la-adpcm.o .libs/libsox_la-ima_rw.o .libs/libsox_la-wav.o .libs/libsox_la-wve.o .libs/libsox_la-xa.o .libs/libsox_la-nulfile.o .libs/libsox_la-f4-fmt.o .libs/libsox_la-f8-fmt.o .libs/libsox_la-gsrt.o .libs/libsox_la-flac.o .libs/libsox_la-opus.o .libs/libsox_la-sndio.o .libs/libsox_la-vorbis.o	  -L/usr/local/lib -lFLAC -lopusfile -lopus -lsndio -lvorbisenc -lvorbisfile -lvorbis -logg -lm	 -O2 -Wl,-z -Wl,defs -Wl,--as-needed   -Wl,-retain-symbols-file,.libs/libsox.exp
> ld: error: undefined symbol: free
> ld: error: undefined symbol: sprintf
> [etc]
>
> When I drop the "-Wl,-z -Wl,defs" from that line,
> the "gcc -shared" command goes through as expected,
> producing libsox.so

Apparently OpenBSD shared libraries aren't linked with libc.  That's a
quirk I haven't noticed before.

The simplest solution here is probably to just drop the -z defs option.
It doesn't actually do anything useful if everything is as it should.
What it does is prevent the link succeeding if something is accidentally
left unresolved.  This can be useful when working on something, but it's
not really worth the effort of trying to figure out when it's safe to use.

-- 
Måns Rullgård


_______________________________________________
SoX-devel mailing list
SoX-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-devel

  parent reply	other threads:[~2020-08-21 13:33 UTC|newest]

Thread overview: 89+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-19 20:40 Build system cleanup Måns Rullgård
2020-08-20 20:40 ` Wolfgang Stoeggl via SoX-devel
2020-08-20 21:22   ` Måns Rullgård
2020-08-20 22:15     ` Wolfgang Stoeggl via SoX-devel
2020-08-21  8:24     ` Jan Stary
2020-08-21  8:16 ` Jan Stary
2020-08-21  8:31   ` Jan Stary
2020-08-21 10:28     ` Måns Rullgård
2020-08-21 12:24       ` Jan Stary
2020-08-21 12:46         ` Måns Rullgård
2020-08-21  8:49   ` Jan Stary
2020-08-21 10:33     ` Måns Rullgård
2020-08-21 12:49       ` Jan Stary
2020-08-21 12:50         ` Jan Stary
2020-08-21 13:32         ` Måns Rullgård [this message]
2020-08-21 14:09         ` Jan Stary
2020-08-21 11:15   ` Måns Rullgård
2020-08-21 14:04     ` Jan Stary
2020-08-21 14:47       ` Måns Rullgård
2020-08-21 19:26       ` Wolfgang Stoeggl
2020-08-21 20:20       ` Jan Stary
2020-08-21 15:16   ` Jan Stary
2020-08-21 15:21     ` Jan Stary
2020-08-21 17:08       ` Måns Rullgård
2020-08-21 17:43         ` Jan Stary
2020-08-21 17:52           ` Måns Rullgård
2020-08-21 17:57             ` Jan Stary
2020-08-21 20:17             ` Jan Stary
2020-08-21 20:45               ` Jan Stary
2020-08-21 21:43                 ` Måns Rullgård
2020-08-22  8:17                   ` Jan Stary
2020-08-22 10:10                     ` Måns Rullgård
2020-08-22 15:35                       ` Jan Stary
2020-08-22 15:44                         ` Jan Stary
2020-08-22 20:54                         ` Måns Rullgård
2020-08-23 14:07                           ` Jan Stary
2020-08-23 17:13                             ` Måns Rullgård
2020-08-23 19:46                               ` Jan Stary
2020-08-24 11:04                                 ` Måns Rullgård
2020-08-24 11:19                                   ` Jan Stary
2020-08-27  9:38                                     ` Jan Stary
2020-08-27 10:53                                       ` Måns Rullgård
2020-08-23 21:55                               ` Jan Stary
2020-08-24  6:56                                 ` Jan Stary
2020-08-27  9:40                                   ` Jan Stary
2020-08-27 11:08                                     ` Måns Rullgård
2020-08-27 11:37                                       ` Jan Stary
2020-08-27 11:53                                         ` Måns Rullgård
2020-08-27 13:05                                     ` Jan Stary
2020-08-27 13:31                                       ` Måns Rullgård
2020-08-27 14:10                                         ` Jan Stary
2020-08-27 14:38                                           ` Jan Stary
2020-08-27 15:11                                         ` Måns Rullgård
2020-08-27 17:41                                           ` Jan Stary
2020-08-27 18:50                                             ` Måns Rullgård
2020-08-27 19:18                                               ` Jan Stary
2020-08-28  4:54                                                 ` Jan Stary
2020-08-28  9:13                                                 ` Måns Rullgård
2020-08-24 12:19                                 ` Måns Rullgård
2020-08-24 14:43                                   ` Jan Stary
2020-08-24 14:59                                     ` Måns Rullgård
2020-08-27  9:44                                       ` Jan Stary
2020-08-27 11:08                                         ` Måns Rullgård
2020-08-24 17:22                                     ` Måns Rullgård
2020-08-22 15:43                     ` Jan Stary
2020-08-22 15:48                       ` Jan Stary
2020-08-24 12:18                   ` Jan Stary
2020-08-24 12:27                     ` Måns Rullgård
2020-08-24 13:16                       ` Jan Stary
2020-08-24 14:15                         ` Måns Rullgård
2020-08-27  9:52                           ` Jan Stary
2020-08-27 11:10                             ` Måns Rullgård
  -- strict thread matches above, loose matches on Subject: below --
2020-08-21  8:52 Jan Stary
2020-08-21 10:36 ` Måns Rullgård
2020-08-21 12:22   ` Jan Stary
2020-08-21 12:27     ` Måns Rullgård
2020-08-27  9:21 Jan Stary
2020-08-27 10:54 ` Jan Stary
2020-08-27 11:52 ` Måns Rullgård
2020-08-27 12:40   ` Jan Stary
2020-08-27 12:44     ` Jan Stary
2020-08-27 12:45     ` Måns Rullgård
2020-08-27 17:45 ` Jan Stary
2020-08-27 18:59   ` Måns Rullgård
2020-08-27 19:51     ` Jan Stary
2020-08-27 20:01 ` Jan Stary
2020-08-28  9:21   ` Måns Rullgård
2020-08-28  9:35     ` Jan Stary
2020-08-28  9:43       ` Måns Rullgård

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://lists.sourceforge.net/lists/listinfo/sox-devel

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=yw1xo8n4nmz6.fsf@mansr.com \
    --to=sox-devel@lists.sourceforge.net \
    --cc=hans@stare.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/sox.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).