Closed grempe closed 14 years ago
Updated per adamv's request and pushed to the same commit sha1 in my fork (git commit --amend)
http://github.com/grempe/homebrew/commit/388804b7ed4c0d5aa58d6046b37ec8d6a263458a
Correction, its not at the same sha1 as earlier. The update is found at the location shown in my previous comment : 388804b7ed4c0d5aa58d6046b37ec8d6a263458a
Updated once more to modify makefile. Now passes supported -DNOMLOCK compiler option which avoids compiling using an unsupported on OS X memory locking option. This eliminates the warning previously shown on every run of the command as mentioned in my initial comments above. Updated code is at:
cfc47e2926c3bd3c449df812930f1ec4dbdf5ca2
gmp.h header not found in non /usr/local
/usr/bin/cc -W -DNOMLOCK -W -DNOMLOCKall -O2 -lgmp -o ssss-split ssss.c
xmltoman ssss.manpage.xml > ssss.1
ssss.c:51:17: error: gmp.h: No such file or directory
0xffea, you need to have installed the 'gmp' homebrew package. It is listed in this recipe as a dependency.
i think i have it installed. it works for u outside /usr/local? LDFLAGS and CFLAGS should be set so the compiler can find the headers.
I ran the following, and the binaries that get installed are running fine:
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ brew install ssss
==> Downloading http://point-at-infinity.org/ssss/ssss-0.5.tar.gz
File already downloaded and cached to /Users/glenn/Library/Caches/Homebrew
==> make
/usr/local/Cellar/ssss/0.5: 6 files, 56K, built in 2 seconds
Here is the output of running the prog:
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ ssss-combine -v
Combine shares using Shamir's Secret Sharing Scheme.
ssss-combine -t threshold [-x] [-q] [-Q] [-D] [-v]
Version: 0.5
I have the following two dependencies installed which are required, gmp, and xmltoman (a recipe which I submitted and was approved recently)
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ brew info gmp
gmp 5.0.1
http://gmplib.org/
/usr/local/Cellar/gmp/5.0.1 (10 files, 2.3M)
http://github.com/grempe/homebrew/commits/master/Library/Formula/gmp.rb
and
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ brew info xmltoman
xmltoman 0.4
http://sourceforge.net/projects/xmltoman/
/usr/local/Cellar/xmltoman/0.4 (10 files, 60K)
http://github.com/grempe/homebrew/commits/master/Library/Formula/xmltoman.rb
My in development 'ssss' recipe is living in the following location:
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ ls -la /usr/local/Library/Formula/ssss.rb
-rw-r--r--@ 1 glenn staff 606 Jul 31 16:29 /usr/local/Library/Formula/ssss.rb
If I uninstall ssss and gmp from my system brew does the right thing and works when I re-install just ssss.
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ brew uninstall gmp
Uninstalling /usr/local/Cellar/gmp/5.0.1...
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ brew uninstall ssss
Uninstalling /usr/local/Cellar/ssss/0.5...
glenn@mbp ~/src/git/ssss [1.9.2][master*]$ brew install ssss
==> Downloading ftp://ftp.gnu.org/gnu/gmp/gmp-5.0.1.tar.bz2
File already downloaded and cached to /Users/glenn/Library/Caches/Homebrew
==> ./configure --prefix=/usr/local/Cellar/gmp/5.0.1 -- infodir=/usr/local/Cellar/gmp/5.0.1/share/info --enable-cxx
==> make
==> make install
==> make check
/usr/local/Cellar/gmp/5.0.1: 10 files, 2.3M, built in 2.4 minutes
==> Downloading http://point-at-infinity.org/ssss/ssss-0.5.tar.gz
File already downloaded and cached to /Users/glenn/Library/Caches/Homebrew
==> make
/usr/local/Cellar/ssss/0.5: 6 files, 56K, built in 2 seconds
glenn@mbp ~/src/git/ssss [1.9.2][master*]$
I am not really an expert on LDFLAGS or CFLAGS so I'm not really sure what you are suggesting to do there. Neither of these were set in the original makefile and things seem to be working well for me. Perhaps there is something different in your system environment? Do you have 'gmp' installed via homebrew, or via another mechanism?
thanks for the detailed answer. u install into /usr/local so the headers are found. if u install into some other place the headers cant be found. maybe i fix this tomorrow. thanks again
added CFLAGS and pushed.
The updated version of this recipe does not seem to be working any longer after checkin. I get the following error:
glenn@mbp ~/Desktop [ruby-1.9.2-p0]$ brew install ssss
==> Downloading http://point-at-infinity.org/ssss/ssss-0.5.tar.gz
File already downloaded and cached to /Users/glenn/Library/Caches/Homebrew
==> make
/usr/bin/cc -W -DNOMLOCK -O3 -w -pipe -I/usr/local/include -W -DNOMLOCK -O3 -w -pipe -I/usr/local/include all -O2 -lgmp -o ssss-split ssss.c
xmltoman ssss.manpage.xml > ssss.1
xmlmantohtml ssss.manpage.xml > ssss.1.html
i686-apple-darwin10-gcc-4.2.1: all: No such file or directory
make: *** [ssss-split] Error 1
make: *** Waiting for unfinished jobs....
Exit status: 2
http://github.com/mxcl/homebrew/blob/master/Library/Formula/ssss.rb#L19
==> Environment
HOMEBREW_VERSION: 0.7
HEAD: c99b3aca44e4a48b7c1a8faadc5efe603ac5a100
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
HOMEBREW_REPOSITORY: /usr/local
HOMEBREW_LIBRARY_PATH: /usr/local/Library/Homebrew
Hardware: quad-core 64-bit arrandale
OS X: 10.6.4
Kernel Architecture: i386
Ruby: 1.8.7-174
/usr/bin/ruby => /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
GCC-4.0: build 5494
GCC-4.2: build 5664
LLVM: build 2333
MacPorts or Fink? false
X11 installed? true
==> Build Flags
CC: /usr/bin/cc => /usr/bin/gcc-4.2
CXX: /usr/bin/c++ => /usr/bin/c++-4.2
LD: /usr/bin/cc => /usr/bin/gcc-4.2
CFLAGS: -O3 -w -pipe -I/usr/local/include
CXXFLAGS: -O3 -w -pipe
MAKEFLAGS: -j4
Error: Failure while executing: make
Please report this bug at http://github.com/mxcl/homebrew/issues
Also try:
`brew doctor` to check your setup for common problems.
`brew missing` to check installed packages for missing deps.
glenn@mbp ~/Desktop [ruby-1.9.2-p0]$
0xffea, do you have commit access? If so, it would have been good if you had responded to grempe about breaking this formula.
I'll probably revert to his version later tonight.
his version does not build outside of /usr/local. i just added CFLAGS. Seems something is wrong in the makefile.
Sorry, I'm a bit confused as to what has happened here. Does the latest version build for you? It doesn't for me either.
yes, outside of /usr/local. i cant test it in /usr/local.
Why not?
To clarify further, this is our recommended location and the place that 95% of our users (if not more) will install to. If you can't test there, arguably you can't really test in a useful fashion.
New install formula for ssss program.
Can be pulled from my branch here: http://github.com/grempe/homebrew/commit/33e82c43c6ced5beba2acaa0ace54a9feaf48fb1
Depends on: gmp (already in homebrew) xmltoman (added by me earlier today in another issue)
For more info on the program see: http://point-at-infinity.org/ssss/
Tested on OS X 10.6.4
Note: There is a warning shown at runtime. This is expected behavior when running on OS X and does not represent an issue with the installation. From the man page: