Discussion:
[Audacity-devel] Getting stuck building on Linux
Gale Andrews
2017-07-15 16:43:01 UTC
Permalink
Ubuntu 14.04.

I use default

./configure CXXFLAGS="-std=gnu++11"

Even on a fresh checkout, running make I get stuck on the following

audacity-AudioIO.o: In function `AudioIO::MidiTime()':
/home/gale/audacityHEAD/audacity/src/AudioIO.cpp:3984: undefined
reference to `PaUtil_GetTime'
collect2: error: ld returned 1 exit status
make[2]: *** [audacity] Error 1
make[2]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make: *** [all-recursive] Error 1

Can anyone give some pointers how to get round this?

Thank you.


Gale
Paul Licameli
2017-07-15 16:49:33 UTC
Permalink
Post by Gale Andrews
Ubuntu 14.04.
I use default
./configure CXXFLAGS="-std=gnu++11"
Even on a fresh checkout, running make I get stuck on the following
/home/gale/audacityHEAD/audacity/src/AudioIO.cpp:3984: undefined
reference to `PaUtil_GetTime'
collect2: error: ld returned 1 exit status
make[2]: *** [audacity] Error 1
make[2]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make: *** [all-recursive] Error 1
Can anyone give some pointers how to get round this?
Thank you.
Gale
A link, not a compilation error.

Can you help us, Poke?

PRL
Post by Gale Andrews
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Paul Licameli
2017-07-15 17:34:32 UTC
Permalink
I think I see the problem, see commit
38fd97b8e26060332ab3e9e000a8882326a70ba7

This touches lib-src. Can we put this small change upstream? Roger?

I think the problem is that you can compile portaudio either as C or as
C++, and if as C, then your build is fine, but if as C++, then the missing
function was not given "C" linkage agreeing with the header file.

Or the other way to fix it is to make sure the makefiles always compile
with C not C++.

PRL


On Sat, Jul 15, 2017 at 1:19 PM, Pokechu22 <
I've seen this before, and it's an odd one. It happens on some machines
but not others.
Midi synchronization uses PaUtil_GetTime, which isn't part of portaudio's
public API but instead is one of the methods declared in pa_util.h
<http://portaudio.com/docs/v19-doxydocs-dev/pa__util_8h.html>. On some
machines, this is still fine, but on others it doesn't link. I'm not sure
why. In both cases, the method seems to be present in the binary: My pi
has it as "000000c0 T PaUtil_GetTime" in pa_unix_util.o and my main
computer, via windows subsystem for Linux, has it as "00000000000000f0 T
PaUtil_GetTime" also in pa_unix_util.o. So I don't get why it links on my
computer but not my pi, and it's not something that I can easily test
because compiling on my pi takes a very long time.
--Poke
Post by Paul Licameli
Post by Gale Andrews
Ubuntu 14.04.
I use default
./configure CXXFLAGS="-std=gnu++11"
Even on a fresh checkout, running make I get stuck on the following
/home/gale/audacityHEAD/audacity/src/AudioIO.cpp:3984: undefined
reference to `PaUtil_GetTime'
collect2: error: ld returned 1 exit status
make[2]: *** [audacity] Error 1
make[2]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make: *** [all-recursive] Error 1
Can anyone give some pointers how to get round this?
Thank you.
Gale
A link, not a compilation error.
Can you help us, Poke?
PRL
Post by Gale Andrews
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Paul Licameli
2017-07-15 17:37:27 UTC
Permalink
What I did may be the minimal fix for the Audacity build, but the correct
fix for portaudio upstream might enlarge the extern "C" block to include
other functions declared "C" but not used by Audacity.

PRL
I think I see the problem, see commit 38fd97b8e26060332ab3e9e000a888
2326a70ba7
This touches lib-src. Can we put this small change upstream? Roger?
I think the problem is that you can compile portaudio either as C or as
C++, and if as C, then your build is fine, but if as C++, then the missing
function was not given "C" linkage agreeing with the header file.
Or the other way to fix it is to make sure the makefiles always compile
with C not C++.
PRL
I've seen this before, and it's an odd one. It happens on some machines
but not others.
Midi synchronization uses PaUtil_GetTime, which isn't part of portaudio's
public API but instead is one of the methods declared in pa_util.h
<http://portaudio.com/docs/v19-doxydocs-dev/pa__util_8h.html>. On some
machines, this is still fine, but on others it doesn't link. I'm not sure
why. In both cases, the method seems to be present in the binary: My pi
has it as "000000c0 T PaUtil_GetTime" in pa_unix_util.o and my main
computer, via windows subsystem for Linux, has it as "00000000000000f0 T
PaUtil_GetTime" also in pa_unix_util.o. So I don't get why it links on my
computer but not my pi, and it's not something that I can easily test
because compiling on my pi takes a very long time.
--Poke
Post by Paul Licameli
Post by Gale Andrews
Ubuntu 14.04.
I use default
./configure CXXFLAGS="-std=gnu++11"
Even on a fresh checkout, running make I get stuck on the following
/home/gale/audacityHEAD/audacity/src/AudioIO.cpp:3984: undefined
reference to `PaUtil_GetTime'
collect2: error: ld returned 1 exit status
make[2]: *** [audacity] Error 1
make[2]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make: *** [all-recursive] Error 1
Can anyone give some pointers how to get round this?
Thank you.
Gale
A link, not a compilation error.
Can you help us, Poke?
PRL
Post by Gale Andrews
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Gale Andrews
2017-07-15 22:06:59 UTC
Permalink
On 15 July 2017 at 21:28, Pokechu22
That fixes building on my pi. Though, if the system version of portaudio is
used, it probably won't make a difference; probably the m4 checklib file for
portaudio needs to be changed to check if the system version is usable,
which I can try to do. In the mean time, using ./configure
CXXFLAGS="-std=gnu++11" --with-portaudio=local should work.
Yes that enables me to link. Thank you.

Having imported a MIDI track I can't play it with the play button (OK
I have not
researched this yet). But no further audio generation or playback/recording
is then possible, as if MIDI playback were still running.

This seems poor, if it is supposed to be like this on Linux.


Gale
--Poke
Post by Paul Licameli
What I did may be the minimal fix for the Audacity build, but the correct
fix for portaudio upstream might enlarge the extern "C" block to include
other functions declared "C" but not used by Audacity.
PRL
Post by Paul Licameli
I think I see the problem, see commit
38fd97b8e26060332ab3e9e000a8882326a70ba7
This touches lib-src. Can we put this small change upstream? Roger?
I think the problem is that you can compile portaudio either as C or as
C++, and if as C, then your build is fine, but if as C++, then the missing
function was not given "C" linkage agreeing with the header file.
Or the other way to fix it is to make sure the makefiles always compile
with C not C++.
PRL
On Sat, Jul 15, 2017 at 1:19 PM, Pokechu22
I've seen this before, and it's an odd one. It happens on some machines
but not others.
Midi synchronization uses PaUtil_GetTime, which isn't part of
portaudio's public API but instead is one of the methods declared in
pa_util.h. On some machines, this is still fine, but on others it doesn't
link. I'm not sure why. In both cases, the method seems to be present in
the binary: My pi has it as "000000c0 T PaUtil_GetTime" in pa_unix_util.o
and my main computer, via windows subsystem for Linux, has it as
"00000000000000f0 T PaUtil_GetTime" also in pa_unix_util.o. So I don't get
why it links on my computer but not my pi, and it's not something that I can
easily test because compiling on my pi takes a very long time.
--Poke
Post by Paul Licameli
Post by Gale Andrews
Ubuntu 14.04.
I use default
./configure CXXFLAGS="-std=gnu++11"
Even on a fresh checkout, running make I get stuck on the following
/home/gale/audacityHEAD/audacity/src/AudioIO.cpp:3984: undefined
reference to `PaUtil_GetTime'
collect2: error: ld returned 1 exit status
make[2]: *** [audacity] Error 1
make[2]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make: *** [all-recursive] Error 1
Can anyone give some pointers how to get round this?
Thank you.
Gale
A link, not a compilation error.
Can you help us, Poke?
PRL
Post by Gale Andrews
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Paul Licameli
2017-07-15 23:13:51 UTC
Permalink
On Sat, Jul 15, 2017 at 6:29 PM, Pokechu22 <
Hm, no; that's not normal. If you don't have any MIDI devices set up, it
should give you a notification of that and cancel playback; you shouldn't
get stuck with playback disabled.
--Poke
Gale does not have all of your work if he builds audacity/master

