SNAPHU installation on Mac Big Sur ZSH terminal

Hello,
I want to install snaphu on my M1 macbook. I dowloaded the setup file from stanford website. I installed it using this way.
Opened terminal accessed the src directory and then “sudo make install”.
At the beginning it was showing man1 folder error so I created the man1 folder using “sudo mkdir usr/local/man/man1” and then the error got away.

Now when I type which snaphu it shows snaphu not found. Please guide. Also one thing I noticed that they way @muddasirshah did the installation it showed bash-terminal and mine shows ZSH. I am using the new m1 macbook pro having mac os Big Sur in it.

that image show that the binary was copied into /usr/local/bin… I don’t know much about MacOS but have you check if that is in the PATH?
can you try to run

/usr/local/bin/snaphu

to see if get the expected output…

you could have continued in the other thread

1 Like

Sorry about the second thread and yes the paths exist

/bin
usr/local/bin
usr/local/man
usr/local/man/man1 exists

i think it has something to do with ZSH?

When I edite the Makefile by changing any path it then shows error. So what do you suggest?

You can try running snaphu with:

/usr/local/bin/snaphu [...]

or add /usr/local/bin to the PATH environment variable. You can add directories to the PATH for all users (zsh configuration on macOS) or just for yourself in ~/.zshrc. Both bash and zsh comply with POSIX standards, so adding a directory to the PATH is done the same way (but the name if the file where the command goes will differ, see man zsh):

PATH="/usr/local/bin:$PATH"

Note that you may need to create ~/.zshrc if it doesn’t exist on your system.

1 Like

I am literally not understanding that. Please make that simple for me🥺.
Like what’s the path variable? If you can please please write it in steps and I’ll follow you. All I know is that it’s zsh based and not bash.

We had the same discussion here: Installing SNAPHU on Macbook

The path variable is a list of directories which are indexed for later use, so if there is a command inside, it is found by the system.

@gnwiii suggested to call snaphu by writing the full path to snaphu as an alternative.

1 Like

I’ll try it but not sure whether ill do it or not.

Hello,
I am trying to install SNAPHU on my mac osx Big Sur. When I enter the src folder using terminal and type “sudo make install” it shows the man folder error.
I even updated the make file directory by adding “/man1” to it still it shows this error.
I am not that good in linux, please help me it’s urgent. I am following that SNAPHU installation thread by @muddasirshah , created the man1 folder and still have no idea what’s going on. Please please please guide me

Did you change the Makefile entry /usr/local/man to /usr/local/man/man1?
If so, try changing this back and then create the /usr/local/man/man1
directory. You can do this with sudo mkdir -p /usr/local/man/man1.

1 Like

please don’t open new topics on the same questions. I merged all posts in here.

1 Like

I understand sorry about that. I have a request please teach me in step by step manner. I shall be obliged. Seems like I am not able to follow the thread you’ve mentioned. Help me!!

don’t worry, it’s not that hard.
In which directory did you install snaphu?

1 Like

I downloaded the file from stanford website. Opened terminal (zsh). In the first installation it showed error 1 as no “man1” folder was there in my system root. I created it using “sudo mkdir man1” command inside the usr/local/man directory.
and ran the setup again. This time no man1 error showed but when I typed “which snaphu” it said “snaphu not found”

Now I don’t know what to do ahead.

please type whereis snaphu

1 Like

Thank you, you’re so kind. Laptop not here with me at the moment when I get back I’ll do it. Any further guidance is more than welcome. Thank you one again Andreas :heart:

no worries, we’ll get it to work. :+1:

1 Like

Nothing!

ok, then then installation failed.

Can you please go to this location and manually create the folder for the manual?
/usr/local/man/man1/man1

grafik

1 Like

Another man folder?