Closed kstephens13 closed 4 years ago
Looks like you already had stuff in /usr/local from another installation? Pinging @seisman who is our brew master.
I never had similar issues before. As @PaulWessel said, it may be because you already have some packages installed in /usr/local before installing homebrew? Perhaps brew install --force gmt
works?
Hi all,
I tried out brew install --force gmt
but the same error comes up:
Error: An unexpected error occurred during the
brew linkstep The formula built, but is not symlinked into /usr/local Directory not empty @ dir_s_rmdir - /usr/local/opt/fontconfig Error: Directory not empty @ dir_s_rmdir - /usr/local/opt/fontconfig
Would I need to remove previously installed packages from /usr/local? Do you have suggestions for how to go about doing that?
remove previously installed packages from /usr/local
Yes, please try that if you didn't manually install any packages in this directory before.
I don't think I manually installed any packages before, so this should be possible.
Could you perhaps provide suggestions on how I go about removing packages from this directory? I am not sure how to approach this and don't want to accidentally remove something that still needs to be there. Thanks very much
Homebrew installs everything to /usr/local. If you also manually installs some packages in that directory, it may cause some conflicts.
My suggestions would be:
mv /usr/local /usr/local.bak
I tried to rename my /usr/local folder but Permission was denied:
gsc-dkmd007:usr kirsten$ sudo mv local local-saved
mv: rename local to local-saved: Operation not permitted
Then I tried changing ownership using two methods since High Sierra won't let me change chown permissions on /usr/local itself:
gsc-dkmd007:usr kirsten$ sudo chown -R "$USER":admin /usr/local/*
sudo chown -R $(whoami) $(brew --prefix)/*
These didn't give any errors, but I still get the recurring issue for trying to move the /usr/local directory...
Sorry, it's unclear to me why it doesn't work. Do you mind trying Anaconda (https://github.com/GenericMappingTools/2020-unavco-course/blob/master/INSTALL.md#installing-with-conda)?
Hi all, Following on from the suggestions during the video install session earlier, it looks like the install went through smoothly! Here are the steps I took in summary (attached log file gives greater details just in case logfile_gmt_install_homebrew_13Jul2020PM.txt):
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall.sh)"
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
brew install gmt
brew install ghostscript graphicsmagick ffmpeg
The only thing I feel could be an issue is ffmpeg:
==> Installing ffmpeg
==> Pouring ffmpeg-4.3.1.high_sierra.bottle.tar.gz
Warning: ffmpeg dependency gcc was built with a different C++ standard library (libstdc++ from clang). This may cause problems at runtime.
🍺 /usr/local/Cellar/ffmpeg/4.3.1: 299 files, 61MB
Reason being because when I tested test_2.sh script, I got the following error output:
gsc-dkmd007:hw1 kirsten$ ./test_2.sh
movie [NOTICE]: Running: ffmpeg -loglevel warning -f image2 -framerate 4 -y -i "count/count_%02d.png" -vcodec libx264 -pix_fmt yuv420p count.mp4
movie [NOTICE]: Running: ffmpeg -loglevel warning -f image2 -framerate 4 -y -i "count/count_%02d.png" -vcodec libvpx -crf 10 -b:v 1.2M -pix_fmt yuv420p count.webm
Open either count.mp4 or count.webm in an application that can view movies
Any suggestions on this? Thanks again!
Can you double-click on count.mp4 and verity you see the mocie?
Yupp, the movie works! (But only in QuickTime, in VLC it only shows up to number 18 and then quits)
That is good enough I think.
Excellent, thank you everyone for your help!
System: Mac OS X 10.13.7 (High Sierra)
I previously tried to install GMT 6.1 using macports, but was only able to install GMT 6.0 successfully. I was then recommended to rather try using homebrew instead of macports, and move the macports linked folder: sudo mv /opt/local /opt/local-saved
After installing homebrew, I encountered several errors during install command: brew install gmt Two main types of errors were observed (see attached log file of runtime output logfile_gmt_install_homebrew_errors_12Jul2020.txt): 1) Error: The
brew link
step did not complete successfully The formula built, but is not symlinked into /usr/local 2) Error: An unexpected error occurred during thebrew link
step The formula built, but is not symlinked into /usr/localI was able to resolve some of the errors associated with error 1, however sometimes the forced symlink didn't always works. It seems like the issue may still be associated with macports? I have never used homebrew before so I am unsure of how to resolve the errors