When building any conda recipie on my macOS (High Sierra, version 10.13.6), I get the following error:
OSError: dlopen(/anaconda3/bin/../lib/libarchive.dylib, 6): Library not loaded: #rpath/libxml2.2.dylib Referenced from: /anaconda3/lib/libarchive.13.dylib
Reason: Incompatible library version: libarchive.dylib requires version 12.0.0 or later, but libxml2.2.dylib provides version 10.0.0
I have done the following:
Downloaded and installed https://repo.anaconda.com/archive/Anaconda3-2019.03-MacOSX-x86_64.pkg.
updated conda: conda update conda
installed conda-build: conda install conda-build
then tried building conda recipe: conda install .
I get this error when building any recipe, for the sake of example, here is the one i am trying:
package:
name: cmake
version: 3.2.3
source:
fn: cmake-3.2.3.tar.gz [not win]
url: http://www.cmake.org/files/v3.2/cmake-3.2.3.tar.gz [not win]
build:
number: 0
requirements:
build:
run:
about:
home: http://www.cmake.org
license: BSD 3-clause
build.sh contains:
#!/bin/bash
./bootstrap --prefix=$PREFIX
make
make install
Related
When I doing bundle install of my project with Pashion in my gemfile.
I encountered troubleshooting:
ld: library not found for -ljpeg.
Confirmed things are I have installed jpeg, libjpeg, libpng by following commands.
brew install jpeg and brew install libjpeg
brew install libpng
gem install phashion -v '1.2.0' will get the same error.
Machine: MacBook Air (M1, 2020)
Os: macOS BigSur 11.2 (20D64)
$ gcc --version
Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/4.2.1
Apple clang version 12.0.0 (clang-1200.0.32.29)
Target: arm64-apple-darwin20.3.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
Related:
I use homebrew, which has full support on NEW Mac(M1), to install pacakges.
I use rvm(1.29.12) to manage ruby(2.6.3 as default).
Most like the problem here https://github.com/westonplatter/phashion/issues/19
After lots of searching and tries, the solution is as follows:
gem install phashion -v '1.2.0'
You will get troubleshooting: ld: library not found for -ljpeg
install phashion with config
LIBRARY_PATH=$LIBRARY_PATH:/opt/homebrew/opt/libjpeg/lib gem install phashion -v '1.2.0'
Then you will get troubleshooting: fatal error: 'jpeglib.h' file not found
last troubleshooting is because of clang path error. So
Add export CPLUS_INCLUDE_PATH=/opt/homebrew/include into ~/.zshrc
Don't forget to source ~/.zshrc.
run LIBRARY_PATH=$LIBRARY_PATH:/opt/homebrew/opt/libjpeg/lib gem install phashion -v '1.2.0' once again.
Then You will get troubleshooting: ld: library not found for -lpng
run LIBRARY_PATH=$LIBRARY_PATH:/opt/homebrew/opt/libjpeg/lib:/opt/homebrew/opt/libpng/lib gem install phashion -v '1.2.0' once again.
Installation success!
LSB Version: core-9.20170808ubuntu1-noarch:security-9.20170808ubuntu1-noarch
Distributor ID: Ubuntu
Description: Ubuntu 18.04.3 LTS
Release: 18.04
Codename: bionic
Conda install of gcc results in the following:
(base) userA#server:~$ conda install -c anaconda gcc
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: /home/userA/anaconda3
added / updated specs:
- gcc
The following NEW packages will be INSTALLED:
cloog anaconda/linux-64::cloog-0.18.0-0
gcc anaconda/linux-64::gcc-4.8.5-7
isl anaconda/linux-64::isl-0.12.2-0
Proceed ([y]/n)? y
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
ERROR conda.core.link:_execute(700): An error occurred while installing package 'anaconda::gcc-4.8.5-7'.
Rolling back transaction: done
LinkError: post-link script failed for package anaconda::gcc-4.8.5-7
location of failed script: /home/userA/anaconda3/bin/.gcc-post-link.sh
==> script messages <==
<None>
==> script output <==
stdout: Installation failed: gcc is not able to compile a simple 'Hello, World' program.
stderr: ln: failed to create symbolic link '/home/userA/anaconda3/lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crt1.o': File exists
ln: failed to create symbolic link '/home/userA/anaconda3/lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crti.o': File exists
ln: failed to create symbolic link '/home/userA/anaconda3/lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crtn.o': File exists
/home/userA/anaconda3/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.5/cc1: error while loading shared libraries: libmpfr.so.4: cannot open shared object file: No such file or directory
return code: 1
()
Please advise. Happy to provide any additional helpful information.
***EDITED (most recent first):
OUTPUT of conda list | grep -E '(gmp|mpc|mpfr)
(base) userA#server:~$ conda list | grep -E '(gmp|mpc|mpfr)'
gmp 6.1.2 hb3b607b_0 anaconda
gmpy2 2.0.8 py37h10f8cd9_2
mpc 1.1.0 h10f8cd9_1 anaconda
mpfr 4.0.1 hdf1c602_3 anaconda
conda install gcc is no longer relevant in Anaconda v5, which prefers conda install gcc_linux-64
Anaconda v5 in Ubuntu 18.04 supports libmpfr.so.6 but not libmpfr.so.4, hence the issues with finding libmpfr.so.4
I have installed conda 4.3.22 and want to update conda gcc from 4.8.5 to 6.2.0. By using the following command I am getting an error because of the isl version. However, by trying to install a newer version of isl I am getting an error because of the gcc version. This is a rather dumb problem but I am not sure on how to get around it.
$ conda install -c salford_systems gcc-6=6.2.0
Fetching package metadata ...........
Solving package specifications:
PackageNotFoundError: Dependency missing in current linux-64 channels:
- gcc-6 6.2.0* -> isl >=0.17,<=0.17.1
$ conda install -c conda-forge isl=0.17.1
Fetching package metadata ...........
Solving package specifications: .
UnsatisfiableError: The following specifications were found to be in conflict:
- gcc -> isl >=0.10,<=0.14
- isl 0.17.1*
Use "conda info <package>" to see the dependencies for each package.
Edit 1:
As it was pointed out in the comments by darthbith, a combined command is not working and throws the following error:
$ conda install -c conda-forge -c salford_systems gcc-6=6.2.0 isl=0.17.1
Fetching package metadata .............
Solving package specifications: .
UnsatisfiableError: The following specifications were found to be in conflict:
- gcc -> isl 0.12.*
- gcc-6 6.2.0*
Use "conda info <package>" to see the dependencies for each package.
Do I understand it correct, that gcc and gcc-6 are different packages of which both require a different version of isl and thus leading to my problem? I only would need a newer version of gcc which supports GLIBCXX_3.4.21.
Thanks in advance.
I was able to solve my problem, thank you darthbith for helping me out.
Since gcc and gcc-6 are in fact two different packages, the solution was to delete gcc. After that, I had to update isl before I could install gcc-6. The commands used were:
conda uninstall gcc
conda install -c conda-forge isl=0.17.1
conda install -c salford_systems gcc-6=6.2.0
How to install gcc3.4? I need this version to compile u-boot sources which seem to take older version of gcc.
I have a fresh install of 0S - Ubuntu-mate 14.04.2-LTS, which I am using to install gcc3.4. I do not have any pre installed gcc on this.
When I tried the command:
$sudo apt-get install gcc-3.4
I am getting the error:
E: Unable to locate package gcc-3.4
E: Couldn't find any package by regex 'gcc-3.4'
I'm trying to use RVM to install ruby 1.9.2 and 1.9.3. It fails because one of the dependencies seems to be gcc46, and rvm uses brew to install it.
rbanerjee:~ $ sudo brew install gcc46
==> Installing dependencies for gcc46: gmp4, mpfr2, libmpc08, ppl011, cloog-ppl015
==> Installing gcc46 dependency: gmp4
==> Downloading ftp://ftp.gmplib.org/pub/gmp-4.3.2/gmp-4.3.2.tar.bz2
Already downloaded: /Library/Caches/Homebrew/gmp4-4.3.2.tar.bz2
==> Patching
==> ./configure --prefix=/usr/local/Cellar/gmp4/4.3.2 --enable-cxx --build=x86_64-apple-darwin
checking ABI=64
checking compiler clang ... no
checking ABI=32
checking compiler clang ... no
configure: error: could not find a working compiler, see config.log for details
but clang is there and working:
rbanerjee:~ $ which clang
/usr/bin/clang
rbanerjee:~ $ clang -v
Apple LLVM version 4.2 (clang-425.0.28) (based on LLVM 3.2svn)
Target: x86_64-apple-darwin11.4.2
Thread model: posix
Weird that the version is 4.2, since I have Xcode 4.6.3 and command line tools 4.6.3 installed. xcrun seems to be a problem too. Digging through the gcc46 logs leads to a failure to install gmp4:
in ~/Library/Logs/Homebrew/gmp4/config.log
/usr/local/Library/ENV/4.3/clang:338:in `exec': No such file or directory - xcrun (Errno::ENOENT)
from /usr/local/Library/ENV/4.3/clang:338
Any ideas? Thanks in advance. OSX Lion. Here's all my system info:
https://gist.github.com/anonymous/9e2cdb6c0d0ca0b29eba