-
Notifications
You must be signed in to change notification settings - Fork 185
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compilation error in gcc vorbis-master/examples/encoder_example.c #1
Comments
Can you provide the commands that you used for compiling? Also, your platform? |
I am using Linux ubuntu 14.04. |
Please read the README file for building instructions. Also, note that Ubuntu 14.04 includes Vorbis. You may want to use the distribution package. |
After reading README file, I even setup up the svn repository and compiled the encoder_example.c code. |
I want to know how encoder_example works? My work is to write a 16-bit PCM data buffer to a ogg file. |
Please follow the directions in the README:
Then switch to the examples directory, and type By the way, you may want to use libvorbisfile, as it has a much easier API than libvorbis. See the vorbisfile_example.c file. |
I am getting the below error when executing command make in the example directory. |
Something is wrong with your libogg installation. Did you install it from source? On ubuntu, you can install libogg with |
No. I installed libogg0 and libogg-dev packages. But still the problem persist. |
After you install |
yeah. I tried to run ./configure again but still I am facing with the error. |
I did the following steps, but still the problem persists.
At step 7, I am getting the below error. Please help me in getting this work done. |
Okay, so the problem is t hat the build system is not linking in libogg when it should. -logg should have been automatically put on the command line, here's mine:
I cannot figure out how the -logg is being added in my Makefile. I don't know how this ever worked at all. Maybe an autotools wizard can help. |
Ah, I forgot that -logg is added automatically by libtool. Can you paste your config.log from the root vorbis directory? |
This file contains any messages produced by compilers while It was created by libvorbis configure 1.3.5, which was $ ./configure --enable-maintainer-mode ---------Platform.---------hostname = arunbalaji-VPCEA33EN /usr/bin/uname -p = unknown /bin/arch = unknown PATH: /home/arunbalaji/Downloads/google_appengine/google/yes/google-cloud-sdk/bin -----------Core tests.-----------configure:2357: checking build system type configure:3418: $? = 0 ----------------------Running config.status.----------------------This file was extended by libvorbis config.status 1.3.5, which was CONFIG_FILES = on arunbalaji-VPCEA33EN config.status:1143: creating Makefile ----------------Cache variables.----------------ac_cv_build=x86_64-unknown-linux-gnu -----------------Output variables.-----------------ACLOCAL='${SHELL} /home/arunbalaji/vorbis_svn/missing aclocal-1.14' -----------confdefs.h.-----------/* confdefs.h */ configure: exit 0 |
Can you test this patch and see if it solves your problem? You will need to run ./autogen.sh and ./configure again. |
I tried testing the patch but it never solves the problem. |
@arun09e902 tdaede's fix should have resolved your issue. Can you try:
|
Closing presumed fixed. Please re-open if you're still having this issue. |
Did this ever get resolved 5 yrs ago? |
I started getting this error in Debian for a software that used to build, without changing the software (but libvorbis probably was upgraded): |
Ah, |
That would explain it. Glad you figured it out! |
You need both
|
/tmp/ccFY2ZX4.o: In function
main': encoder_example.c:(.text+0xe7): undefined reference to
vorbis_info_init'encoder_example.c:(.text+0x108): undefined reference to
vorbis_encode_init_vbr' encoder_example.c:(.text+0x130): undefined reference to
vorbis_comment_init'encoder_example.c:(.text+0x149): undefined reference to
vorbis_comment_add_tag' encoder_example.c:(.text+0x162): undefined reference to
vorbis_analysis_init'encoder_example.c:(.text+0x17b): undefined reference to
vorbis_block_init' encoder_example.c:(.text+0x1a4): undefined reference to
ogg_stream_init'encoder_example.c:(.text+0x1d2): undefined reference to
vorbis_analysis_headerout' encoder_example.c:(.text+0x1eb): undefined reference to
ogg_stream_packetin'encoder_example.c:(.text+0x204): undefined reference to
ogg_stream_packetin' encoder_example.c:(.text+0x21d): undefined reference to
ogg_stream_packetin'encoder_example.c:(.text+0x238): undefined reference to
ogg_stream_flush' encoder_example.c:(.text+0x2e4): undefined reference to
vorbis_analysis_wrote'encoder_example.c:(.text+0x2fd): undefined reference to
vorbis_analysis_buffer' encoder_example.c:(.text+0x429): undefined reference to
vorbis_analysis_wrote'encoder_example.c:(.text+0x442): undefined reference to
vorbis_analysis' encoder_example.c:(.text+0x451): undefined reference to
vorbis_bitrate_addblock'encoder_example.c:(.text+0x46f): undefined reference to
ogg_stream_packetin' encoder_example.c:(.text+0x48d): undefined reference to
ogg_stream_pageout'encoder_example.c:(.text+0x4f7): undefined reference to
ogg_page_eos' encoder_example.c:(.text+0x52b): undefined reference to
vorbis_bitrate_flushpacket'encoder_example.c:(.text+0x54c): undefined reference to
vorbis_analysis_blockout' encoder_example.c:(.text+0x571): undefined reference to
ogg_stream_clear'encoder_example.c:(.text+0x580): undefined reference to
vorbis_block_clear' encoder_example.c:(.text+0x58f): undefined reference to
vorbis_dsp_clear'encoder_example.c:(.text+0x59e): undefined reference to
vorbis_comment_clear' encoder_example.c:(.text+0x5ad): undefined reference to
vorbis_info_clear'collect2: error: ld returned 1 exit status
The text was updated successfully, but these errors were encountered: