<html dir="ltr"><head></head><body style="text-align:left; direction:ltr;"><div>Hi,</div><div><br></div><div>I found the answer. I had an old installation of OpenJPEG lib (2.3.1) on Gdal was still pointing on it (but this version doesn't contain <b>opj_encoder_set_extra_options)</b>. After a clean removal and fresh re-compiling of OpenJPEG 2.4.0 I managed to compile GDAL.</div><div><br></div><div>Thanks.</div><div><br></div><div>Sylvain.</div><div><br></div><div>Le lundi 08 février 2021 à 11:52 +0300, Sylvain Maffren a écrit :</div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div>I answer to myself (I just realized that my email topic wasn't good).</div><div><br></div><div>Sylvain</div><div>--</div><div><br></div><div>Le lundi 08 février 2021 à 08:53 +0300, Sylvain Maffren a écrit :</div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div>Hello,</div><div><br></div><div>I am trying to insatll GDAL manually by compiling from src. Here is the different versions of the librairies used :</div><div><br></div><div>GDAL_VERSION=3.2.1</div><div>GEOS_VERSION=3.8.1 (manual compilation)</div><div>PROJ_VERSION=7.2.1 (manual compilation)</div><div>HDF5_VERSION=1.10.5 (manual compilation)</div><div>NETCDF_VERSION=4.7.4 (manual compilation)</div><div>OPENJPEG_VERSION=2.4.0 (manual compilation)</div><div>PROJ_DAT_VERSION=1.8 (manual compilation)</div><div><br></div><div>I had some errors I managed to fix by following some google posts. It just remains one and I can't find any clue on internet on how to fix it.</div><div><br></div><div>Here is the way I used to compile GDAL from src :</div><div><br></div><div>cd $ROOTDIR/src</div><div>echo "Downloading sources and compiling GDAL"</div><div>wget -q <a href="https://github.com/OSGeo/gdal/releases/download/v${GDAL_VERSION}/gdal-${GDAL_VERSION}.tar.gz">https://github.com/OSGeo/gdal/releases/download/v${GDAL_VERSION}/gdal-${GDAL_VERSION}.tar.gz</a></div><div>tar -xvf gdal-${GDAL_VERSION}.tar.gz &>> /dev/null</div><div><br></div><div>cd $ROOTDIR/src/gdal-${GDAL_VERSION}</div><div>CFLAGS="-O3 -pipe -march=native -w"; CXXFLAGS="${CFLAGS}" ./configure --with-proj=$ROOTDIR --with-cpp14  --with-crypto=yes --with-liblzma --with-python --with-geos=$ROOTDIR --with-spatialite --with-openjpeg=$ROOTDIR --with-hdf5=$ROOTDIR --with-netcdf=$ROOTDIR --with-pg --with-curl --with-png </div><div>make -s -j$(nproc) &>> /dev/null </div><div>make install</div><div>ldconfig </div><div>make clean &>> /dev/null</div><div><br></div><div>echo "Install GDAL python"    </div><div>cd $ROOTDIR/src/gdal-${GDAL_VERSION}/swig/python</div><div>python3 setup.py build && python3 setup.py install</div><div><br></div><div>I got this error and I am unable to complete the compilation :</div><div><br></div><div>make[1] : on entre dans le répertoire « /usr/src/gdal-3.2.1/apps »</div><div>/bin/bash /usr/src/gdal-3.2.1/libtool --mode=link --silent g++  gdalinfo_bin.lo  /usr/src/gdal-3.2.1/libgdal.la  -o gdalinfo</div><div><b>/usr/bin/ld: /usr/src/gdal-3.2.1/.libs/libgdal.so: undefined reference to `opj_encoder_set_extra_options'</b></div><div>collect2: error: ld returned 1 exit status</div><div>make[1]: *** [GNUmakefile:90: gdalinfo] Error 1</div><div>make[1] : on quitte le répertoire « /usr/src/gdal-3.2.1/apps »</div><div>make: *** [GNUmakefile:120: apps-target] Error 2</div><div><br></div><div>It seems that the reference to <b> </b>`opj_encoder_set_extra_options' is linked to the OpenJPEG librairy but I didn't have any errors when I compiled manually OpenJPEG librairy. And I didn't find any clue on internet to fix it.</div><div><br></div><div>Did I miss something in my compilation process ?</div><div><br></div><div>Thanks in adavance for your advice.</div><div><br></div><div><span><pre>-- </pre><br><div>Sylvain</div></span></div>
</blockquote><div><span><pre>-- </pre><br><div>Sylvain</div></span></div>
</blockquote><div><span><pre>-- <br></pre><div>Sylvain</div></span></div></body></html>