Valgrind 2.20 to be used but requires glibc 2.1 - 2.3 version - valgrind

I want to install valgrind 2.20. It requires glibc 2.1-2.3 version. I am having glibc2.11? What can i change in configure file to solve the problem? I tried this link valgrind doesn't accept newest version of glibc
And pasted this
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: 2.11 family" >&5
$as_echo "2.11 family" >&6; }
$as_echo "#define GLIBC_2_11 1" >>confdefs.h
DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
;;
but it is showing the same error
configure: error: Valgrind requires the glibc version 2.1, 2.2 or 2.3

What can i change in configure file to solve the problem?
It's a bug in autoconf, which has long since been fixed.
Just edit configure script to remove the glibc version check.

Related

Meet "dyld: Library not loaded of wrong architecture" for libquadmath.0.dylib when running scip

I installed SCIP Optimization Suite from the SCIPOptSuite-7.0.2-Darwin-Ipopt-gcc10.sh installer of precompiled binary.
I also installed gcc and tbb by running:
brew install gcc
brew install tbb
Error message:
$ SCIPOptSuite-7.0.2-Darwin/bin/scip
dyld: Library not loaded: /usr/local/lib/7/i386/libquadmath.0.dylib
Referenced from: /Users/it/VirtualBox/10运筹学/14SCIP/01install/SCIPOptSuite-7.0.2-Darwin/bin/scip
Reason: no suitable image found. Did find:
/usr/local/lib/7/i386/libquadmath.0.dylib: mach-o, but wrong architecture
/usr/local/lib/7/i386/libquadmath.0.dylib: stat() failed with errno=1
/usr/local/lib/7/i386/libquadmath.0.dylib: mach-o, but wrong architecture
[1] 93720 abort SCIPOptSuite-7.0.2-Darwin/bin/scip
There is other libquadmath.0.dylib with x86_64 architecture installed:
$ sudo find / -name libquadmath.0.dylib
Password:
/usr/local/lib/7/i386/libquadmath.0.dylib
/usr/local/lib/7/libquadmath.0.dylib
/usr/local/opt/lib/gcc/7/i386/libquadmath.0.dylib
/usr/local/opt/lib/gcc/7/libquadmath.0.dylib
/usr/local/Cellar/4.6.4/lib/gcc/x86_64-apple-darwin12.5.0/4.6.4/i386/libquadmath.0.dylib
/usr/local/Cellar/4.6.4/lib/gcc/x86_64-apple-darwin12.5.0/4.6.4/libquadmath.0.dylib
/usr/local/Cellar/gcc/10.2.0_2/lib/gcc/10/libquadmath.0.dylib
/usr/local/Cellar/gcc#4.6/4.6.4/lib/gcc/x86_64-apple-darwin12.5.0/4.6.4/i386/libquadmath.0.dylib
/usr/local/Cellar/gcc#4.6/4.6.4/lib/gcc/x86_64-apple-darwin12.5.0/4.6.4/libquadmath.0.dylib
/Users/it/miniconda3/lib/python3.6/site-packages/numpy/.dylibs/libquadmath.0.dylib
/Users/it/miniconda3/lib/python3.6/site-packages/scipy/.dylibs/libquadmath.0.dylib
/Users/it/miniconda3/envs/py2/lib/python2.7/site-packages/scipy/.dylibs/libquadmath.0.dylib
$ lipo /usr/local/lib/7/libquadmath.0.dylib -archs
x86_64
I wonder why scip did not find these dylibs with right architecture?
Thanks very much.
First of all make sure you have the correct version of gcc installed, the installer that you downloaded asks for version 10.
Second, try installing all prerequisites first and then rerunning the installer-script afterwards.
If that does not help, please check the output of otool -L SCIPOptSuite-7.0.2-Darwin/bin/scip and echo $DYLD_LIBRARY_PATH to see if the library in question is loaded.
Lastly, you can try to patch the binary by adjusting the path to the library for the correct one:
install_name_tool -change /usr/local/lib/7/i386/libquadmath.0.dylib /usr/local/Cellar/gcc/10.2.0_2/lib/gcc/10/libquadmath.0.dylib SCIPOptSuite-7.0.2-Darwin/bin/scip

How to make cmake identify correct version in centos 6 terminal?

After a very long and lengthy process of trying to get Emscripten going. I'm stuck trying to build fastcomp.
cmake .. -DCMAKE_BUILD_TYPE=Release
-DLLVM_TARGETS_TO_BUILD="X86;JSBackend" -DLLVM_INCLUDE_EXAMPLES=OFF -DLLVM_INCLUDE_TESTS=OFF -DCLANG_INCLUDE_TESTS=OFF
It gives this error:
CMake Error at cmake/modules/CheckCompilerVersion.cmake:12 (message):
Host GCC version must be at least 4.8!
I've installed devtools 2 and actiavted the toolset.
gcc --version reads as using gcc 4.8.2, but it just won't go.
I've also tried:
export CC=/opt/rh/devtoolset-2/root/usr/bin/gcc
export CXX=/opt/rh/devtoolset-2/root/usr/bin/c++
export CPP=/opt/rh/devtoolset-2/root/usr/bin/cpp
What am I doing wrong?
I had this same problem until I recompiled a recent version of cmake with the newer version of gcc already "activated".
Then, with the CC, CXX and CPP environment variables also set to the appropriate paths, cmake then stopped giving that "Host GCC version must be at least 4.8!" error.

building TensorFlow: bazel cannot find libstdc++ in non-standard directory

I am trying to build MKL-accelerated version of TensorFlow using bazel 0.5.1, gcc 6.2, binutils 2.28, Anaconda2 python on Scientific Linux 7.2.
Apparently the system /lib64/libstdc++.so.6 is too old, so I am trying to use gcc installed in another directory. PATH, LD_LIBRARY_PATH are modified to prepend the corresponding paths (using modules). However, while bazel has no trouble picking up correctly executables for gcc, ld, python, it still tries to load old system /lib64/libstdc++.so.6. How to force it to use the one from gcc 6.2? Why does not it pick it up from LD_LIBRARY_PATH?
According to google many people are having trouble with this but I could not find a solution that would work for me. I had no trouble building TensorFlow under Ubuntu 16.04 that has sufficiently new gcc in the standard location.
I do:
1) ./configure
The only non-default options I choose is use MKL and download MKL
2) bazel build --config=mkl --copt="-DEIGEN_USE_VML" -s -c opt //tensorflow/tools/pip_package:build_pip_package
.....
example/example_parser_configuration.proto tensorflow/core/protobuf/control_flow.proto tensorflow/core/protobuf/meta_graph.proto tensorflow/core/protobuf/named_tensor.proto tensorflow/core/protobuf/saved_model.proto tensorflow/core/protobuf/tensorflow_server.proto tensorflow/core/util/event.proto tensorflow/core/util/test_log.proto)
ERROR: /scratch/midway2/ivy2/TF_intel/tensorflow/tensorflow/tools/tfprof/BUILD:42:1: null failed: protoc failed: error executing command bazel-out/host/bin/external/protobuf/protoc '--python_out=bazel-out/local-opt/genfiles/' -I. -I. -Iexternal/protobuf/python -Ibazel-out/local-opt/genfiles/external/protobuf/python ... (remaining 5 argument(s) skipped): com.google.devtools.build.lib.shell.BadExitStatusException: Process exited with status 1.
bazel-out/host/bin/external/protobuf/protoc: /lib64/libstdc++.so.6: version GLIBCXX_3.4.20' not found (required by bazel-out/host/bin/external/protobuf/protoc)
bazel-out/host/bin/external/protobuf/protoc: /lib64/libstdc++.so.6: versionCXXABI_1.3.8' not found (required by bazel-out/host/bin/external/protobuf/protoc)
bazel-out/host/bin/external/protobuf/protoc: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by bazel-out/host/bin/external/protobuf/protoc)
.....
Thank you,
Igor
sorry for the slow reply. Bazel by design ignores LD_LIBRARY_PATH when running actions. It doesn't have to ignore them during C++ toolchain detection, but at the moment, it does :/ To help you forward, I would try adding --sysroot= as linkopt or using bazel grte_top flag. Depending on where your libstdc++.so lives, you might need to disable sandbox. The principled solution would be to write a custom CROSSTOOL that specifies builtin_sysroot or grte_top. But that is not an easy task.
Let me know if I lost you somewhere in that paragraph :)

Unable to import matplotlib._png (pylab)

