#299 pocketsphinx: programs/Makefile: LIBS need to add -lm

next release
closed
nobody
None
1
2013-12-06
2012-11-10
No

On Ubuntu 12.10:

Building fail on missing math symbols:

/bin/bash ../../libtool --tag=CC --mode=link gcc -g -O2 -Wall -L/home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxad -L/home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxbase -L/home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxbase/.libs -o pocketsphinx_batch batch.o ../../src/libpocketsphinx/libpocketsphinx.la -lsphinxbase
libtool: link: gcc -g -O2 -Wall -o .libs/pocketsphinx_batch batch.o -L/home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxbase/.libs -L/home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxad -L/home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxbase ../../src/libpocketsphinx/.libs/libpocketsphinx.so /home/rngadam/lophilo/sphinx-i686/pocketsphinx/../sphinxbase/src/libsphinxbase/.libs/libsphinxbase.so
../../src/libpocketsphinx/.libs/libpocketsphinx.so: error: undefined reference to 'sqrt'
../../src/libpocketsphinx/.libs/libpocketsphinx.so: error: undefined reference to 'log'
collect2: error: ld returned 1 exit status
make[2]: [pocketsphinx_batch] Error 1
make[2]: Leaving directory /home/rngadam/lophilo/sphinx-i686/pocketsphinx/src/programs' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory/home/rngadam/lophilo/sphinx-i686/pocketsphinx/src'
make:
[all-recursive] Error 1

This is easily remedied by adding -lm to LIBS in pocketsphinx/src/programs/Makefile

...but I have no idea how to modify the build system to do this.

Discussion

  • Nickolay V. Shmyrev

    • status: open --> closed
     
  • Nickolay V. Shmyrev

    Fixed in trunk, thanks for your report

     

Log in to post a comment.