I've successfully built Zcash on OS X... Ask me anything!

Could you please post on this forum a step by side guide on how you installed Zcash on os x.

Will do when I'll have some time.. I should have it done by the end of the weekend.


PleasePlease! I'm waiting on this.

I'm very curios too, paging @adam -- Going to try and build it myself soon.

@adam Did you get around to writing this guide? I've been scouring the forum with no luck. If so, please reply with a link so I and others may easily follow.

Thanks Adam!

The key is to use only GCC... you have to replace e.g. in /usr/local/bin/... gcc-5 and g++-5 with gcc bacisally... It is because of different standard libraries (I hope I am explaining it well) and fucked-up libsnark which cannot be compiled with clang :frowning: So the "easiest" and "least painful" solution is - system-wide replacement of clang with gcc... (install it with brew) Minor patches or paths on the way of course...

Let me know if it doesn't work for you - I'll give you a solution if you run into similar issues...

E.g.: build.sh

set -ex

# cd "$(dirname "$(readlink -f "$0")")/.."
cd /Users/adam/Dev/zcash

or fetchparams.sh (shasum -> sha256sum)

# Now verify their hashes:
echo 'Verifying parameter file integrity via sha256sum...'
sha256sum --check - <<EOF
7844a96933979158886a5b69fb163f49de76120fa1dcfc33b16c83c134e61817  regtest/$REGTEST_PKEY_NAME
7844a96933979158886a5b69fb163f49de76120fa1dcfc33b16c83c134e61817  testnet3/$REGTEST_PKEY_NAME
6902fd687bface72e572a7cda57f6da5a0c606c7b9769f30becd255e57924f41  regtest/$REGTEST_VKEY_NAME
6902fd687bface72e572a7cda57f6da5a0c606c7b9769f30becd255e57924f41  testnet3/$REGTEST_VKEY_NAME

Thanks a lot Adam, I'll try it out this weekend and see where I get.

Do you know what the problem is with libsnark and clang? https://github.com/scipr-lab/libsnark claims that it has been tested with clang 3.4, although I would suggest using clang 3.8+ for more complete OpenMP support. It might be worth opening a ticket there for any specific errors you get.

(But yes, using gcc/g++ is the path of least resistance for now.)

Glad to see the team pay attention to this. I run OS X daily and native support would be great!

Unfortunately not.. :frowning: It needs somebody with more stronger background than me..

Two questions, Sir
1. How to sync up zcash blockchain? Is it automatic?
2. How to check sync up status, is it this command? ./zcash-cli getblockcount?

No idea.. Not related to buildin imho...

Complete newbie here... Is it worth it for me to buy a new MacBook Pro for mining Z? I'm not looking to be a pro miner, but would like to get some kind of return. I really don't want to miss out again. I tried to buy Bitcoin when it was 1bit/$1 and couldn't figure it out. I'm still liking myself to this day. This seems like a good currency, and I'd like to get in from the beginning. Any help would be greatly appreciated. Thanks in advance

1 Like

If you simply want to buy a computer for mining Zcash a MacBook pro would probably not be the best option. You would want something that you can expand/ add to easily and can take the abuse of running 100% 24/7.

1 Like

Any suggestions? I need a new one, so I was hoping to get one for this purpose.. And if it doesn't pan out, hopefully I'll still have a decent laptop

I don't like to give specific hardware advice but here are things to consider: Mining is very hard on hardware, a Laptop is likely to run hot and possibly overheat if it's mining 24/7. If in the future GPU mining becomes the best way to be profitable you won't have the option to add a graphics card.
If you want to use a MacBook as a computer for your everyday use then that is fine, but it may only be able to mine successfully for a very short period of time. As difficulty increases the likelihood of finding block greatly decreases with set hardware.

1 Like

Ok. Thanks for the advice.

I'm attempting to build zcash using macports gcc5 on OSX and ran into this issue http://pastebin.com/gDtfpFYB while attempting to build libsnark.

Has anyone else run into this?

edit: is this related to clang?

It depends.. Might be, find out what is your c++ in that build script scope.. e.g. $ which c++

MacBook-Pro:zcash mugatu $ which c++
MacBook-Pro:zcash mugatu$ c++ -v
Using built-in specs.
Target: x86_64-apple-darwin15
Configured with: /opt/local/var/macports/build/_opt_mports_dports_lang_gcc5/gcc5/work/gcc-5.4.0/configure --prefix=/opt/local --build=x86_64-apple-darwin15 --enable-languages=c,c++,objc,obj-c++,lto,fortran,java --libdir=/opt/local/lib/gcc5 --includedir=/opt/local/include/gcc5 --infodir=/opt/local/share/info --mandir=/opt/local/share/man --datarootdir=/opt/local/share/gcc-5 --with-local-prefix=/opt/local --with-system-zlib --disable-nls --program-suffix=-mp-5 --with-gxx-include-dir=/opt/local/include/gcc5/c++/ --with-gmp=/opt/local --with-mpfr=/opt/local --with-mpc=/opt/local --with-isl=/opt/local --enable-stage1-checking --disable-multilib --enable-lto --enable-libstdcxx-time --with-build-config=bootstrap-debug --with-as=/opt/local/bin/as --with-ld=/opt/local/bin/ld --with-ar=/opt/local/bin/ar --with-bugurl=https://trac.macports.org/newticket --with-pkgversion='MacPorts gcc5 5.4.0_0'
Thread model: posix
gcc version 5.4.0 (MacPorts gcc5 5.4.0_0)