Note that there are some explanatory texts on larger screens.

plurals
  1. POUndefined references in building code from IPOL with libpng
    primarykey
    data
    text
    <p>I am trying to compile the code which is available online <a href="http://www.ipol.im/pub/art/2011/bcm_nlm/" rel="nofollow">Non-Local Means Denoising</a></p> <p>When I compile the source, the following errors appear that I suppose are mainly due to <code>libpng</code>:</p> <pre><code> g++ -L/opt/local/lib/ -L/usr/local/lib/ -L/usr/lib/x86_64-linux-gnu/ -fopenmp -lpng -o nlmeans_ipol nlmeans_ipol.o io_png.o libauxiliar.o libdenoising.o mt19937ar.o io_png.o: In function `io_png_write_raw': io_png.c:(.text+0xe0): undefined reference to `png_create_write_struct' io_png.c:(.text+0xf6): undefined reference to `png_create_info_struct' io_png.c:(.text+0x12b): undefined reference to `png_init_io' io_png.c:(.text+0x194): undefined reference to `png_set_IHDR' io_png.c:(.text+0x1a6): undefined reference to `png_write_info' io_png.c:(.text+0xb36): undefined reference to `png_write_image' io_png.c:(.text+0xb48): undefined reference to `png_write_end' io_png.c:(.text+0xb62): undefined reference to `png_destroy_write_struct' io_png.c:(.text+0xbcc): undefined reference to `png_destroy_write_struct' io_png.c:(.text+0xc1f): undefined reference to `png_destroy_read_struct' io_png.c:(.text+0xe6a): undefined reference to `png_destroy_write_struct' io_png.c:(.text+0xe80): undefined reference to `png_destroy_write_struct' </code></pre> <p>I have followed the following threads and placed the file "libpng.a" at many locations but it does not help.</p> <p>I have seen a similar <a href="http://sourceforge.net/p/pngwriter/discussion/237442/thread/6e394eca/" rel="nofollow">libpng problem here</a> but does not help.</p> <p>I am using ubuntu 12.04.</p> <p>Could anyone please tell what could actually go wrong?</p> <p><strong>EDIT 1</strong> The complete call is as follows</p> <pre><code> g++ -O3 -funroll-loops -fomit-frame-pointer -fno-tree-pre -falign-loops -ffast-math -ftree-vectorize -Wall -Wextra -Wno-write-strings -Wno-deprecated -ansi -fopenmp -c -o nlmeans_ipol.o nlmeans_ipol.cpp cc -c -o io_png.o io_png.c -O3 -funroll-loops -fomit-frame-pointer -fno-tree-pre -falign-loops -ffast-math -ftree-vectorize -Wall -Wextra -Wno-write-strings -ansi -I/opt/local/include/ -I/usr/local/include/ g++ -c -o libauxiliar.o libauxiliar.cpp -O3 -funroll-loops -fomit-frame-pointer -fno-tree-pre -falign-loops -ffast-math -ftree-vectorize -Wall -Wextra -Wno-write-strings -Wno-deprecated -ansi -fopenmp -I/opt/local/include/ -I/usr/local/include/ g++ -c -o libdenoising.o libdenoising.cpp -O3 -funroll-loops -fomit-frame-pointer -fno-tree-pre -falign-loops -ffast-math -ftree-vectorize -Wall -Wextra -Wno-write-strings -Wno-deprecated -ansi -fopenmp -I/opt/local/include/ -I/usr/local/include/ cc -c -o mt19937ar.o mt19937ar.c -O3 -funroll-loops -fomit-frame-pointer -fno-tree-pre -falign-loops -ffast-math -ftree-vectorize -Wall -Wextra -Wno-write-strings -ansi -I/opt/local/include/ -I/usr/local/include/ g++ -lpng -lm -fopenmp -L/opt/local/lib/ -L/usr/local/lib/ -L/usr/lib/ -L/usr/lib/x86_64-linux-gnu/ -fopenmp -lpng -lpngwriter -lz -lfreetype -o nlmeans_ipol nlmeans_ipol.o io_png.o libauxiliar.o libdenoising.o mt19937ar.o </code></pre> <p>this is the complete call. Its a make file, The dump above in the copy of what appears at the command prompt.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload