Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I can't install Madagascar on Ubuntu22.04. #285

Closed
zhangxiaoshuotttt opened this issue Mar 31, 2023 · 6 comments
Closed

I can't install Madagascar on Ubuntu22.04. #285

zhangxiaoshuotttt opened this issue Mar 31, 2023 · 6 comments

Comments

@zhangxiaoshuotttt
Copy link

zhangxiaoshuotttt commented Mar 31, 2023

Hi:
I can't install Madagascar on Ubuntu22.04.
My error came after running make install, the error is: make: *** [Makefile:7: install] Error 2

Here is my operation and related information:

(base) master@MasterComputer:~/Python/Madagascar/madagascar-4.0$ ./configure --prefix=/home/master/Python/Madagascar
checking for Python ... /home/master/anaconda3/bin/python
checking Python version ... 3.9.13
checking for RSFROOT ... /home/master/Python/Madagascar
checking for SCons ... /home/master/anaconda3/bin/scons
checking SCons version ... v4.4.0.fc8d0ec215ee6cba8bc158ad40c099be0b598297
Running RSFROOT=/home/master/Python/Madagascar /home/master/anaconda3/bin/scons  config ...

scons: Reading SConscript files ...
checking platform ... (cached) linux [ubuntu]
checking for C compiler ... (cached) gcc
checking if gcc works ... yes
checking if gcc accepts '-x c -std=gnu17 -Wall -pedantic' ... yes
checking for ar ... (cached) ar
checking for rpc ... no
checking complex support ... yes
checking for X11 headers ... /usr/include
checking for X11 libraries ... /usr/lib/X11
checking for OpenGL ... yes
checking for sfpen ... (cached) xtpen
checking for ppm ... no

  Optional package: libnetpbm10-dev
checking for tiff ... no

  sfbyte2tif, sftif2byte, and tiffpen will not be built.

  Optional package: libtiff5-dev
checking for GD (PNG) ... no

  gdpen will not be built.
 
  Optional package: libgd-dev
checking for plplot ... no

  Optional package: libplplot-dev
checking for ffmpeg ... no

  Optional package: libavcodec-dev
checking for cairo (PNG) ... no

  Optional package: libcairo2-dev
checking for jpeg ... no

  sfbyte2jpg, sfjpg2byte, and jpegpen will not be built.

  Optional package: libjpeg-dev
checking for BLAS ... no

  Optional package: libblas-dev
checking for LAPACK ... no

  Optional package: liblapack-dev
checking for SWIG ... (cached) no

  Optional package: swig
checking for numpy ... (cached) yes
checking API options ... (cached) []
checking for C++ compiler ... (cached) g++
checking if g++ works ... yes
checking if g++ accepts '-std=gnu++17 -U__STRICT_ANSI__ -Wall -pedantic' ... yes
checking for MPICC ... (cached) /opt/nvidia/hpc_sdk/Linux_x86_64/23.1/comm_libs/mpi/bin/mpicc
checking if /opt/nvidia/hpc_sdk/Linux_x86_64/23.1/comm_libs/mpi/bin/mpicc works ... no

  Optional package: libopenmpi-dev
checking for MPICXX ... (cached) /opt/nvidia/hpc_sdk/Linux_x86_64/23.1/comm_libs/mpi/bin/mpicxx
checking if /opt/nvidia/hpc_sdk/Linux_x86_64/23.1/comm_libs/mpi/bin/mpicxx works ... no

  Optional package: libopenmpi-dev
checking for MPIRUN ... (cached) /opt/nvidia/hpc_sdk/Linux_x86_64/23.1/comm_libs/mpi/bin/mpirun
checking for Posix threads ... yes
checking for OpenMP ... yes
checking for CUDA ... (cached) /usr/local/cuda
checking if /opt/nvidia/hpc_sdk/Linux_x86_64/23.1/compilers/bin/nvcc works ... yes
checking for FFTW ... no

  Optional package: libfftw3-dev
checking for SuiteSparse ... no

  Optional package: libsuitesparse-dev

scons: *** Two environments with different actions were specified for the same target: sfpseudodepth
File "/home/master/Python/Madagascar/madagascar-4.0/build/user/xuxin/SConstruct", line 61, in <module>

Then

base) master@MasterComputer:~/Python/Madagascar/madagascar-4.0$ make install
RSFROOT=/home/master/Python/Madagascar PYTHONPATH=/home/master/Python/Madagascar/lib/python3.9/site-packages /home/master/anaconda3/bin/scons install
scons: Reading SConscript files ...

scons: *** Two environments with different actions were specified for the same target: sfpseudodepth
File "/home/master/Python/Madagascar/madagascar-4.0/build/user/xuxin/SConstruct", line 61, in <module>
make: *** [Makefile:7: install] Error 2
@zhangxiaoshuotttt
Copy link
Author

I found the solution here #201

@zhangxiaoshuotttt
Copy link
Author

zhangxiaoshuotttt commented Mar 31, 2023

But I get new error.
Can you help me to fix this? Thank you very much. @zhichenggeng @Dirack@andreigomesoliveira

(base) master@MasterComputer:~/Python/Madagascar/madagascar-4.0$ scons install
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
__header(["build/api/c/alloc.h"], ["build/api/c/alloc.c"])
__header(["build/api/c/getpar.h"], ["build/api/c/getpar.c"])
__header(["build/api/c/blas.h"], ["build/api/c/blas.c"])
__header(["build/api/c/chain.h"], ["build/api/c/chain.c"])
__header(["build/api/c/box.h"], ["build/api/c/box.c"])
__header(["build/api/c/butter.h"], ["build/api/c/butter.c"])
__header(["build/api/c/causint.h"], ["build/api/c/causint.c"])
__header(["build/api/c/cdstep.h"], ["build/api/c/cdstep.c"])
__header(["build/api/c/clist.h"], ["build/api/c/clist.c"])
__header(["build/api/c/ccgstep.h"], ["build/api/c/ccgstep.c"])
__header(["build/api/c/cconjgrad.h"], ["build/api/c/cconjgrad.c"])
__header(["build/api/c/ccopy.h"], ["build/api/c/ccopy.c"])
__header(["build/api/c/quadratic.h"], ["build/api/c/quadratic.c"])
__header(["build/api/c/eno2.h"], ["build/api/c/eno2.c"])
__header(["build/api/c/lsint2.h"], ["build/api/c/lsint2.c"])
__header(["build/api/c/cmatmult.h"], ["build/api/c/cmatmult.c"])
__header(["build/api/c/conjgrad.h"], ["build/api/c/conjgrad.c"])
__header(["build/api/c/conjprec.h"], ["build/api/c/conjprec.c"])
__header(["build/api/c/copy.h"], ["build/api/c/copy.c"])
__header(["build/api/c/cosft.h"], ["build/api/c/cosft.c"])
__header(["build/api/c/ctriangle.h"], ["build/api/c/ctriangle.c"])
__header(["build/api/c/weight.h"], ["build/api/c/weight.c"])
__header(["build/api/c/dtrianglen.h"], ["build/api/c/dtrianglen.c"])
__header(["build/api/c/fftlabel.h"], ["build/api/c/fftlabel.c"])
__header(["build/api/c/files.h"], ["build/api/c/files.c"])
__header(["build/api/c/freqfilt.h"], ["build/api/c/freqfilt.c"])
__header(["build/api/c/freqfilt2.h"], ["build/api/c/freqfilt2.c"])
__header(["build/api/c/ftutil.h"], ["build/api/c/ftutil.c"])
__header(["build/api/c/fzero.h"], ["build/api/c/fzero.c"])
__header(["build/api/c/gaussel.h"], ["build/api/c/gaussel.c"])
__header(["build/api/c/igrad2.h"], ["build/api/c/igrad2.c"])
__header(["build/api/c/halfint.h"], ["build/api/c/halfint.c"])
__header(["build/api/c/igrad1.h"], ["build/api/c/igrad1.c"])
__header(["build/api/c/int2.h"], ["build/api/c/int2.c"])
__header(["build/api/c/int3.h"], ["build/api/c/int3.c"])
__header(["build/api/c/mask.h"], ["build/api/c/mask.c"])
__header(["build/api/c/matmult2.h"], ["build/api/c/matmult2.c"])
__header(["build/api/c/repeat.h"], ["build/api/c/repeat.c"])
__header(["build/api/c/weight2.h"], ["build/api/c/weight2.c"])
__header(["build/api/c/sharpen.h"], ["build/api/c/sharpen.c"])
__header(["build/api/c/ntrianglen.h"], ["build/api/c/ntrianglen.c"])
__header(["build/api/c/point.h"], ["build/api/c/point.c"])
__header(["build/api/c/polydiv.h"], ["build/api/c/polydiv.c"])
__header(["build/api/c/recfilt.h"], ["build/api/c/recfilt.c"])
__header(["build/api/c/sharpinv.h"], ["build/api/c/sharpinv.c"])
__header(["build/api/c/slice.h"], ["build/api/c/slice.c"])
__header(["build/api/c/triangle2.h"], ["build/api/c/triangle2.c"])
__header(["build/api/c/spline.h"], ["build/api/c/spline.c"])
__header(["build/api/c/stretch4.h"], ["build/api/c/stretch4.c"])
__header(["build/api/c/tent2.h"], ["build/api/c/tent2.c"])
__header(["build/api/c/tinysolver.h"], ["build/api/c/tinysolver.c"])
__header(["build/api/c/triangle1.h"], ["build/api/c/triangle1.c"])
__header(["build/api/c/vector.h"], ["build/api/c/vector.c"])
__header(["build/api/c/wavelet.h"], ["build/api/c/wavelet.c"])
__header(["build/user/gee/mspef.h"], ["build/user/gee/mspef.c"])
__header(["build/user/gee/nmisinput.h"], ["build/user/gee/nmisinput.c"])
/opt/nvidia/hpc_sdk/Linux_x86_64/23.1/compilers/bin/nvcc -o build/user/cuda/gpuktmig.o -c --x=cu -Ibuild/include build/user/cuda/gpuktmig.c
build/user/cuda/ktmig.cu(56): error: texture is not a template

