Skip to content

Conversation

tdomhan
Copy link
Contributor

@tdomhan tdomhan commented Jan 20, 2014

Because opencv_highgui depends on libpng, without linking it I get the following errors:

/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_strip_alpha@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_get_io_ptr@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_palette_to_rgb@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_swap@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_write_end@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_compression_level@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_write_image@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_destroy_read_struct@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_write_info@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_gray_to_rgb@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_destroy_write_struct@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_get_IHDR@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_read_update_info@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_compression_strategy@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_create_read_struct@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_read_info@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_longjmp_fn@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_read_image@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_create_write_struct@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_bgr@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_create_info_struct@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_write_fn@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_init_io@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_packing@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_error@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_strip_16@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_read_end@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_IHDR@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_read_fn@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_expand_gray_1_2_4_to_8@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_rgb_to_gray@PNG15_0'
/home/domhant/anaconda/lib/libopencv_highgui.so: undefined reference to `png_set_filter@PNG15_0'

@shelhamer
Copy link
Member

Sorry, I haven't encountered this problem. opencv_highui and opencv_imgproc are our direct dependencies while libpng is not, so for simplicity I might prefer keeping the makefile as it is.

Do you not have libpng in your LD_LIBRARY_PATH?

@tdomhan
Copy link
Contributor Author

tdomhan commented Jan 23, 2014

thanks, setting LD_LIBRARY_PATH properly also does the trick. nvm then ;)

@shelhamer
Copy link
Member

No problem, thanks for raising the issue.

@shelhamer shelhamer closed this Jan 23, 2014
@tdomhan tdomhan deleted the pngdependency branch January 27, 2014 09:32
naibaf7 added a commit that referenced this pull request Aug 26, 2016
[RFC] Improvements to the build system
DVEfremov pushed a commit to DVEfremov/caffe that referenced this pull request Jan 27, 2017
DVEfremov pushed a commit to DVEfremov/caffe that referenced this pull request Jan 27, 2017
DVEfremov pushed a commit to DVEfremov/caffe that referenced this pull request Jan 28, 2017
DVEfremov pushed a commit to DVEfremov/caffe that referenced this pull request Jan 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants