Running Stack on NixOS Causes Missing C Compiler Error - haskell-stack

Running stack build and even stack --nix build on a NixOS build yields the following:
Linking /run/user/1000/stack7176/old-time-1.1.0.3/.stack-work/dist/x86_64-linux-nix/Cabal-1.22.5.0/setup/setup ...
Configuring old-time-1.1.0.3...
configure: WARNING: unrecognized options: --with-compiler, --with-gcc
checking for gcc... no
checking for cc... no
checking for cl.exe... no
configure: error: in `/run/user/1000/stack7176/old-time-1.1.0.3':
configure: error: no acceptable C compiler found in $PATH
See `config.log' for more details
I have installed gcc and clang on my system and verified that, i.e., gcc is indeed on my path. How to resolve this issue?

Related

configure: error: cannot run C compiled programs. when installing libtools-2.4.2

Have been struggling to set up my environment to run bioinformatics tools. The issue started with a consistent autogen.sh error in autoreconf -fi: command not found for multiple applications. Reinstalled autoconf, automake, libtools.
Currently, libtools installation fails at ./configure, but autoconf and automake installed successfully.
Here is the error:
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... libltdl/config/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 build system type... x86_64-apple-darwin18.0.0
checking host system type... x86_64-apple-darwin18.0.0
configure: autobuild project... GNU Libtool
configure: autobuild revision... 2.4.2 ()
configure: autobuild hostname... MACUSR
configure: autobuild mode... default
configure: autobuild timestamp... 2019011
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... configure: error: in `/usr/local/libtool-2.4.2':
configure: error: cannot run C compiled programs.
Tried Homebrew, it installed all my tools in usr/local/Cellar and nothing runs, I have added tool locations to my PATH variable, but no luck. Traced problem to jamf issue:
https://www.jamf.com/jamf-nation/discussions/28764/jamf-quickadd-symlinks-usr-local-bin-causing-install-problems-for-other-apps
Stuck and will be happy for an advice here.
Long story short, it was an old gcc problem. My PATH referenced to anaconda3/bin first, where it was triggering whatever gcc it found there. After changing my $PATH to point to other bins before anaconda3, everything compiled without issues.
gcc --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 9.1.0 (clang-902.0.39.2)
Target: x86_64-apple-darwin18.0.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin

OMNET++ installation error in Windows 10

I am trying to install omnet 5.1.1 in my windows 10 64 bit. everything was ok untill this error message showed.
/e/Mansoor/E/Simulator/omnet/omnetpp-5.1.1$ ./configure
configure: loading site script /mingw64/etc/config.site
checking build system type... x86_64-w64-mingw32
checking host system type... x86_64-w64-mingw32
configure: -----------------------------------------------
configure: reading configure.user for your custom settings
configure: -----------------------------------------------
checking for clang... no
checking for icc... no
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/e/Mansoor/E/Simulator/omnet/omnetpp-5.1.1':
configure: error: C compiler cannot create executables
See `config.log' for more details
Kindly suggest me how may i debug this?

Building Bochs on MacOSX Marverics

I am building Bochs2.3.7 on my MacOS10.9.2(Marverics) I got .tar.gz file from
http://sourceforge.net/projects/bochs/files/bochs/2.3.7/
Then, when I did
./configure --with-x11
I got following message
ERROR: X windows gui was selected, but X windows libraries were not found.
I tried
sh .conf.macosx
too but I got this message
checking build system type... i386-apple-darwin13.1.0
checking host system type... i386-apple-darwin13.1.0
checking target system type... i386-apple-darwin13.1.0
checking if you are configuring for another platform... no
checking for standard CFLAGS on this platform... -fpascal-strings -fno-common -Wno-four-char- constants -Wno-unknown-pragmas -Dmacintosh
checking for gcc... gcc
checking for C compiler default output file name... configure: error: C compiler cannot create executables
See `config.log' for more details.
I already installed XQuartz and Xcode but I couldn't build Bochs. Does anyone know how to solve this ploblem?

CYGWIN error: C compiler cannot create executables

I try to compile mono using cygwin(manual), but I get the following output:
checking whether the C compiler works... no
configure: error: in `/cygdrive/a/TempForCompile/mono-master':
configure: error: C compiler cannot create executables
See `config.log' for more details
Some parts of config.log:
gcc: error: unrecognized command line option '-mno-cygwin'
gcc: error: unrecognized command line option '-V'
How to fix this issue and compile mono?

Why do I get a configure error when installing Ruby 1.9.3?

Anyone have an idea as to what this error means? I'm attempting to install Ruby 1.9.3
Error running ' ./configure --prefix=/Users/coreycallahan/.rvm/rubies/ruby-1.9.3-p125 --enable-shared --disable-install-doc --with-libyaml --with-opt-dir=/Users/coreycallahan/.rvm/usr ', please read /Users/coreycallahan/.rvm/log/ruby-1.9.3-p125/configure.log
There has been an error while running configure. Halting the installation.
$ cat /Users/coreycallahan/.rvm/log/ruby-1.9.3-p125/configure.log
[2012-04-10 11:10:33] ./configure --prefix=/Users/coreycallahan/.rvm/rubies/ruby-1.9.3-p125 --enable-shared --disable-install-doc --with-libyaml --with-opt-dir=/Users/coreycallahan/.rvm/usr
configure: WARNING: unrecognized options: --with-libyaml
checking build system type... i386-apple-darwin11.3.0
checking host system type... i386-apple-darwin11.3.0
checking target system type... i386-apple-darwin11.3.0
checking whether the C compiler works... no
configure: error: in `/Users/coreycallahan/.rvm/src/ruby-1.9.3-p125':
configure: error: C compiler cannot create executables
See `config.log' for more details
configure: error: C compiler cannot create executables
Do you have permission to write in the directory where you're compiling?

Resources