build/user/cuda/ktmig.cu(58): error: texture is not a template

build/user/cuda/ktmig.cu(60): error: texture is not a template

build/user/cuda/ktmig.cu(62): error: texture is not a template

build/user/cuda/ktmig.cu(64): error: texture is not a template

build/user/cuda/ktmig.cu(208): error: no instance of overloaded function "tex1Dfetch" matches the argument list
            argument types are: (<error-type>, int)

build/user/cuda/ktmig.cu(212): error: no instance of overloaded function "tex1Dfetch" matches the argument list
            argument types are: (<error-type>, int)

build/user/cuda/ktmig.cu(236): error: no instance of overloaded function "tex1Dfetch" matches the argument list
            argument types are: (<error-type>, unsigned int)

build/user/cuda/ktmig.cu(258): error: no instance of overloaded function "tex1Dfetch" matches the argument list
            argument types are: (<error-type>, <error-type>)

build/user/cuda/ktmig.cu(283): error: no instance of overloaded function "tex2D" matches the argument list
            argument types are: (<error-type>, float, float)

build/user/cuda/ktmig.cu(284): error: no instance of overloaded function "tex2D" matches the argument list
            argument types are: (<error-type>, float, float)

build/user/cuda/ktmig.cu(285): error: no instance of overloaded function "tex2D" matches the argument list
            argument types are: (<error-type>, float, float)

build/user/cuda/ktmig.cu(310): error: no instance of overloaded function "tex1Dfetch" matches the argument list
            argument types are: (<error-type>, unsigned int)

build/user/cuda/ktmig.cu(331): error: no instance of overloaded function "tex1Dfetch" matches the argument list
            argument types are: (<error-type>, <error-type>)

build/user/cuda/ktmig.cu(345): error: no instance of overloaded function "tex2D" matches the argument list
            argument types are: (<error-type>, float, float)

build/user/cuda/gpuktmig.c(291): error: identifier "cudaBindTextureToArray" is undefined

build/user/cuda/gpuktmig.c(302): error: identifier "cudaBindTexture" is undefined

build/user/cuda/gpuktmig.c(593): error: identifier "cudaUnbindTexture" is undefined

18 errors detected in the compilation of "build/user/cuda/gpuktmig.c".
scons: *** [build/user/cuda/gpuktmig.o] Error 2
scons: building terminated because of errors.

@sfomel
Copy link
Contributor

sfomel commented Mar 31, 2023

Thank you for reporting these problems.

The first bug is fixed here: 6e65a81

We will make a new stable release (madagascar-4.1) with this and other bug fixes.

@zhangxiaoshuotttt
Copy link
Author

Thank you for reporting these problems.

The first bug is fixed here: 6e65a81

We will make a new stable release (madagascar-4.1) with this and other bug fixes.

Thank you very much. At the same time, I would like to ask how to solve the problem related to CUDA that I encountered in the later installation. It seems that this problem makes me unable to install normally. I observed that the error seems to be due to some internal problems of this code.

What I want to ask is:

① Whether this problem can be solved

② Could you skip installing this "user/cuda"? (I don't know if this will affect the installation of Madagascar)

@sfomel
Copy link
Contributor

sfomel commented Apr 3, 2023

We will check if the error is caused by a different version of nvcc.

Skipping user/cuda is easy: simply delete the whole directory.

To disable CUDA support in Madagascar, edit $RSFSRC/config.py and set

CUDA_TOOLKIT_PATH = None

@zhangxiaoshuotttt
Copy link
Author

We will check if the error is caused by a different version of nvcc.

Skipping user/cuda is easy: simply delete the whole directory.

To disable CUDA support in Madagascar, edit $RSFSRC/config.py and set

CUDA_TOOLKIT_PATH = None

Thanks for your advice. I think your guess is correct, this is probably due to different nvcc versions, after I removed the 'usr' related to GPU, make and make install can be correctly.
I deleted the following three USRs, I hope it will be helpful for your test: "cuda","fomels","hwang"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants