An effort to share my learning at work which revolves around different aspects of computer vision, image processing, robotics.
Showing posts with label Ubuntu. Show all posts
Showing posts with label Ubuntu. Show all posts
Saturday, January 30, 2016
Wednesday, December 2, 2015
Tuesday, November 3, 2015
OpenGL : how to install in Ubuntu 14.04
Check if OpenGL is installed or not:
$glxinfo | grep OpenGL
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce GTX 660/PCIe/SSE2
OpenGL core profile version string: 4.3.0 NVIDIA 352.30
OpenGL core profile shading language version string: 4.30 NVIDIA via Cg compiler
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 4.5.0 NVIDIA 352.30
OpenGL shading language version string: 4.50 NVIDIA
OpenGL context flags: (none)
OpenGL profile mask: (none)
OpenGL extensions:
If you get error:
Install mesa-utils and run the command again.
$sudo apt-get install mesa-utils
$glxinfo | grep OpenGL
Refer:
http://www.codeproject.com/Articles/182109/Setting-up-an-OpenGL-development-environment-in-Ub
When you run the sample code firstWindow.cpp, you may get an error:
$ g++ firstWindow.cpp -lglut
/usr/bin/ld: /tmp/ccT2pQWr.o: undefined reference to symbol 'glClear'
//usr/lib/x86_64-linux-gnu/libGL.so.1: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
solution: add -lGL
$ g++ ./firstWindow.cpp -lGL -lglut
/usr/bin/ld: cannot find -lGL
collect2: error: ld returned 1 exit status
I got error.
Solution: Locate libGL.so and create soft link /usr/lib/libGL.so
$ locate libGL.so
/usr/lib/libGL.so.1
/usr/lib/x86_64-linux-gnu/libGL.so
/usr/lib/x86_64-linux-gnu/libGL.so.1
/usr/lib/x86_64-linux-gnu/libGL.so.352.30
/usr/lib/x86_64-linux-gnu/mesa/libGL.so
/usr/local/MATLAB/R2015a/sys/opengl/lib/glnxa64/libGL.so.1
/usr/local/MATLAB/R2015a/sys/opengl/lib/glnxa64/libGL.so.1.5.070200
$ sudo ln -s /usr/lib/libGL.so.1 /usr/lib/libGL.so
Wednesday, August 5, 2015
take backup of your tabs and bookmarks in firefox
I was excited to figure out that its possible to take backup of my tabs, windows and bookmarks, basically my "profile" in firefox! Why? I usually keep many tabs and windows open, all for separate purpose and never close them... who knows when they will be helpful!
This is the link published by mozilla. The steps are quite simple too :)
https://support.mozilla.org/en-US/kb/back-and-restore-information-firefox-profiles
Enjoy!
This is the link published by mozilla. The steps are quite simple too :)
https://support.mozilla.org/en-US/kb/back-and-restore-information-firefox-profiles
Enjoy!
Monday, May 18, 2015
Link to PASCAL VOC 2007 Dataset
Link where PASCAL VOC 2007 Dataset available:
http://vision.cs.utexas.edu/voc/
(Thanks to Dr Jasper Uijlings)
How to download vis Linux terminal:
$ wget -m -np http://vision.cs.utexas.edu/voc/
(Ref: http://stackoverflow.com/questions/8386894/download-an-svn-repository )
Found the official mirror to PASCAL VOC datasets (Thanks to Dr Jasper Uijlings again):
http://host.robots.ox.ac.uk/pascal/VOC/
Wednesday, May 13, 2015
Mount cellphone (Nokia Lumia 520) on Ubuntu 12.04
http://askubuntu.com/questions/367927/how-to-connect-nokia-lumia-520-to-ubuntu-12-04
Saturday, November 1, 2014
Audacity: to process mp3 files
Needed to filter humming noise from a lecture audio file, and found this amazing tool!
The references I used to learn it:
http://askubuntu.com/questions/429480/how-to-improve-the-sound-quality-of-an-mp3-speech-file
http://audacity.sourceforge.net/help/faq_i18n?s=editing&i=menu-disabled
http://www.youtube.com/watch?v=ZqxQc_8X4hw
http://manual.audacityteam.org/o/man/faq_opening_and_saving_files.html
The references I used to learn it:
http://askubuntu.com/questions/429480/how-to-improve-the-sound-quality-of-an-mp3-speech-file
http://audacity.sourceforge.net/help/faq_i18n?s=editing&i=menu-disabled
http://www.youtube.com/watch?v=ZqxQc_8X4hw
http://manual.audacityteam.org/o/man/faq_opening_and_saving_files.html
Monday, October 20, 2014
Assembler messages: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
I got the following errors while building RGBDSLAMv2 in ROS in my ubuntu 12.04 system.
[ 62%] Building CXX object rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/qt_gui.o
[ 64%] Building CXX object rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/node.o
[ 66%] Building CXX object rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/glviewer.o
/tmp/ccgvJzxG.s: Assembler messages:
/tmp/ccgvJzxG.s:11194: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/ccgvJzxG.s:12560: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/moc_graph_manager.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/tmp/cct3JxmG.s: Assembler messages:
/tmp/cct3JxmG.s:10798: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/cct3JxmG.s:12164: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/moc_openni_listener.o] Error 1
Linking CXX executable /home/swagatika/catkin_ws/devel/lib/my_pcl_tutorial/example
[ 66%] Built target example
/tmp/ccELf8iw.s: Assembler messages:
/tmp/ccELf8iw.s:16630: Error: no such instruction: `vfmadd312ss 88(%rsp),%xmm1,%xmm2'
/tmp/ccELf8iw.s:16640: Error: no such instruction: `vfmadd312ss 96(%rsp),%xmm3,%xmm1'
/tmp/ccELf8iw.s:16641: Error: no such instruction: `vfmadd312ss 100(%rsp),%xmm3,%xmm0'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/glviewer.o] Error 1
/tmp/ccslUlsc.s: Assembler messages:
/tmp/ccslUlsc.s:15733: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/ccslUlsc.s:17099: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/main.o] Error 1
/tmp/ccAmx5la.s: Assembler messages:
/tmp/ccAmx5la.s:439309: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/ccAmx5la.s:440675: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/openni_listener.o] Error 1
make[1]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/all] Error 2
make: *** [all] Error 2
Invoking "make" failed
$ gcc -march=native -Q --help=target | grep march
-march= corei7-avx
Solution:
In /home/swagatika/catkin_ws/src/rgbdslam_v2-hydro/CMakeLists.txt,
You can add
In my CMakeLists.txt, I added the above to the
http://stackoverflow.com/questions/17126593/compile-errors-with-assembler-messages
http://stackoverflow.com/questions/10327939/erroring-on-no-such-instruction-while-assembling-project-on-mac-os-x-lion
[ 62%] Building CXX object rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/qt_gui.o
[ 64%] Building CXX object rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/node.o
[ 66%] Building CXX object rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/glviewer.o
/tmp/ccgvJzxG.s: Assembler messages:
/tmp/ccgvJzxG.s:11194: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/ccgvJzxG.s:12560: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/moc_graph_manager.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/tmp/cct3JxmG.s: Assembler messages:
/tmp/cct3JxmG.s:10798: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/cct3JxmG.s:12164: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/moc_openni_listener.o] Error 1
Linking CXX executable /home/swagatika/catkin_ws/devel/lib/my_pcl_tutorial/example
[ 66%] Built target example
/tmp/ccELf8iw.s: Assembler messages:
/tmp/ccELf8iw.s:16630: Error: no such instruction: `vfmadd312ss 88(%rsp),%xmm1,%xmm2'
/tmp/ccELf8iw.s:16640: Error: no such instruction: `vfmadd312ss 96(%rsp),%xmm3,%xmm1'
/tmp/ccELf8iw.s:16641: Error: no such instruction: `vfmadd312ss 100(%rsp),%xmm3,%xmm0'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/glviewer.o] Error 1
/tmp/ccslUlsc.s: Assembler messages:
/tmp/ccslUlsc.s:15733: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/ccslUlsc.s:17099: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/main.o] Error 1
/tmp/ccAmx5la.s: Assembler messages:
/tmp/ccAmx5la.s:439309: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
/tmp/ccAmx5la.s:440675: Error: no such instruction: `vfmadd312ss (%r15),%xmm0,%xmm1'
make[2]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/src/openni_listener.o] Error 1
make[1]: *** [rgbdslam_v2-hydro/CMakeFiles/rgbdslam.dir/all] Error 2
make: *** [all] Error 2
Invoking "make" failed
$ gcc -march=native -Q --help=target | grep march
-march= corei7-avx
Solution:
In /home/swagatika/catkin_ws/src/rgbdslam_v2-hydro/CMakeLists.txt,
You can add
-march=native -mno-avx
This worked for me. In my CMakeLists.txt, I added the above to the
CMAKE_CXX_FLAGS
:SET(CMAKE_CXX_FLAGS "-ggdb -O3 -fPIC -std=c++0x -march=native -mno-avx")
Ref:http://stackoverflow.com/questions/17126593/compile-errors-with-assembler-messages
http://stackoverflow.com/questions/10327939/erroring-on-no-such-instruction-while-assembling-project-on-mac-os-x-lion
Sunday, May 4, 2014
Split a PDF to many PDFs
Here is the link to Linux Commando's blogpost on using pdftk to split a pdf.
http://linuxcommando.blogspot.in/2013/02/splitting-up-is-easy-for-pdf-file.html
http://linuxcommando.blogspot.in/2013/02/splitting-up-is-easy-for-pdf-file.html
Monday, March 3, 2014
Take screencast and ogv to Avi conversion in Ubuntu
For recording your screen, where we can demonstrate some videos or some functions, RecordMydesktop is a nice option in Ubuntu. It can be downloaded using Ubuntu Software Center. It is pretty easy to use too.
Here is the link for RecordMyDesktop:
https://apps.ubuntu.com/cat/applications/gtk-recordmydesktop/
However, this tool generates the video in ".ogv" format. If we wish to convert it into a commonly used format such as ".avi", we can use following commad:
$ mencoder input.ogv -ovc lavc -oac mp3lame -o output.avi
Courtesy:
http://www.cyberciti.biz/faq/linux-unix-bsd-appleosx-convert-ogv-to-avi-video-audio/
Here is the link for RecordMyDesktop:
https://apps.ubuntu.com/cat/applications/gtk-recordmydesktop/
However, this tool generates the video in ".ogv" format. If we wish to convert it into a commonly used format such as ".avi", we can use following commad:
$ mencoder input.ogv -ovc lavc -oac mp3lame -o output.avi
Courtesy:
http://www.cyberciti.biz/faq/linux-unix-bsd-appleosx-convert-ogv-to-avi-video-audio/
Saturday, January 4, 2014
combine multiple images or pdfs to generate one pdf file in Linux
Convert multiple images to pdf:
Convert multiple pdfs to write as a pdf:
$convert -compress Zip img1.jpg img2.jpg final.pdf
Convert multiple pdfs to write as a pdf:
$gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -sOutputFile=finished.pdf file1.pdf file2.pdf
Tuesday, April 9, 2013
Turn on Bluetooth in Ubuntu 12.04
I did not find it so straightforward to setup bluetooth in my ubuntu 12.04 system. So I had to look up couple of sites to fix my problem and successfully transfer data via bluetooth.
The following link gives a nice, detailed, step-by-step instruction on how to turn on bluetooth in ubuntu.
http://www.hecticgeek.com/2012/09/how-to-set-up-a-bluetooth-connection-in-ubuntu/
However, I was not able to activate any button. They all appeared deactivated to me. If you are facing the same problem, then you have to do the following setup in terminal:
$sudo hciconfig hci0 reset
This activates the buttons and lets you do your setting. (Refer: http://askubuntu.com/questions/153384/trouble-turning-on-bluetooth-in-12-04)
We need to check the option "Receive files in Downloads Folder over Bluetooth" in the menu opened in Personal File Sharing. In ubuntu 12.04, it is found in the path:
Applications ->System Tools->Preferences->Personal File Sharing.
The files transferred to the system are stored in the folder "Public" in the homepath.
The following link gives a nice, detailed, step-by-step instruction on how to turn on bluetooth in ubuntu.
http://www.hecticgeek.com/2012/09/how-to-set-up-a-bluetooth-connection-in-ubuntu/
However, I was not able to activate any button. They all appeared deactivated to me. If you are facing the same problem, then you have to do the following setup in terminal:
$sudo hciconfig hci0 reset
This activates the buttons and lets you do your setting. (Refer: http://askubuntu.com/questions/153384/trouble-turning-on-bluetooth-in-12-04)
We need to check the option "Receive files in Downloads Folder over Bluetooth" in the menu opened in Personal File Sharing. In ubuntu 12.04, it is found in the path:
Applications ->System Tools->Preferences->Personal File Sharing.
The files transferred to the system are stored in the folder "Public" in the homepath.
Sunday, February 24, 2013
Error: device not ready(firmware missing) while enabling wi-fi ubuntu 12.04
When I tried to enable wi-fi on my laptop, a ubuntu 12.04 system,
I got the following Error:
device not ready(firmware missing)
To solve this, first check if wireless driver is installed in your system.
Check for wireless driver in the following path:
Applications-> System Tools-> System settings->Additional Driver
If it is present and activate it.
If not, we need to install the driver. Use the following commands for the same and you are done!
$ sudo apt-get install firmware-b43-installer
$ sudo apt-get install firmware-b43-lpphy-installer
I got the following Error:
device not ready(firmware missing)
To solve this, first check if wireless driver is installed in your system.
Check for wireless driver in the following path:
Applications-> System Tools-> System settings->Additional Driver
If it is present and activate it.
If not, we need to install the driver. Use the following commands for the same and you are done!
$ sudo apt-get install firmware-b43-installer
$ sudo apt-get install firmware-b43-lpphy-installer
Reference:
http://askubuntu.com/questions/149999/how-do-i-install-missing-firmware
Labels:
Ubuntu
Location:
Hyderabad, Andhra Pradesh, India
Sunday, January 20, 2013
If font size in the figures do not change in Matlab..
If you wish to change the font of the text in your Matlab figure globally, then you have to set :
>>set(gca, 'FontSize', xx);
And if you want to change it only for a specific legend or text or axis-handles just add the option 'FontSize', xx to your parameters.
But this did not work in my Ubuntu 12.04 system. No matter what changes I made, Matlab displayed a fixed font size.
Thanks to the following forums, I could sort it out:
http://www.mathworks.in/matlabcentral/newsreader/view_thread/301184
http://ubuntuforums.org/showthread.php?t=1762805
You need to go to terminal and install following two packages, log in again.
$sudo apt-get install xfonts-75dpi
$sudo apt-get install xfonts-100dpi
>>set(gca, 'FontSize', xx);
And if you want to change it only for a specific legend or text or axis-handles just add the option 'FontSize', xx to your parameters.
But this did not work in my Ubuntu 12.04 system. No matter what changes I made, Matlab displayed a fixed font size.
Thanks to the following forums, I could sort it out:
http://www.mathworks.in/matlabcentral/newsreader/view_thread/301184
http://ubuntuforums.org/showthread.php?t=1762805
You need to go to terminal and install following two packages, log in again.
$sudo apt-get install xfonts-75dpi
$sudo apt-get install xfonts-100dpi
Saturday, January 5, 2013
Manage your time at work: timer for Ubuntu
Well, sometime back I was finding it difficult to focus and manage my time. Some times, I would sit at work for long period at a stretch affecting my health, some other time I would not be able to focus for 10 minutes. I searched for a timer that will help me set a fixed duration in which I will be bound to focus. I found a tool in the following link for usage in Ubuntu. I also found many more tools, but I liked this particular one because it is simple and has the visual clock like effect. As the time recedes, I become more alert since I need to finish the task within that period.
http://www.upubuntu.com/2011/10/beautimer-quick-and-lightweight.html
I found it very useful in managing my time and focusing as well. Hope it helps you too. :)
Happy working!
http://www.upubuntu.com/2011/10/beautimer-quick-and-lightweight.html
I found it very useful in managing my time and focusing as well. Hope it helps you too. :)
Happy working!
Tuesday, November 27, 2012
compressing in Linux : the 'tar' command
I find the 'tar' command very useful for my work especially when I work with lots of files and maintain lot of versions of code. The man page of tar is huge and I am sure there are many more flavours to it. However, I always find it confusing...there are certain customizations of 'tar' that come handy to me often and here they are...
$tar -cvzf filesDir.tgz filesDir/
Compress all files in directory filesDir to filesDir.tgz
Suppose, you edit only a few files of a huge directory with lots of sub-folders, then you would want to save only those few files.
In such case you should maintain a fileList which contains all filenames with relative path to the parent folder.
$cat fileList.txt
file1
file2
subdir1/subdir2/file3
subdir3/file4
subdir4/
$tar -cvzf filesDir.tgz -T fileList.txt
This will compress the files mentioned in fileList.txt. Note that subdir4/ is an entire folder. In this case, we are compressing all files contained in subdir4/
Now, comes the uncomressing part.
Go to the required path.
$ mkdir filesDir
$cd filesDir
filesDir]$ tar -xvzf filesDir.tgz
In case when you want to merge this data into another version of the same library/code, you can go into that directory and simply untar as above. The corresponding files in respective paths will get replaced by the files in filesDir.tgz, and new files and folders will be added.
Before untarring, we may want to check the difference to make sure that we are doing the right thing.
Here are the commands:
$diff -r dir1/ dir2/
This will display all the differences in two directories and their contents recursively (-r).
If you want to just see the files which correspond to changes, not the contents, then
$diff --brief -r dir1/ dir2/
$tar -cvzf filesDir.tgz filesDir/
Compress all files in directory filesDir to filesDir.tgz
Suppose, you edit only a few files of a huge directory with lots of sub-folders, then you would want to save only those few files.
In such case you should maintain a fileList which contains all filenames with relative path to the parent folder.
$cat fileList.txt
file1
file2
subdir1/subdir2/file3
subdir3/file4
subdir4/
$tar -cvzf filesDir.tgz -T fileList.txt
This will compress the files mentioned in fileList.txt. Note that subdir4/ is an entire folder. In this case, we are compressing all files contained in subdir4/
Now, comes the uncomressing part.
Go to the required path.
$ mkdir filesDir
$cd filesDir
filesDir]$ tar -xvzf filesDir.tgz
In case when you want to merge this data into another version of the same library/code, you can go into that directory and simply untar as above. The corresponding files in respective paths will get replaced by the files in filesDir.tgz, and new files and folders will be added.
Before untarring, we may want to check the difference to make sure that we are doing the right thing.
Here are the commands:
$diff -r dir1/ dir2/
This will display all the differences in two directories and their contents recursively (-r).
If you want to just see the files which correspond to changes, not the contents, then
$diff --brief -r dir1/ dir2/
Sunday, November 4, 2012
Matlab error of the type : /usr/bin/ld: matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.10' not found (required by /usr/bin/ld)
When I tried to compile mex files in Matlab (R2009a, 32-bit) on my Ubuntu 11.10 system, I got the following error:
>>mexAll
/usr/bin/ld: /home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.10' not found (required by /usr/bin/ld)
/usr/bin/ld: /home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.11' not found (required by /usr/bin/ld)
/usr/bin/ld: /home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by /usr/bin/ld)
collect2: ld returned 1 exit status
mex: link of ' "minFunc_2009/lbfgsC.mexglx"' failed.
Well, I found that I upgraded my system from v10.10 to 11.10. In the process, the libraries stored in Matlab were not updated with the system libraries.
So when such an error occurs,
1) Locate the library file in the system.
2)Remove or create a back up of the library in Matlab path.
3)Create a soft link in the matlab's appropriate folder for the one present in /usr/lib/
$ locate libstdc++.so.6
/home/swagatika/.dropbox-dist/libstdc++.so.6
/home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6
/home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6.0.9
/home/swagatika/softwares/matlab/toolbox/shared/hdllink/scripts/linux32/libstdc++.so.6
/home/swagatika/softwares/matlab/toolbox/shared/hdllink/scripts/linux32/libstdc++.so.6.0.9
/home/swagatika/softwares/matlab/toolbox/symbolic/mupad/linux/lib/gcclibs/libstdc++.so.6
/usr/lib/i386-linux-gnu/libstdc++.so.6
/usr/lib/i386-linux-gnu/libstdc++.so.6.0.16
/usr/lib/ure/lib/libstdc++.so.6
$ln -s /usr/lib/i386-linux-gnu/libstdc++.so.6 libstdc++.so.6
Now it compiles properly.
>>mexAll
/usr/bin/ld: /home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.10' not found (required by /usr/bin/ld)
/usr/bin/ld: /home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.11' not found (required by /usr/bin/ld)
/usr/bin/ld: /home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by /usr/bin/ld)
collect2: ld returned 1 exit status
mex: link of ' "minFunc_2009/lbfgsC.mexglx"' failed.
Well, I found that I upgraded my system from v10.10 to 11.10. In the process, the libraries stored in Matlab were not updated with the system libraries.
So when such an error occurs,
1) Locate the library file in the system.
2)Remove or create a back up of the library in Matlab path.
3)Create a soft link in the matlab's appropriate folder for the one present in /usr/lib/
$ locate libstdc++.so.6
/home/swagatika/.dropbox-dist/libstdc++.so.6
/home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6
/home/swagatika/softwares/matlab/sys/os/glnx86/libstdc++.so.6.0.9
/home/swagatika/softwares/matlab/toolbox/shared/hdllink/scripts/linux32/libstdc++.so.6
/home/swagatika/softwares/matlab/toolbox/shared/hdllink/scripts/linux32/libstdc++.so.6.0.9
/home/swagatika/softwares/matlab/toolbox/symbolic/mupad/linux/lib/gcclibs/libstdc++.so.6
/usr/lib/i386-linux-gnu/libstdc++.so.6
/usr/lib/i386-linux-gnu/libstdc++.so.6.0.16
/usr/lib/ure/lib/libstdc++.so.6
$ln -s /usr/lib/i386-linux-gnu/libstdc++.so.6 libstdc++.so.6
Now it compiles properly.
Subscribe to:
Posts (Atom)