Can't install Tesseract on Mac using brew install tesseract - python-3.x

I check my homebrew is the latest version (3.2.6).
But I can't still install tesseract using the following code on my macbook pro 2014-mid.
brew install tesseract
And it replied that
Warning: No available formula or cask with the name "tesseract".
I also try the following code to check if the tesseract has been installed, but it seems to be null.
brew list tesseract
And it replied that
Error: No such keg: /usr/local/Cellar/tesseract
Is there any setting should I do? Thanks!
Update 1:
I also try the following code, and still get the problem.
brew install wget
Warning: No available formula or cask with the name "wget".

After I try so many times, a Taiwanese netizen solve my problem.
The problem existed in the TAPS (third-party-repositories).
And I try the following code
rm -rf /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core
and then
brew tap homebrew/core
finally,
brew update

Related

How to downgrade or install older or specific version of node using Homebrew?

I'm new to brew, to be honest. I want to use an earlier version of the Node. The current version I have is node#14.
The Version I've been trying to install is node#9.10.0, I tried installing it using Brew. brew install node#9.10.0
Online, I have followed instructions here
but it keeps throwing me an error, I'm not sure If I'm doing anything wrong here.
Warning: No available formula or cask with the name "node#9". Did you mean node, nodenv, node#12, node#10, node#14 or ode?
==> Searching for similarly named formulae...
These similarly-named formulae were found:
node ✔ nodenv node#12 node#10 node#14 ode
To install one of them, run (for example):
brew install node ✔
==> Searching for a previously deleted formula (in the last month)...
Error: No previously deleted formula found.
==> Searching taps on GitHub...
Error: No formulae found in taps.
I tried Updating brew and I have also tried brew doctor to resolve any kind of complications.
I have also tried uninstalling Node completely and installed it using Brew but any of the methods doesn't seem to work. Should I use a different subcommand instead? Is there a completely different method I should try?
I'm running macOS Bigsur 11.6 and Homebrew 3.2.16
First do: brew search node and tell me what you get
If you get the node version you want do:
brew install node#availableversion
You can download from nodejs website:
https://nodejs.org/download/release/v9.10.0/
Try below:
eval "$(nodenv init -)"
node -v
brew unlink (the node version you see)
nodenv install -l
nodenv install (the node version you want on the list)

Package 'demo_nodes_cpp' not found. Cannot run ros2 demo after installing ade when trying Autoware.auto tutorial on linux

I'm following Autoware.auto tutorial. After installing ade, I cannot run ros2 demo talker/listener examples:
source /opt/ros/foxy/setup.bash
ros2 run demo_nodes_cpp talker
source /opt/ros/foxy/setup.bash
ros2 run demo_nodes_py listener
I got this error:
"Package 'demo_nodes_cpp' not found"
I was in user#ade when running the command.
Any help is appreciated. Thanks in advance!
Look like demo_nodes_cpp was removed from Autoware.Auto. I refer to this issue on the original Autoware.Auto GitLab tutorial gitlab.com/ApexAI/autowareclass2020/-/issues/75 The problem is closed now.
Run this command replacing with your version of ros installed
for ros-foxy-demo-nodes-cpp :sudo apt-get install ros-{ros-version}-demo-nodes-cpp
example: ros-humble-demo-nodes-cpp
for ros-foxy-demo-nodes-py :sudo apt-get install ros-{ros-version}-demo-nodes-py
example: ros-humble-demo-nodes-py
It seems that thedemo-nodes-cpp and demo-nodes-py packages are not installed.
This can be easily fixed with:
sudo apt-get update
sudo apt-get install ros-$ROS_DISTRO-demo-nodes-py
sudo apt-get install ros-$ROS_DISTRO-demo-nodes-cpp
source /opt/ros/$ROS_DISTRO/local_setup.bash
Which will download the mentioned packages for any ros2 version as long as the environment variable ROS_DISTRO has been properly set (which should be by default).

I'm getting errors while installing pygame on my Chromebook, and to make matters worse, the website is down? Please tell me why [duplicate]

