crichardson332 / homebrew-crich_brews

Homebrew tap
0 stars 0 forks source link

readlink: illegal option -- f #4

Open jharrison opened 5 years ago

jharrison commented 5 years ago

Note: I know you already answered this here, but I made this separate issue for posterity.

Found a snag. There's a difference between the BSD and GNU versions of readlink. This results in the following error when trying to run generate-plugin.sh:

readlink: illegal option -- f
usage: readlink [-n] [file ...]

See also: https://stackoverflow.com/questions/1055671/how-can-i-get-the-behavior-of-gnus-readlink-f-on-a-mac

jharrison commented 5 years ago

Note for anyone with the same issue: if you follow the workaround of changing readlink to greadlink in generate-plugin.sh, it works but it leaves you with a bunch of files hanging around with names ending in -- (e.g., CMakeLists.txt--, MyPlugin.h--, MyPlugin.cpp--, MyPlugin.xml--). It looks like these are created by the generate-plugin.sh script and are supposed to be temporary. For whatever reason, they stuck around afterward. I think they can be safely deleted without a problem.