I need some help. I am using stock source of ccx 2.17 and following README to compile in Ubuntu 20.04. I have gone though all the steps to make OpenBLAS, hwloc, parsec, scotch and pastix. Ihave installed CUDA 11.1 and modified the make files as needed. When I run Makefile_i8 I get the following error:
/usr/bin/ld: …/…/…/PaStiX/pastix_i8/lib/libpastix.a(isched_hwloc.c.o): undefined reference to symbol ‘hwloc_bitmap_iszero’
/usr/bin/ld: …/…/…/PaStiX/hwloc_i8/lib/libhwloc.so: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make: *** [Makefile_i8:39: ccx_2.17_i8] Error 1
Any idea what could be the issue here? I see that in my case hwloc creates a lib folder and not a lib64. I have modified the Makefile accordingly.
DSO is dynamic shared object add -lpthread to the link command in the makefile.
Thanks. I believe -lpthread is already in the link command. Below is my exact Makefile_i8 file, slightly modded from the stock file based on my system. Would really appreciate some suggestions.
CFLAGS = -Wall -O2 -fopenmp -fpic -I …/…/…/SPOOLES.2.2 -I$(PASTIX_INCLUDE) -DARCH=“Linux” -DSPOOLES -DARPACK -DMATRIXSTORAGE -DLONGLONG -DPASTIX -DPASTIX_FP32 -DPASTIX_GPU
FFLAGS = -Wall -O2 -fopenmp -fpic -fdefault-integer-8
CC=cc
FC=gfortran
.c.o :
(CC) (CFLAGS) -c <
.f.o :
(FC) (FFLAGS) -c <
include Makefile.inc
SCCXMAIN = ccx_2.17.c
OCCXF = (SCCXF:.f=.o)
OCCXC = (SCCXC:.c=.o)
OCCXMAIN = $(SCCXMAIN:.c=.o)
DIR=…/…/…/SPOOLES.2.2
PASTIX_INCLUDE = …/…/…/PaStiX/pastix_i8/include
PASTIX_LIBS = …/…/…/PaStiX/hwloc_i8/lib/libhwloc.so …/…/…/OpenBLAS_i8/lib/libopenblas.a
…/…/…/PaStiX/pastix_i8/lib/libpastix.a …/…/…/OpenBLAS_i8/lib/libopenblas.a -lpthread -lm …/…/…/PaStiX/pastix_i8/lib/libspm.a
…/…/…/PaStiX/pastix_i8/lib/libpastix_parsec.a …/…/…/PaStiX/pastix_i8/lib/libpastix_kernels.a …/…/…/OpenBLAS_i8/lib/libopenblas.a -lrt
…/…/…/PaStiX/pastix_i8/lib/libpastix_kernels_cuda.a …/…/…/PaStiX/parsec_i8/lib/libparsec.so
/usr/local/cuda-11.1/lib64/libcudart_static.a -lpthread -ldl -lrt /usr/lib/x86_64-linux-gnu/libcublas.so.10
/usr/local/cuda-11.1/lib64/libculibos.a /usr/lib/x86_64-linux-gnu/libcublasLt.so.10 -lrt
…/…/…/PaStiX/scotch_i8/lib/libscotch.a …/…/…/PaStiX/scotch_i8/lib/libscotcherrexit.a -lpthread -lz -lm /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libgomp.so.1
LIBS =
(DIR)/spooles.a \
../../../ARPACK/libarpack_INTEL.a \
(PASTIX_LIBS)
-lpthread -lm -lc
ccx_2.17_i8: (OCCXMAIN) ccx_2.17.a (LIBS)
./date.pl; (CC) (CFLAGS) -c ccx_2.17.c; (FC) -Wall -O2 -o @
(OCCXMAIN) ccx_2.17.a (LIBS)
ccx_2.17.a: (OCCXF) (OCCXC)
ar vr @ ?
I was finally able to compile ccx with PastiX in Ubuntu 20.04. I had to modify the following line in Makefile_i8 file, by adding …/…/…/PaStiX/hwloc_i8/lib/libhwloc.so to the end. Hope this helps someone.
ccx_2.17_i8: (OCCXMAIN) ccx_2.17.a (LIBS)
./date.pl; (CC) (CFLAGS) -c ccx_2.17.c; (FC) -Wall -O2 -o @
(OCCXMAIN) ccx_2.17.a (LIBS) …/…/…/PaStiX/hwloc_i8/lib/libhwloc.so
2 Likes
For Ubuntu system, you can use a ready-made hwloc and scotch package (to facilitate the entire procedure):
sudo apt-get install -y hwloc
sudo apt-get install -y scotch
1 Like