I used
./configure --prefix=$HOME
make
make install
to install sdl2,
after which I tried to install pygame by
cd ../pygame-1.9.1release/
python setup.py install
but I am getting an error:
linuxnx:~/python/library/pygame-1.9.1release> python setup.py install
WARNING, No "Setup" File Exists, Running "config.py"
Using UNIX configuration...
Hunting dependencies...
sh: sdl-config: command not found
WARNING: "sdl-config" failed!
sh: smpeg-config: command not found
WARNING: "smpeg-config" failed!
Unable to run "sdl-config". Please make sure a development version of SDL is installed.
I searched a long time, cause I needed the package for Python Crash Course by Eric Matthes, but couldn't find the answer that would help running
pip install pygame
without errors and finally found 1 line solution that worked for me
sudo apt-get install python-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsdl1.2-dev libsmpeg-dev python-numpy subversion libportmidi-dev ffmpeg libswscale-dev libavformat-dev libavcodec-dev libfreetype6-dev
I'm seeing that this thread has been around for a long time, but I think it's a good idea to leave this here in case it helps someone.
I found these lines on a website that might help:
At the moment, 5/1/2020, you cannot install the pygame libraries in
python 3.8 with pip install pygame, bu you can install them with a
particular version of them, still for dev. You can install Python 3.8
in the command line using this version: pip install pygame==2.0.0.dev6
Latest version: pip install pygame==2.0.0.dev10
I don't know if you use python3 but it throws me more errors apart from sdl
as well as freetype-config ... Before I used "python3 -m pip install pygame".
:~$ python3 -m pip install pygame==2.0.0.dev10
Collecting pygame==2.0.0.dev10
Downloading pygame-2.0.0.dev10-cp38-cp38-manylinux1_x86_64.whl (14.3 MB)
|████████████████████████████████| 14.3 MB 130 kB/s
Installing collected packages: pygame
Successfully installed pygame-2.0.0.dev10
Nice programming time for all!! =)
ORIGINAL: 2013.10.25
PyGame-1.9.1 was created in 2009 so it still use old SDL 1.2 not new SDL2.
PySDL2 use SDL2
EDIT: 2021.10.17
Question and my original answer is almost 8 years old and it seems author removed PySDL2 from URL in my old answer. He moved code from bitbucket to github
Using Google I found
doc: https://pysdl2.readthedocs.io/
pypi: https://pypi.org/project/PySDL2/
github: https://github.com/marcusva/py-sdl2
And meanwhile PyGame started to use SDL2.
Pygame.org: pygame 2 — 28 Oct, 2020
GitHub: Release note
See also all releases
Try this in the terminal , It should installs the sdl 1.2
# make a temporary directory where we can download and build stuff
mkdir tmp
cd tmp
# download and install SDL
wget http://www.libsdl.org/release/SDL-1.2.14.tar.gz
tar -xzvf SDL-1.2.14.tar.gz
cd SDL-1.2.14
./configure
sudo make all
After I read top answer above,
I installed python-dev, libsdl-image1.2-dev.
Then I got
Hunting dependencies...
WARNING: "pkg-config freetype2" failed!
WARNING: "freetype-config" failed!
SDL : found 1.2.15
FONT : not found
IMAGE : found
MIXER : not found
PNG : found
JPEG : found
SCRAP : found
PORTMIDI: not found
PORTTIME: not found
FREETYPE: not found
Missing dependencies
So I just installed these and it worked.
sudo apt install python-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libportmidi-dev libfreetype6-dev
This error showed up once again in Pygame-2.0.0.dev12
The solution for me was:
sudo apt-get install libsdl2-dev
Then I got
Hunting dependencies...
SDL : found 2.0.9
FONT : not found
IMAGE : not found
MIXER : not found
PNG : found
JPEG : found
SCRAP : found
PORTMIDI: found
PORTTIME: found
FREETYPE: found 22.1.16
So I ran this command below:
sudo apt-get install libsdl2-mixer-dev libsdl2-image-dev libsdl2-ttf-dev
To wrap up the missing dependencies

Installing octave in termux, "Unable to correct problems, you have held broken packages"

I am trying to install octave from the "Its Pointless" repository mentioned in the termux wiki. The repository is added successfully as far as I can tell. However, when I try the command pkg install octave I get the error "octave Depends openblas" "octave Depends arpack-ng" "Unable to correct problems, you have held broken packages"
I have run dpkg --get-selections | grep held but it doesn't return anything.
When I try to run pkg install openblas it gives the error "openblas Depends libgcc but it is not installable"
When I try to run pkg install libgcc it gives the error "package libgcc is not available but is referred to by another package, this may mean the package is missing, has been obsoleted, or is only available from another source. However, the following packages replace it: ndk-sysroot"
After searching some more I did pkg install clang but I still get the same errors. ndk-sysroot has been installed during installation of clang.
I have done apt-get autoclean, apt-get autoremove and apt-get purge but that did not do anything.
What can I do to fix this problem and install octave on my phone?
The problem got solved by itself.
I tried pkg install octave again and got a response saying "The repository https://termux.net stable Release is no longer signed."
So I ran the command bash setup-pointless-repo.sh again.
And that was it! pkg install octave is now working.

Installing node with brew fails on Mac OS Sierra

