Octave forge packages installation - octave

I'm trying to install image-2.6.1 package to GNU Octave, version 4.0.0. I downloaded image-2.6.1.tar.gz and tried to install it with
pkg install /home/vladimirmatveev/Downloads/image-2.6.1.tar.gz
but get an error.
configure: error: in `/tmp/oct-BAtlFb/image-2.6.1/src':
configure: error: C++ compiler cannot create executables
See `config.log' for more details
checking for a sed that does not truncate output... /bin/sed
checking for octave... /usr/bin/octave
checking for mkoctfile... /usr/bin/mkoctfile
checking whether the C++ compiler works... no
pkg: error running the configure script for image.
error: called from 'configure_make' in file /usr/share/octave/4.0.0/m/pkg/private/configure_make.m near line 79, column 9
I am sure I have C/C++ compilers, they are gcc and g++ (when I am trying to install them with apt-get it says I already have a newest version and I am sure it is true).
I tried to set c/c++ compilers to system variables with
export CC=/usr/bin/gcc-4.8
export CXX=/usr/bin/g++-4.8
or
export CC=/usr/bin/gcc-5
export CXX=/usr/bin/g++-5
(I have both versions) but it didn't helped. It usually works for me when cmake can not find a compiler.
I found im-config.log file, but it contains only
Script for ibus started at run_im.
Script for auto started at run_im.
Script for default started at run_im.
I am not sure this is that config file which was mentioned in error message, but it is the only file which has suitable modification date.
I am working at ubuntu 16.04.
I unpackaged .tar.gz, cd to it and to src/, then run ./configure and there was no troubles found while checking compiler, here is the console log.
checking for a sed that does not truncate output... /bin/sed
checking for octave... /usr/bin/octave
checking for mkoctfile... /usr/bin/mkoctfile
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 /usr/bin/g++-5 accepts -g... yes
checking for /usr/bin/g++-5 option to enable C++11 features... -std=gnu++11
checking whether xmin is in the octave::math namespace... no
checking whether templated lambda functions accept '&const int'... yes
configure: creating ./config.status
config.status: creating im2double.m
config.status: creating Makefile
config.status: creating config.h
Here is full config log http://pastebin.com/u6MNSqCB

Related

How to force ./configure to use intel oneAPI compilers?

I recently installed IntelĀ® oneAPI Base Toolkit and IntelĀ® oneAPI HPC Toolkit using the cimmands:
sudo yum install intel-basekit
sudo yum install intel-hpckit
The packages are installed in /opt/intel/oneapi
but when I run ./configure it usually specifies other compilers:
directory QEHeat/src : ok okkokCI : ok
directory ACFDT/src : not present in /rhome/pkgs/QE/qe-7.1/install
directory KCW/PP : okk
all dependencies updated successfully
checking build system type... x86_64-pc-linux-gnu
checking ARCH... x86_64
checking setting AR... ... ar
checking setting ARFLAGS... ... ruv
checking for gfortran... gfortran
checking whether the Fortran compiler works... yes
checking for Fortran 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 Fortran compiler... yes
checking whether gfortran accepts -g... yes
checking for mpiifort... no
checking for mpif90... no
checking for ifort... no
checking for nvfortran... no
checking for pgf90... no
checking for nagfor... no
checking for gfortran... gfortran
checking whether we are using the GNU Fortran compiler... yes
checking whether gfortran accepts -g... yes
checking version of gfortran... gfortran 4.8
checking for Fortran flag to compile .f90 files... none
setting F90... gfortran
setting MPIF90... gfortran
checking for cc... cc
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
setting CC... cc
setting CFLAGS... -O3
using F90... gfortran
setting FFLAGS... -O3 -g
setting F90FLAGS... $(FFLAGS) -cpp
setting FFLAGS_NOOPT... -O0 -g
setting CPP... cpp
setting CPPFLAGS... -P -traditional -Uvector
setting LD... gfortran
setting LDFLAGS... -g
checking whether make sets $(MAKE)... yes
checking whether Fortran files must be preprocessed... no
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether gfortran accepts -g... yes
checking for library containing dgemm... no
MKL not found
in /opt/intel/mkl/lib/intel64: checking for library containing dgemm... no
MKL not found
checking for library containing dgemm... no
in /usr/local/lib: checking for library containing dgemm... no
checking for library containing dgemm... -lblas
setting BLAS_LIBS... -lblas
checking for library containing dspev... -llapack
in /usr/local/lib: checking for library containing dspev... -llapack
checking FFT... checking for library containing dfftw_execute_dft... no
in /usr/local/lib: checking for library containing dfftw_execute_dft... no
using internal copy of FFTW
checking MASS...
checking for library containing mpi_init... no
checking ELPA...
checking for Environ... not used
checking for ranlib... ranlib
checking for wget... wget -O
setting WGET... wget -O
checking for git... git
setting DFLAGS... -D__FFTW
setting IFLAGS... -I. -I$(TOPDIR)/include -I$(TOPDIR)/FoX/finclude
configure: creating ./config.status
config.status: creating install/make_lapack.inc
config.status: creating include/configure.h
config.status: creating make.inc
config.status: creating configure.msg
config.status: creating install/make_wannier90.inc
config.status: creating include/qe_cdefs.h
--------------------------------------------------------------------
ESPRESSO can take advantage of several optimized numerical libraries
(essl, fftw, mkl...). This configure script attempts to find them,
but may fail if they have been installed in non-standard locations.
If a required library is not found, the local copy will be compiled.
The following libraries have been found:
BLAS_LIBS= -lblas
LAPACK_LIBS=-L/usr/local/lib -llapack -lblas
FFT_LIBS=
Please check if this is what you expect.
If any libraries are missing, you may specify a list of directories
to search and retry, as follows:
./configure LIBDIRS="list of directories, separated by spaces"
Parallel environment not detected \(is this a parallel machine?\).\
Configured for compilation of serial executables.
For more info, read the ESPRESSO User's Guide (Doc/users-guide.tex).
--------------------------------------------------------------------
configure: success
How to force ./configure to choose intel oneAPI compilers?
Here is a solution to your issue!
The key env vars to set
using F90... gfortran
setting FFLAGS... -O3 -g
setting F90FLAGS... $(FFLAGS) -cpp
setting FFLAGS_NOOPT... -O0 -g
so
export F90=ifort
export FFLAGS='-O3 -xhost -g'
export FFLAGS_NOOPT='-O0 -g'

configure: WARNING: FFTW3F library not found. The slower FFTPACK library will be used instead

