Hi Tim, Malcolm,
I decided to try compling Starlink again with a new checkout of the 2018A branch. This time, the problem with FIGARO and the %LOC issue has gone away. I wonder if I installed a package at some stage since my last build
attempt. I did remove libgfortran-static before building, so not sure if that was causing an issue (or indeed if there's been an update to some Fedora 28 packages since that fixed an issue somewhere).
I built with Fedora 28:
gcc-fortran / libgfortran 8.1.1-5.fc28
There are still a couple of other issues that I had to fix - I have detailed the problems I encountered and the fixes below. If you would like any more diagnostics or Fedora 28 package details from my build, let me know.
I'd be happy to tar up and send the compilation directories and the build if useful - just let me know.
Thanks again for your help - it's very much appreciated.
Cheers,
John
1)
In starlink/applications/esp/ellpro.f
Declaration of arrays passed to subroutine:
CALL GJP_IDBVIP(MD,NCP,L,XV,YV,FV2,NOP,XI,YI,
: ZI,IWK,WK,IFAIL,STATUS)
have different dimensions from those in the subroutine definition
SUBROUTINE GJP_IDBVIP(md,ncp,ndp,xd,yd,zd,nip,xi,yi,zi,iwk,
: wk,istat,status)
Fedora 28 compiler didn't like this.
** SOLUTION: Make dimensions of arrays in initial declaration match those in the GJP_IDBVIP subroutine definition.
2)
cd thirdparty/kitware/vtk \
&& (make && make install) >make.log 2>make.log.err || { cat make.log.err; false; }
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/cookie.c:81:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/easy.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/formdata.c:102:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/getenv.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/hash.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/http.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/if2ip.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/mprintf.c:33:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/multi.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/sendf.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/telnet.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/transfer.c:24:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
In file included from /usr/include/bits/libc-header-start.h:33,
from /usr/include/stdio.h:27,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/setup.h:173,
from /home/jbarnes/Build/starlink/thirdparty/kitware/vtk/cmake/Utilities/cmcurl/url.c:26:
/usr/include/features.h:184:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
# warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
^~~~~~~
CMake Error at CMake/vtkCompilerExtras.cmake:42 (if):
if given arguments:
"cc (GCC) 8.1.1 20180712 (Red Hat 8.1.1-5)
Copyright (C) 2018 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.
" "VERSION_GREATER" "4.2.0" "AND" "BUILD_SHARED_LIBS" "AND"
"HAVE_GCC_VISIBILITY" "AND" "VTK_USE_GCC_VISIBILITY" "AND" "NOT" "MINGW"
"AND" "NOT" "CYGWIN"
Unknown arguments specified
Call Stack (most recent call first):
CMakeLists.txt:139 (include)
make[1]: *** [Makefile:677: all] Error 1
make: *** [Makefile.dependencies:3274: /star/manifests/vtk] Error 1
** SOLUTION: Get rid of check for gcc version on line 42 of ./VTK/CMake/vtkCompilerExtras.cmake as definitely > 4.2.0
and then again in ./VTK/CMake/GenerateExportHeader.cmake (i.e. ${_gcc_version} not working)
** SOLUTION: Comment out lines 178,179&180 of ./VTK/CMake/GenerateExportHeader.cmake as unnecessary
John,
> I was wondering if you could help with the problem I mentioned recently when compiling Starlink on Fedora 28.
I was hoping somebody else with Fedora could help with practical
tips.
> I have found that one of my workarounds has resulted in a problem - I detailed it below in 1) between then asterisks
Please could you send me the applications/figaro/config.log file.
Amongst a number of checks of features in the Fortran compiler, there
should be a test for LOC or %LOC. In mine on Mint the relevant part
reads:
configure:18083: checking whether gfortran has the %LOC extension
configure:18115: result: no
configure:18128: checking whether gfortran supports intrinsic LOC
configure:18147: result: yes
indicating that compiler supports the LOC() syntax.
> In addition to the problem with plotting I mentioned in 1), when I run
> FIGARO-isubset on and NDF file it doesn't actually work properly and
> prints
KAPPA:NDFCOPY is better. You can subset by pixels or world
co-ordinates, it's not limited to two dimensions, and it preserves the
WCS information.
> I think the # sections in the source code (See 1) below) are meant to
> be place holders or substituted into the code if necessary - rather
> than turned into print statements. It seems as though my build is
> failing the HAVE_PERCENTLOC and HAVE_INTRINSIC_LOC for some reason -
> maybe the line Do not have LOC or %LOC should never be reached. Any
> idea why that might be or what additional tests I might perform? I
> wonder if I am missing some devel file somewhere.
Yes, there is a preprocessor that edits the Fortran in these .F files.
The configure.ac has these lines to set the boolean HAVE_PERCENTLOC
and HAVE_INTRINSIC_LOC.
AC_FC_HAVE_PERCENTLOC()
AC_FC_CHECK_INTRINSICS(LOC)
If for some reason you have neither, then the error message you see
appears.
I'd still like to know all the extra packages that you needed to
install, so that I can update the main README in the source.
Malcolm