QT Creator cannot run any of examples
I just installed QT SDK and first thing I did is check “Demos and Examples” but on EVERY “Run” I get some errors. They’re most like this:
- /usr/bin/ld: warning: libpng12.so.0, needed by /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so, not found (try using -rpath or -rpath-link)
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_gAMA@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_PLTE@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_text@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_write_rows@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_invert_mono@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_error_fn@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_image_width@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_sig_bytes@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_read_update_info@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_write_fn@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_create_read_struct@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_gray_to_rgb@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_channels@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_strip_16@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_expand@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_create_write_struct@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_write_info@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_PLTE@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_destroy_write_struct@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_image_height@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_y_pixels_per_meter@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_compression_level@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_get_x_pixels_per_meter@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_gamma@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_destroy_read_struct@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_read_end@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_packswap@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_sBIT@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_write_image@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_tRNS@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_create_info_struct@PNG12_0'
- /home/broi/QtSDK/Simulator/Qt/gcc/lib/libQtGui.so: undefined reference to `png_set_bgr@PNG12_0'
- collect2: ld returned 1 exit status
- make: *** [annotatedurl] Error 1
- make: Leaving directory `/home/broi/QtSDK/Examples/QtMobility/annotatedurl-build-simulator-Simulator_Qt_for_GCC__Qt_SDK__Release'
- 19:56:28: The process "/usr/bin/make" exited with code 2.
- When executing build step 'Make'
I have libpng installed.
I’m using Linux 32bit
7 replies
Hope this helps:
http://doc.qt.nokia.com/4.7-snapshot/requirements-x11.html
Run ldd on the library and find out whether any libraries are missing.
If so: Install them (including the development packages!) and/or set LD_LIBRARY_PATH to point to the directories containing the .so files needed.
If all libraries are found: The png shipped with your distribution is too old (or new, IIRC there was a binary breakage in libPNG recently) and you will need to build Qt yourself to fix this. You can also try to get Qt from your distributor, they should have one that works for their system.
You must log in to post a reply. Not a member yet? Register here!