I'm compiling octave on my LFS - Linux from scratch - system.
While configuring octave, I receive a warning:
configure: WARNING: FFTW3F library not found. The slower FFTPACK library will be used instead.
I compiled and installed FFTW 3.3.4, and then reconfigured octave, however I still receive the following messages:
checking fftw3.h usability... yes
checking fftw3.h presence... yes
checking for fftw3.h... yes
checking for fftw_plan_dft_1d in -lfftw3... yes
checking for fftw3.h... (cached) yes
checking for fftwf_plan_dft_1d in -lfftw3f... no
configure: WARNING: FFTW3F library not found. The slower FFTPACK library will be used instead.
I notice that FFTW 3.3.4 installs libfftw3.so but NOT libfftw3f.so, that's why even after installing FFTW 3.3.4, octave cannot find FFTW3F library. Now, I wonder how I can install libfftw3f.so.
It looks like you have the double precision FFTW libraries (libfftw3) but not the single precision versions (libfftw3f). Build it again with:
./configure --enable-float --enable-sse && make install
(assuming we're talking x86 here).
This should then install the libfftw3f libraries next to the existing libfftw3 libs.

configure: error: libtool configure failed

I gave ./configure in tclreadline for tclreadline2.1.0 and got this error
loading cache ./config.cache
checking for a BSD compatible install... (cached) /usr/bin/install -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... (cached) yes
checking for working aclocal... found
checking for working autoconf... found
checking for working automake... found
checking for working autoheader... found
checking for working makeinfo... found
checking whether make sets ${MAKE}... (cached) yes
checking host system type... Invalid configuration `x86_64-unknown-linux-gnu': machine `x86_64-unknown' not recognized
checking for gcc... (cached) gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for Cygwin environment... (cached) no
checking for mingw32 environment... (cached) no
checking for executable suffix... (cached) no
checking build system type... Invalid configuration `x86_64-unknown-linux-gnu': machine `x86_64-unknown' not recognized
checking for ranlib... (cached) ranlib
checking for ld used by GCC... (cached) /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... (cached) yes
checking for BSD-compatible nm... (cached) /usr/bin/nm -B
checking whether ln -s works... (cached) yes
loading cache ./config.cache within ltconfig
checking host system type... Invalid configuration `x86_64-unknown-linux-gnu': machine `x86_64-unknown' not recognized
configure: error: libtool configure failed
Please suggest what to done to compile properly
Thanks for the help in advance
Found the answer here. To get old configure scripts working, you can update the config.sub file:
curl 'http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD' > config.sub
This will replace the config.sub script with the latest version.
The package looks like it hasn't been maintained in a long time. Consequently, the autotools used to build the configure script and auxiliary files probably aren't even aware of x86-64.
Assuming you have the autotools installed - autoconf, automake, libtool, etc. - you could try running autoreconf -ivf, and then attempting ./configure again. You'll probably get a lot of warnings about out-of-date macros, etc. But it might work.

Unable to compile mysql-proxy into an rpm

I am trying to compile and package mysql-proxy-0.8.4.tar.gz into rpm. I followed the instructions to build
[root#localhost mysql-proxy]# rpmbuild -ta --clean mysql-proxy-0.8.4.tar.gz
I get this error
checking which pkg-config file to use to find Lua... configure: error: MySQL Proxy can't be built using --without-lua, lua 5.1 is required
error: Bad exit status from /var/tmp/rpm-tmp.r6iTWn (%build)
RPM build errors:
Bad exit status from /var/tmp/rpm-tmp.r6iTWn (%build)
I checked my build machine and I have all the build dependencies, I can see that pkg-config listing lua libraries
[root#localhost mysql-proxy]# pkg-config --list-all | less
lua Lua - An Extensible Extension Language
Could someone let me know what am I missing?
That error is telling you that you might need to pass --with-lua to rpmbuild when you build the package.
You also, as #hjpotter92 was getting at, likely need to install the lua-devel package to go along with the lua package.
Try installing that first and then re-running your command and see if the error changes.

Macports compile of MySQL++ failing

Before running "sudo port install mysqlxx +universal", I installed the universal variant of mysql5.
...
checking whether -lm is needed to use C math functions... no
checking whether -lsocket is needed... no
checking whether -lnsl is needed... no
checking for MySQL library directory... /opt/local/lib/mysql5/mysql
checking for MySQL include directory... /opt/local/include/mysql5/mysql
checking if we can link to MySQL C API library directly... no
checking zlib.h usability... yes
checking zlib.h presence... yes
checking for zlib.h... yes
checking for gzread in -lz... yes
checking whether adding -lz will let MySQL C API link succeed... no
configure: error: Unable to link to MySQL client library!
I suspect what's going on here is that you're running Snow Leopard. In previous versions of OS X, the default C++ compiler built 32-bit executables by default, but this changed to 64-bit in Snow Leopard. This can cause link problems with the MySQL C API library if it's not built as a Universal library supporting both 64- and 32-bit executables.
There are a bunch of ways around this problem, but most of the ones I know about either won't work with MacPorts or I don't know how to make them work. I've added a section on this to the MySQL++ README for Mac OS X, which you can read online, here.
Perhaps you can figure out how to adapt these solutions to the MacPorts build system. Something like this might work:
CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 sudo port install mysqlxx +universal
That depends on those environment variables making it through the sudo and port barriers. You might have to get trickier. For instance:
sudo -s
CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 port install mysqlxx +universal
As I commented above, it might be simplest to just build from the source tarball.