Configure Error on iostream - iostream

I have recently installed Ubuntu 14.04 64bit and tried to compile MPICH from the source using Intel Compilers 2013. I use this command to configure mpich:
./configure CC=icc CXX=icpc F77=ifort FC=ifort -prefix=/home/user/mpich-install
and I get this error after a while:
.
.
checking whether <iostream> available... no
checking how to run the C++ preprocessor... icpc -E
checking iostream.h usability... no
checking iostream.h presence... no
checking for iostream.h... no
configure: error: C++ compiler icpc has neither iostream nor iostream.h.
configure: error: ./configure failed for test/mpi

It seems that this is a known issue in Intel C++ compiler 14 update 1. It can be solved by updating to ICC 14 update 2. check this link for more information:
software.intel.com/en-us/forums/topic/531138#comment-1799768

Related

GCC 9.2.0 build error : incorrect version of gmp.h while the version is actually correct

I am trying to build a cross-compiler and I chose gcc-9.2.0
So when i run ( from the OSDev Wiki)
../gcc-9.2.0/configure --target=x86_64-elf --prefix="$HOME/opt/cross" --disable-nls --enable-languages=c,c++ --without-headers
I got this error
checking how to compare bootstrapped objects... cmp --ignore-initial=16 $$f1 $$f2
checking for objdir... .libs
checking for the correct version of gmp.h... no
configure: error: Building GCC requires GMP 4.2+, MPFR 2.4.0+ and MPC 0.8.0+.
Try the --with-gmp, --with-mpfr and/or --with-mpc options to specify
their locations.
So I checked the gmp.h library and the version is 6.2.0
#define __GNU_MP_VERSION 6
#define __GNU_MP_VERSION_MINOR 2
#define __GNU_MP_VERSION_PATCHLEVEL 0
Then i tried to use the --with-gmp option, but i got the same error
My platfrom : Windows 10 64-bit
I use Cygwin-x86_64 as a bash emulator
Ok so i found what was wrong. I had installed another gcc compiler for Code::Blocks and it was in PATH variable, so ./configure took this compiler and not the cygwin's

How to accurately make configure script use the updated gcc version on CentOS?

I have followed instructions provided in other articles to fix the below issue but still doesn't appear to work for my system. I am trying to upgrade glibc to v2.27 on my CentOS 7.3 machine. I downloaded the package and running into the below compiler dependency during the configure script execution:
../configure --prefix=/opt/glibc-2.27
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking for gcc... gcc
...
...
checking if gcc is sufficient to build libc... no
checking for nm... nm
checking for python3... no
checking for python... python
configure: error:
*** These critical programs are missing or too old: compiler
*** Check the INSTALL file for required versions.
So I upgraded my gcc and verified the upgraded version:
gcc --version
gcc (GCC) 8.2.0
I also have the following environment variable set in my bashrc:
export CC=/usr/local/bin/gcc
For some reason, the configure script still throws the same error based on which it appears that the upgraded gcc version isn't being used.
What am I missing?

rgdal won't install on AWS RStudio AMI

I have managed to successfully launch the most recent RStudio AWS EC2 instance (louisaslett.com, RStudio-1.1383_R-3.4.2…ubuntu-16.04-LTS-64). R operates mostly as expected in this instance, and I can install and open a number of packages. However I get an error if I try to install either of the rgdal of gdalUtils packages.
Below is the console output when I attempt to install rgdal. The output for the gdalUtils install is too long to include here, but both include the text "error: upgrade GDAL to 1.11.4 or later" which I suspect is the problem, but have no idea how to correct.
Any thoughts or advice would be greatly appreciated.
Cheers
> install.packages("rgdal")
Installing package into ‘/home/rstudio/R/x86_64-pc-linux-gnu-library/3.4’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/src/contrib/rgdal_1.3-3.tar.gz'
Content type 'application/x-gzip' length 1670656 bytes (1.6 MB)
==================================================
downloaded 1.6 MB
* installing *source* package ‘rgdal’ ...
** package ‘rgdal’ successfully unpacked and MD5 sums checked
checking for g++... g++
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 whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
configure: CC: gcc -std=gnu99
configure: CXX: g++
configure: rgdal: 1.3-3
checking for /usr/bin/svnversion... yes
configure: svn revision: 759
checking whether g++ supports C++11 features by default... no
checking whether g++ supports C++11 features with -std=gnu++11... yes
configure: C++11 support available
checking for gdal-config... /usr/bin/gdal-config
checking gdal-config usability... yes
configure: GDAL: 1.11.3
checking GDAL version >= 1.11.4... no
configure: error: upgrade GDAL to 1.11.4 or later
ERROR: configuration failed for package ‘rgdal’
* removing ‘/home/rstudio/R/x86_64-pc-linux-gnu-library/3.4/rgdal’
Warning in install.packages :
installation of package ‘rgdal’ had non-zero exit status
The downloaded source packages are in
‘/tmp/RtmpGUxbcA/downloaded_packages’
I have since run into the same issue running Rstudio on the google cloud. In both cases a solution was relatively simple - install a recent but older rgdal package from cran (https://cran.r-project.org/src/contrib/Archive/rgdal/) which wasnt dependent on the most recent gdal libraries, and therefore installed without throwing the error about upgrading GDAL.

Compiling Octave 4.2.1 in linux, can't link to PCRE library with GCC 4.9.3

When running the configure script for Octave, I do:
./configure CFLAGS="-I/customlibs/pcre/gnu/8.40/include -L/customlibs/pcre/gnu/8.40/lib/" LD_LIBRARY_PATH="/customlibs/pcre/gnu/8.40/lib"
I have also tried:
./configure CFLAGS="-I/customlibs/pcre/gnu/8.40/include" LDFLAGS="-L/customlibs/pcre/gnu/8.40/lib/" LD_LIBRARY_PATH="/customlibs/pcre/gnu/8.40/lib"
Both of these produce the same failure:
checking pcre.h usability... yes
checking pcre.h presence... no
configure: WARNING: pcre.h: accepted by the compiler, rejected by the preprocessor!
configure: WARNING: pcre.h: proceeding with the compiler's result
checking for pcre.h... yes
checking pcre/pcre.h usability... no
checking pcre/pcre.h presence... no
checking for pcre/pcre.h... no
checking whether pcre.h defines the macros we need... no
configure: error: to build Octave, you must have the PCRE library and header files installed
I'm lost as to how it can find pcre.h but fails to do anything else with it. Am I doing something wrong on my configure line or is pcre broken? If it's my configure line, how do I link against pcre correctly?
For reference, here's the pcre path:
ls /customlibs/pcre/gnu/8.40/
bin
include
lib
share
I was struggling with that for a while as well, but the solution was actually very simple. just use CPPFLAGS rather than CFLAGS for include files:
./configure CPPFLAGS="-I/customlibs/pcre/gnu/8.40/include" LDFLAGS="-L/customlibs/pcre/gnu/8.40/lib/"
There's also no need for LD_LIBRARY_PATH upon configuring.

Installing image pgk on Octave on Mac OS X

I installed GNU Octave, version 4.2.0-rc2 on my Mac[0] using Homebrew[1].
But now I tried to install the image pkg[2].
I tried downloading it and then using this line:
"pkg install image-2.6.0.tar.gz"
Then I tried installing it with this line of code:
"pkg install -forge image"
Both resulted in the following output:
configure: error: *** A compiler with support for C++11 is required
checking for a sed that does not truncate output... /usr/local/bin/gsed
checking for octave... /usr/local/Cellar/octave/4.2.0-rc2/bin/octave-4.2.0-rc2
checking for mkoctfile... /usr/local/Cellar/octave/4.2.0-rc2/bin/mkoctfile-4.2.0-rc2
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 whether we are using the GNU C++ compiler... yes
checking whether clang++ -std=gnu++11 accepts -g... yes
checking for clang++ -std=gnu++11 option to enable C++11 features... unsupported
pkg: error running the configure script for image.
error: called from
install at line 200 column 5
pkg at line 392 column 9
But I think I installed GCC correctly:
gcc -v
Has the following output:
Es werden eingebaute Spezifikationen verwendet.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin15.6.0/6.2.0/lto-wrapper
Ziel: x86_64-apple-darwin15.6.0
Konfiguriert mit: ../gcc-6.2.0/configure --enable-languages=c++,fortran --with-gmp=/usr/local
Thread-Modell: posix
gcc-Version 6.2.0 (GCC)
What is my mistake? Or what have i done wrong?
[1] http://wiki.octave.org/Octave_for_MacOS_X#Homebrew
[2] http://octave.sourceforge.net/image/index.html
[0] Macbook Specifications:
MacBook Pro (13-inch, Mid 2012)
2,5 GHz Intel Core i5
16 GB 1600 MHz DDR3
macOS Sierra (Version 10.12)
I had the exact same problem. Just download the older version 2.4.1 of image and installation should work as expected.
Download Link:
https://sourceforge.net/projects/octave/files/Octave%20Forge%20Packages/Individual%20Package%20Releases/image-2.4.1.tar.gz/download

Resources