And that is my fault, for not catching up yet in review and pushing of your
stuff.

Please needle me to do that.

PRL
Post by Gale Andrews
On 15 July 2017 at 21:28, Pokechu22
That fixes building on my pi. Though, if the system version of
portaudio is
used, it probably won't make a difference; probably the m4 checklib
file for
portaudio needs to be changed to check if the system version is usable,
which I can try to do. In the mean time, using ./configure
CXXFLAGS="-std=gnu++11" --with-portaudio=local should work.
Yes that enables me to link. Thank you.
Having imported a MIDI track I can't play it with the play button (OK
I have not
researched this yet). But no further audio generation or
playback/recording
is then possible, as if MIDI playback were still running.
This seems poor, if it is supposed to be like this on Linux.
Gale
--Poke
On Sat, Jul 15, 2017 at 10:37 AM, Paul Licameli <
Post by Paul Licameli
What I did may be the minimal fix for the Audacity build, but the
correct
Post by Paul Licameli
fix for portaudio upstream might enlarge the extern "C" block to
include
Post by Paul Licameli
other functions declared "C" but not used by Audacity.
PRL
On Sat, Jul 15, 2017 at 1:34 PM, Paul Licameli <
Post by Paul Licameli
I think I see the problem, see commit
38fd97b8e26060332ab3e9e000a8882326a70ba7
This touches lib-src. Can we put this small change upstream? Roger?
I think the problem is that you can compile portaudio either as C or
as
Post by Paul Licameli
Post by Paul Licameli
C++, and if as C, then your build is fine, but if as C++, then the
missing
Post by Paul Licameli
Post by Paul Licameli
function was not given "C" linkage agreeing with the header file.
Or the other way to fix it is to make sure the makefiles always
compile
Post by Paul Licameli
Post by Paul Licameli
with C not C++.
PRL
On Sat, Jul 15, 2017 at 1:19 PM, Pokechu22
I've seen this before, and it's an odd one. It happens on some
machines
Post by Paul Licameli
Post by Paul Licameli
but not others.
Midi synchronization uses PaUtil_GetTime, which isn't part of
portaudio's public API but instead is one of the methods declared in
pa_util.h. On some machines, this is still fine, but on others it
doesn't
Post by Paul Licameli
Post by Paul Licameli
link. I'm not sure why. In both cases, the method seems to be
present in
Post by Paul Licameli
Post by Paul Licameli
the binary: My pi has it as "000000c0 T PaUtil_GetTime" in
pa_unix_util.o
Post by Paul Licameli
Post by Paul Licameli
and my main computer, via windows subsystem for Linux, has it as
"00000000000000f0 T PaUtil_GetTime" also in pa_unix_util.o. So I
don't get
Post by Paul Licameli
Post by Paul Licameli
why it links on my computer but not my pi, and it's not something
that I can
Post by Paul Licameli
Post by Paul Licameli
easily test because compiling on my pi takes a very long time.
--Poke
On Sat, Jul 15, 2017 at 9:49 AM, Paul Licameli <
On Sat, Jul 15, 2017 at 12:43 PM, Gale Andrews <
Post by Gale Andrews
Ubuntu 14.04.
I use default
./configure CXXFLAGS="-std=gnu++11"
Even on a fresh checkout, running make I get stuck on the following
/home/gale/audacityHEAD/audacity/src/AudioIO.cpp:3984: undefined
reference to `PaUtil_GetTime'
collect2: error: ld returned 1 exit status
make[2]: *** [audacity] Error 1
make[2]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/gale/audacityHEAD/audacity/src'
make: *** [all-recursive] Error 1
Can anyone give some pointers how to get round this?
Thank you.
Gale
A link, not a compilation error.
Can you help us, Poke?
PRL
Post by Gale Andrews
------------------------------------------------------------
------------------
Post by Paul Licameli
Post by Paul Licameli
Post by Gale Andrews
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Post by Paul Licameli
Post by Paul Licameli
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Post by Paul Licameli
Post by Paul Licameli
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Post by Paul Licameli
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
audacity-devel mailing list
https://lists.sourceforge.net/lists/listinfo/audacity-devel
Loading...