On 02/08/2017 09:00 AM, [hidden email] wrote:
This is a bug. Can you report it on the tracker?
The problem is that the m4 macro OCTAVE_CHECK_LIB sets library specific flags, in this case CXSPARSE_CPPFLAGS. However, the next test in configure.ac which checks version, OCTAVE_CHECK_CXSPARSE_VERSION_OK, doesn't use these flags.
On 02/08/2017 06:23 PM, Rik wrote:
Does the attached patch fix the problem?
> On 02/08/2017 09:00 AM, [hidden email] wrote:
>> --with-cxsparse-includedir option is ignored
>> "c." <[hidden email]>
>> 02/08/2017 03:58 AM
>> Maintainers GNU Octave <[hidden email]>
>> <mailto:[hidden email]>
>> 1.0 (Mac OS X Mail 7.3 \(1878.6\))
>> <[hidden email]>
>> text/plain; charset=us-ascii
>> I am trying to build Octave 4.2 on a machine with Scientific Linux release 6.6 (Carbon).
>> This machine uses an environmental modules system therefore many libraries, including SuiteSparse
>> are installed in non-standard locations.
>> I am configuring with
>> ../configure <...> \
>> --with-colamd-includedir=$mkSuitesparseInc \
>> --with-colamd-libdir=$mkSuitesparseLib \
>> --with-amd-libdir=$mkSuitesparseLib \
>> --with-amd-includedir=$mkSuitesparseInc \
>> --with-camd-libdir=$mkSuitesparseLib \
>> --with-camd-includedir=$mkSuitesparseInc \
>> --with-cholmod-libdir=$mkSuitesparseLib \
>> --with-cholmod-includedir=$mkSuitesparseInc \
>> --with-ccolamd-includedir=$mkSuitesparseInc \
>> --with-ccolamd-libdir=$mkSuitesparseLib \
>> --with-cxsparse-libdir=$mkSuitesparseLib \
>> --with-cxsparse-includedir=$mkSuitesparseInc \
>> --with-umfpack-includedir=$mkSuitesparseInc \
>> The configure phase fails with the following message:
>> checking for cs_di_sqr in -lcxsparse... yes
>> checking whether CXSparse is version 2.2 or later... no
>> configure: error: CXSparse library is too old (< version 2.2). Upgrade CXSparse (SuiteSparse) or configure Octave with --disable-cxsparse"
>> The error message is not very useful because the problem is not with the version of CXSparse avaialble (the available version is > 3.0), checking config.log I see:
>> configure:43472: checking whether CXSparse is version 2.2 or later
>> configure:43523: g++ -std=gnu++11 -E -fPIC conftest.cpp
>> conftest.cpp:96:24: fatal error: cs.h: No such file or directory
>> So it seems the directory passed to --with-cxsparse-includedir is not being added to the compilation flags (while it is added when testing for, e.g., cholmod), indeed adding "CPPFLAGS=-I$mkSuitesparseInc" is a workaround for this problem.
>> Is this a configuration bug? Does anyone know if it affects the development branch? Should I submit it to the tracker?
> This is a bug. Can you report it on the tracker?
> The problem is that the m4 macro OCTAVE_CHECK_LIB sets library specific
> flags, in this case CXSPARSE_CPPFLAGS. However, the next test in
> configure.ac which checks version, OCTAVE_CHECK_CXSPARSE_VERSION_OK,
> doesn't use these flags.
diffs.txt (742 bytes) Download Attachment
On 02/08/2017 04:30 PM, John W. Eaton wrote:
> Does the attached patch fix the problem?
Lots of e-mails crossing paths. Mike's fix should be backported. That is
the correct thing to do since the test in acinclude.m4 only makes use of
the preprocessor. There is no need to save and restore the LIBS variable.
In reply to this post by John W. Eaton
I backported Mike's fix to stable.
Separately, there were two cases in acinclude.m4 where we were saving
CXXFLAGS, but then only using the pre-processor to perform tests with
AC_PREPROC_IFELSE. I pushed a cset to stop the unnecessary save&restore
Finally, following Carlo's investigations I looked in config.log and found
that the test for the Qt SetPlaceHolderText function was failing with
conftest.cpp:123:32: fatal error: Qt/qglobal.h: No such file or directory
but I do have qglobal.h installed at
Since Octave now defaults to Qt5, it is not finding the last instance.
The m4 code in acinclude.m4 is:
dnl Check whether QScintilla SetPlaceholderText function exists.
dnl FIXME: This test uses a version number. It potentially could
dnl be re-written to actually call the function, but is it worth it?
AC_CACHE_CHECK([whether Qt has SetPlaceholderText function],
CPPFLAGS="$QT_CPPFLAGS $CXXPICFLAG $CPPFLAGS"
#if QT_VERSION < 0x040700
#error No SetPlacholderText function available.
if test $octave_cv_func_setplaceholdertext = yes; then
[Define to 1 if you have the Qt SetPlaceholderText function.])
Is it enough to change
It seemed to work for me, but I haven't gone and tested back with Qt4.
|Free forum by Nabble||Edit this page|