I am unable to import matplotlib._png:
import matplotlib._png as _png ImportError:
/home/james/opt/python/virtualenvs/work/lib/python2.7/site-packages/matplotlib-1.3.x-py2.7-linux-x86_64.egg/matplotlib/_png.so:
undefined symbol: png_set_longjmp_fn
This error prevents me from running import pylab (sincce this ultimately imports matplotlib._png).
I installed matplotlib from source, and made sure to add the path with local installations (/home/james/local) to basedir in setupext.py before running python setup.py install.
REQUIRED DEPENDENCIES AND EXTENSIONS
numpy: yes [version 1.7.1]
dateutil: yes [using dateutil version 2.1]
tornado: yes [using tornado version 3.0.1]
pyparsing: yes [using pyparsing version 1.5.7]
pycxx: yes [Couldn't import. Using local copy.]
libagg: yes [pkg-config information for 'libagg' could not
be found Using local copy.]
freetype: yes [version 16.0.10]
png: yes [version 1.2.10]
My research so far:
As can be seen above, matplotlib seems to find version 1.2.10 even though the version that I have under /home/james/local is 1.6.2:
$ find . -iname '*libpng*'
./libpng16.so.16.1.0
./libpng16.so
./libpng16.so.16
./libpng16.a
./libpng.a
./libpng.so
./libpng16.la
./pkgconfig/libpng.pc
./pkgconfig/libpng16.pc
./libpng.la
More specifically, I modified the following line in setupext.py with:
return basedir_map.get(sys.platform, ['/home/james/local', '/usr/local', '/usr'])
but matplotlib seems to have found the system version:
$ locate libpng
/usr/lib/libpng.so
/usr/lib/libpng.so.3
/usr/lib/libpng.so.3.10.0
/usr/lib/libpng12.a
/usr/lib/libpng12.so
/usr/lib/libpng12.so.0
/usr/lib/libpng12.so.0.10.0
Could this be the problem? Why am I unable to import matplotlib._png?
Update:
Looking at setupext.py, it looks like python setup install queries pkg-config through the SetupPackage method _check_for_pkg_config to determine the version of libpng I have installed. It turns out that pkg-config is returning the system installation:
$ pkg-config --libs libpng
-lpng12
even though I have updated basedir in matplotlib's setupext.py, and LD_LIBRARY_PATH to make them point to the the more recent version of libpng that I have locally installed.
Any ideas on how to have pkg-config return the right version?
It's a pkg-config issue; matplotlib's installation is (unfortunately, or perhaps not) relying too much on pkg-config's output.
Assuming you have build libpng the normal way, there should be a pkgconfig subdirectory in your /home/james/local/lib, which contains libpng.pc (and libpng16.pc). When setupext.py runs pkg-config, the latter should of course try and pick up the correct .pc file for libpng. For that, use the PKG_CONFIG_PATH variable and point it to the pkgconfig subdirectory:
$ export PKG_CONFIG_PATH=/home/james/local/lib/pkgconfig
Then, install matplotlib again, and see that it now finds the correct libpng version:
$ python setup.py build
basedirlist is: ['/usr/local', '/usr']
============================================================================
BUILDING MATPLOTLIB
matplotlib: 1.1.0
python: 2.7.4 (default, Apr 8 2013, 16:36:47) [GCC 4.4.5]
platform: linux2
REQUIRED DEPENDENCIES
numpy: 1.7.0
freetype2: 12.0.6
OPTIONAL BACKEND DEPENDENCIES
libpng: 1.6.1
Tkinter: Tkinter: 81008, Tk: 8.4, Tcl: 8.4
(For me, with a different PKG_CONFIG_PATH of course. Yes, I may want to upgrade some dependencies.)
Note that I didn't even alter basedirlist; it's just at its default.
In case pkg-config fails to now pick up some other package, just add more directories to PKG_CONFIG_PATH with colons in between. But I guess this should be enough.
Try
export LD_LIBRARY_PATH=/home/james/local/lib
and then execute Matplotlib... that would point matplotlib to your local version.

Merging Mono Runtime 3.0.4 with MonoDevelop 3.x fails

I'm trying to merge the Mono Runtime (v 3.0.4) with a MonoMac application, but since the upgrade to 3.0.4 (from 2.10.11) this fails with the following error:
Merging Mono Runtime into app bundle
/Applications/MonoDevelop-old.app/Contents/MacOS/lib/monodevelop/AddIns/MonoDevelop.MonoMac/mmp
-nolink "-minos=10.6.6"
-o "/Users/ted/Documents/XCode/Mac/StageTimer/StageTimer/bin/Release"
-n "StageTimer"
-a "/Library/Frameworks/Mono.framework/Versions/3.0.4/lib/mono/4.0/System.dll"
-a "/Library/Frameworks/Mono.framework/Versions/3.0.4/lib/mono/4.0/System.Xml.dll"
-a "/Library/Frameworks/Mono.framework/Versions/3.0.4/lib/mono/4.0/System.Core.dll"
-a "/Library/Frameworks/Mono.framework/Versions/3.0.4/lib/mono/4.0/System.Xml.Linq.dll"
-a "/Library/Frameworks/Mono.framework/Versions/3.0.4/lib/mono/4.0/System.Drawing.dll"
-a "/Applications/MonoDevelop-old.app/Contents/MacOS/lib/monodevelop/AddIns/MonoDevelop.MonoMac/MonoMac.dll"
"/Users/ted/Documents/XCode/Mac/StageTimer/StageTimer/bin/Release/StageTimer.exe"
Process exited with code 1, command:
pkg-config --variable=prefix mono-2
Unhandled Exception: System.IO.DirectoryNotFoundException: Directory '/lib/mono/4.0' not found.
Even if I configure MonoDevelop to use Mono 2.10.11 instead of 3.0.4 it fails with the same error (and path: '/lib/mono/4.0'). Next I also tried modifying the symlink in /Library/Frameworks/Mono.framework/Versions/Current to point to 2.10.11 but still the same error & path.
Anyone with mono & pkg-config skills that knows how to configure this?
Similar issue happened to F# compiler when one tried to run it alongside Mono 3.0.4 (instead of 3.0.3). The issue boils down to a bugfix in Mono that prevents conflicting the homebrew pkg-config set up. The workaround that was adopted in F# sources was to hardcode the path to Mono's pkg-config.
You could probably get the same result as this by just overriding the environment variable PKG_CONFIG_PATH when launching MonoDevelop, this way:
PKG_CONFIG_PATH=/path/were/mono/pc/files/are/in/Mac:$PKG_CONFIG_PATH monodevelop
The exact path must be somewhere underneath /Library/Frameworks/Mono.framework/Versions/Current/ , just look out for files with .pc extension.