jessek / hashdeep

Other
709 stars 132 forks source link

configure script broken on OSX with gcc 4.2.1 #299

Open k6mxd opened 11 years ago

k6mxd commented 11 years ago

autoconf generated config fails (all the way back to 2.0) with this output from config.log:

configure:2091: gcc --version </dev/null >&5 i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2094: $? = 0 configure:2096: gcc -v </dev/null >&5 Using built-in specs. Target: i686-apple-darwin11 Configured with: /private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/src/configure --disable-checking --enable-werror --prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2 --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin11 --enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/dst-llvmCore/Developer/usr/local --program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11 --target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1 Thread model: posix gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) configure:2099: $? = 0 configure:2101: gcc -V </dev/null >&5 llvm-gcc-4.2: argument to `-V' is missing configure:2104: $? = 1 configure:2127: checking for C compiler default output file name configure:2130: gcc conftest.c >&5 ld: library not found for -lcrt1.10.6.o collect2: ld returned 1 exit status

maybe have an osx make that doesn't rely on autoconfig?

simsong commented 11 years ago

First, Apple's tools are increasingly out-of-date and non-standard. I suggest you try compiling with clang / clang++. You should also install autoconf / automake / etc / out of macports.

However, I do not have a problem with the script:

Mucha ~/gits/hashdeep $ ./configure checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... ./install-sh -c -d checking for gawk... no checking for mawk... no checking for nawk... no checking for awk... awk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o ... checking for pthread.h... yes checking for pthread_create in -lpthreadGC2... no checking for pthread_win32_process_attach_np... no checking for pthread_win32_process_detach_np... no checking for pthread_win32_thread_attach_np... no checking for pthread_win32_thread_detach_np... no configure: XXXXXXXX DROPPING OPTIMIZATION FLAGS XXXXXXXX checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile config.status: creating src/Makefile config.status: creating man/Makefile config.status: creating tests/Makefile config.status: creating tests/testfiles/Makefile config.status: creating config.h

config.status: executing depfiles commands

./configure finished at Wed Aug 14 12:03:07 EDT 2013 PACKAGE_NAME: MD5DEEP PACKAGE_VERSION: 4.4-beta1 CC: gcc CXX: g++ CPPFLAGS: -D_THREAD_SAFE -pthread -I/opt/local/include -I/usr/local/include -DUTC_OFFSET=-0400 CFLAGS: -D_THREAD_SAFE -pthread -g -MD -D_FORTIFY_SOURCE=2 -Wpointer-arith -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wwrite-strings -Wcast-align -Waggregate-return -Wbad-function-cast -Wcast-qual -Wundef -Wredundant-decls -Wdisabled-optimization -Wfloat-equal -Wmissing-format-attribute -Wmultichar -Wc++-compat -Wmissing-noreturn -funit-at-a-time CXXFLAGS: -D_THREAD_SAFE -pthread -g -Wall -MD -D_FORTIFY_SOURCE=2 -Wpointer-arith -Wshadow -Wwrite-strings -Wcast-align -Wredundant-decls -Wdisabled-optimization -Wfloat-equal -Wmultichar -Wmissing-noreturn -Wstrict-null-sentinel -Woverloaded-virtual -Wsign-promo -funit-at-a-time LIBS: LDFLAGS: -L/opt/local/lib -L/usr/local/lib

It also builds with no problem:

Mucha ~/gits/hashdeep $ make make all-recursive Making all in src gcc -DHAVE_CONFIG_H -I. -I.. -D_THREAD_SAFE -pthread -I/opt/local/include -I/usr/local/include -DUTC_OFFSET=-0400 -D_THREAD_SAFE -pthread -g -MD -D_FORTIFY_SOURCE=2 -Wpointer-arith -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wwrite-strings -Wcast-align -Waggregate-return -Wbad-function-cast -Wcast-qual -Wundef -Wredundant-decls -Wdisabled-optimization -Wfloat-equal -Wmissing-format-attribute -Wmultichar -Wc++-compat -Wmissing-noreturn -funit-at-a-time -MT md5.o -MD -MP -MF .deps/md5.Tpo -c -o md5.o md5.c gcc -DHAVE_CONFIG_H -I. -I.. -D_THREAD_SAFE -pthread -I/opt/local/include -I/usr/local/include -DUTC_OFFSET=-0400 -D_THREAD_SAFE -pthread -g -MD -D_FORTIFY_SOURCE=2 -Wpointer-arith -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wwrite-strings -Wcast-align -Waggregate-return -Wbad-function-cast -Wcast-qual -Wundef -Wredundant-decls -Wdisabled-optimization -Wfloat-equal -Wmissing-format-attribute -Wmultichar -Wc++-compat -Wmissing-noreturn -funit-at-a-time -MT sha1.o -MD -MP -MF .deps/sha1.Tpo -c -o sha1.o sha1.c ... g++ -D_THREAD_SAFE -pthread -g -Wall -MD -D_FORTIFY_SOURCE=2 -Wpointer-arith -Wshadow -Wwrite-strings -Wcast-align -Wredundant-decls -Wdisabled-optimization -Wfloat-equal -Wmultichar -Wmissing-noreturn -Wstrict-null-sentinel -Woverloaded-virtual -Wsign-promo -funit-at-a-time -L/opt/local/lib -L/usr/local/lib -o hashdeep md5.o sha1.o sha256.o sha3.o whirlpool.o tiger.o main.o hashlist.o multihash.o display.o hash.o dig.o helpers.o xml.o files.o threadpool.o winpe.o
g++ -D_THREAD_SAFE -pthread -g -Wall -MD -D_FORTIFY_SOURCE=2 -Wpointer-arith -Wshadow -Wwrite-strings -Wcast-align -Wredundant-decls -Wdisabled-optimization -Wfloat-equal -Wmultichar -Wmissing-noreturn -Wstrict-null-sentinel -Woverloaded-virtual -Wsign-promo -funit-at-a-time -L/opt/local/lib -L/usr/local/lib -o tigerdeep md5.o sha1.o sha256.o sha3.o whirlpool.o tiger.o main.o hashlist.o multihash.o display.o hash.o dig.o helpers.o xml.o files.o threadpool.o winpe.o
Making all in tests make[2]: Nothing to be done for all'. Making all in man make[2]: Nothing to be done forall'. Making all in tests/testfiles make[2]: Nothing to be done for all'. make[2]: Nothing to be done forall-am'. Mucha ~/gits/hashdeep $

Suggest that the problem is your system.

On Aug 14, 2013, at 11:00 AM, k6mxd notifications@github.com wrote:

autoconf generated config fails (all the way back to 2.0) with this output from config.log:

configure:2091: gcc --version &5 i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2094: $? = 0 configure:2096: gcc -v &5 Using built-in specs. Target: i686-apple-darwin11 Configured with: /private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/src/configure --disable-checking --enable-werror --prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2 --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin11 --enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.11~182/dst-llvmCore/Developer/usr/local --program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11 --target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1 Thread model: posix gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) configure:2099: $? = 0 configure:2101: gcc -V &5 llvm-gcc-4.2: argument to `-V' is missing configure:2104: $? = 1 configure:2127: checking for C compiler default output file name configure:2130: gcc conftest.c >&5 ld: library not found for -lcrt1.10.6.o collect2: ld returned 1 exit status

maybe have an osx make that doesn't rely on autoconfig?

— Reply to this email directly or view it on GitHub.