I'm trying to install node with homebrew on macOS Sierra.
I run
brew install node
After a seemingly successful install I get the following when trying to run node:
dyld: Library not loaded: /usr/local/opt/icu4c/lib/libicui18n.58.dylib
Referenced from: /usr/local/bin/node
Reason: image not found
Abort trap: 6
This is the series of incantations that eventually worked for me based on this link suggested by #robertklep and #vovkasm.
brew uninstall --force node
brew uninstall icu4c && brew install icu4c
brew unlink icu4c && brew link icu4c --force
brew install node
I'm not sure if they're all needed, but given that I can't get my machine in the previous state... I'll just leave this info here, maybe it'll be useful for somebody else.
In my case, brew upgrade node resolve the problem :)
Well I got this error trying to install #angular/cli, realized node might be out of date. Following #mircealungu 's exact steps didn't quite work for me, here is the modified version that worked for me.
brew uninstall --ignore-dependencies --force node
brew uninstall --ignore-dependencies --force icu4c
brew install icu4c
brew unlink icu4c && brew link icu4c --force
brew install node
Upgrading node fixed a problem.
brew upgrade node
I recently encountered a similar issue (after doing
brew switch node 9.8.0 to downgrade to a previous version of node)
dyld: Library not loaded:
/usr/local/opt/icu4c/lib/libicui18n.60.dylib
Referenced from: /usr/local/bin/node
Reason: image not found
Abort trap: 6
The issue is that node is picky about which version of icu4c it's looking for, and the version I had installed (62) was higher than node was expecting.
To fix, I made sure I had version 60 of icu4c selected.
First I found which versions I had with brew info icu4c, then did
brew switch icu4c 60.2 to select the one node was expecting.
For me it was apparently a problem with the icu4c installation from brew.
brew reinstall icu4c
will reinstall icu4c.
if you don't have it installed,
brew install icu4c
Seems file /usr/local/opt/icu4c/lib/libicui18n.58.dylib does not exists in you system.
Please ensure that icu4c installed with Homebrew.
brew info icu4c
If already installed, try reinstall: brew reinstall icu4c
If not installed, try install: brew install icu4c
For high seirra, just "brew upgrade" makes magic!
First I uninstall node and icu4c, force to uninstall all versions
brew uninstall --force --ignore-dependencies node icu4c
After install version 8 of Node
brew install node#8
If it already install, please just upgrade
brew upgrade node#8
And enter
node -v
v8.11.1
This was triggered for me after a brew upgrade and brew update ran. I was able to fix it by simply re-installing the two items flagged as problems (which made sense to me):
brew reinstall node
brew reinstall icu4c
None of the above worked for me. I'm using High Sierra.
What fixed it for me was brew upgrade
I found a solution that works great over here. I'll briefly give the commands below.
First, cd into the homebrew formula directory:
cd $(brew --prefix)/Homebrew/Library/Taps/homebrew/homebrew-core/Formula
Git log:
git log --follow icu4c.rb
Choose the commit hash that matches the version you need. I needed version 61.1, thus chose the 6d9815 commit:
git checkout -b icu4c-61.1 6d9815
Reinstall:
brew reinstall ./icu4c.rb
Switch:
brew switch icu4c 61.1
That fixed it for me.
Credit: hanxue
Nothing worked for me but running this worked
brew link --overwrite node
brew uninstall --force node
brew uninstall --ignore-dependencies icu4c
brew unlink icu4c && brew link icu4c --force
brew install node
This error was given to me after migrating machines.
Even though everything was installed, when I went to check node -v or npm version, I'd get this error.
What fixed it was brew reinstall icu4c.
I had the same problem with my local php installation.
dyld: Library not loaded: /usr/local/opt/icu4c/lib/libicui18n.62.dylib
Referenced from: /usr/local/bin/php
Reason: image not found
Abort trap: 6
Solved the problem with this command. (check your version)
brew link --overwrite --force php#7.1
I removed export PATH="/usr/local/opt/icu4c/bin:$PATH" from my ~/.bash_profile file and it fixed my problem.
My error was:
dyld: Library not loaded: /usr/local/opt/icu4c/lib/libicui18n.63.dylib
Referenced from: /usr/local/opt/node#10/bin/node
Reason: image not found
Abort trap: 6
My /usr/local/opt/icu4c/lib contains libicui18n.64.dylib
I fixed by
cd /usr/local/Cellar
rm -rf node*/
rm -rf icu4c/
brew install node
it seems like your icu4u Reference path is not set properly
first check you might instal icu4c or not by putting below comment in comment promt
brew info icu4c
or else reinstall
brew reinstall icu4c
If you need to have this software first in your PATH run:
echo 'export PATH="/usr/local/opt/icu4c/bin:$PATH"' >> ~/.bash_profile
hope This might help !!!!!
It's as easy as a common software, just download installation package from official site:NodeJS
and then download a recommended version(currently 8.11.3, end with .pkg), install it as a common software, then u can use it. I tried so many methods, and only this works for me.
Try restarting your machine. That helped me.
i run this on macos:
git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow
it takes around 20 minu

Resources