pietern / goestools

Tools to work with signals and files from GOES satellites
https://pietern.github.io/goestools/
BSD 2-Clause "Simplified" License
374 stars 83 forks source link

compile error - "proj version 4 required" #39

Closed ilikeleptons closed 5 years ago

ilikeleptons commented 5 years ago

I just pulled the latest version of the sources of goestools. When I try to compile goesproc (I believe) I get an error stating that "proj version 4 [is] required". Let me know what additional information you'll need, I'm a little new to this.

Here is the output from when I make the project, I can't seem to bold face the errors, but they start at around the 89% mark or so.

[ 91%] Building CXX object src/goesrecv/CMakeFiles/goesrecv.dir/goesrecv.cc.o
In file included from /home/isaac/.cache/yay/goestools-git/src/goestools/src/goesproc/map_drawer.h:5,
                 from /home/isaac/.cache/yay/goestools-git/src/goestools/src/goesproc/handler_goesr.cc:14:
/home/isaac/.cache/yay/goestools-git/src/goestools/src/goesproc/proj.h:4:2: error: #error "proj version 4 required"
 #error "proj version 4 required"
  ^~~~~
pietern commented 5 years ago

Thanks for reporting the issue!

The output you included was a bit verbose so I edited it down to the relevant part.

Can you post the output of cmake instead of the output of running make? That will include information on the actual version of libproj you have installed. The fact that you got past that stage implies that CMake was able to find some version of libproj, just not the right one.

Please also include the operating system you're using and any relevant version information.

ilikeleptons commented 5 years ago

ah, i forgot to mention that before i was building it from the archlinux user repository. however, when i instead follow the build instructions in README.md, i get far less progress:

cd goestools ~ isaac@thnikdap> mkdir -p build ~/goestools isaac@thnikdap> cd build ~/goestools isaac@thnikdap> cmake ../ -DCMAKE_INSTALL_PREFIX=/usr/local ~/goestools/build -- The CXX compiler identification is GNU 8.2.1 -- The C compiler identification is GNU 8.2.1 -- Check for working CXX compiler: /bin/c++ -- Check for working CXX compiler: /bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Check for working C compiler: /bin/cc -- Check for working C compiler: /bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done CMake Warning at CMakeLists.txt:36 (find_package): By not providing "FindSanitizers.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "Sanitizers", but CMake did not find one.

Could not find a package configuration file provided by "Sanitizers" with any of the following names:

SanitizersConfig.cmake
sanitizers-config.cmake

Add the installation prefix of "Sanitizers" to CMAKE_PREFIX_PATH or set "Sanitizers_DIR" to a directory containing one of the above files. If "Sanitizers" provides a separate development package or SDK, be sure it has been installed.

-- Defaulting build type to 'RelWithDebInfo' CMake Error at CMakeLists.txt:59 (add_subdirectory): The source directory

/home/isaac/goestools/vendor/libcorrect

does not contain a CMakeLists.txt file.

CMake Error at CMakeLists.txt:60 (add_subdirectory): The source directory

/home/isaac/goestools/vendor/libaec

does not contain a CMakeLists.txt file.

CMake Error at CMakeLists.txt:68 (add_subdirectory): The source directory

/home/isaac/goestools/vendor/nanomsg

does not contain a CMakeLists.txt file.

CMake Error at src/lrit/CMakeLists.txt:5 (add_sanitizers): Unknown CMake command "add_sanitizers".

-- Configuring incomplete, errors occurred! See also "/home/isaac/goestools/build/CMakeFiles/CMakeOutput.log".

i've attached the cmake output log below: CMakeOutput.log

eminence commented 5 years ago

Perhaps the submodules are missing? Try:

git submodule init
git submodule update
pietern commented 5 years ago

@ilikeleptons This problem will be resolved by the submodule initialization like @eminence.

I just checked the Arch Linux repository for proj and it has version 5.2.

AlCutter commented 5 years ago

I hit this problem too with Ubuntu 19.04, which also ships Proj 5.20. The submodule suggestion didn't work for me (doesn't look like proj is vendored in?), but while digging around I noticed that proj_api.h shipped with 5.20 is compatible with the proj4 API, so I've created a small PR (in #43 ) which allows compilation to proceed when either proj version 4 or 5 are detected.

This allows the build to successfully complete on my machine. Hope it's helpful!

pietern commented 5 years ago

Thank you for fixing this!