<div dir="ltr">Thanks for your answer Even, lcms2 was indeed a missing piece, it allowed me to get GDAL configured but the build failed with a missing header:<div><div><i>fatal error: core/fpdfapi/page/cpdf_page.h: No such file or directory</i><br></div><div><br></div><div>I finally used your pre-built binaries from <a href="https://github.com/rouault/pdfium_build_gdal_3_8/releases" target="_blank">https://github.com/rouault/pdfium_build_gdal_3_8/releases</a></div><div>And get GDAL to compile properly with pdfium.</div><div><br></div><div>Thanks for the support,</div><div>Johannes</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 6 Mar 2024 at 11:19, Even Rouault <<a href="mailto:even.rouault@spatialys.com" target="_blank">even.rouault@spatialys.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><u></u>

  
    
  
  <div>
    <p>Hi,</p>
    <p>I suspect that the error comes from the fact that one of several
      of the other dependencies required by pdfium are not found: JPEG,
      PNG, OpenJPEG, lcms2</p>
    <p>Even<br>
    </p>
    <div>Le 06/03/2024 à 11:00, Johannes Paul
      via gdal-dev a écrit :<br>
    </div>
    <blockquote type="cite">
      
      <div dir="ltr">Hello,
        <div><br>
        </div>
        <div>I have compiled PDFium from <a href="https://github.com/rouault/pdfium/tree/master" target="_blank">https://github.com/rouault/pdfium/tree/master</a>
          and I'm trying to get GDAL 3.8.4 built with this geospatial
          PDF driver on Almalinux 8.</div>
        <div><br>
        </div>
        <div>However if I use cmake with the following variables :</div>
        <div><i>-DGDAL_USE_PDFIUM=ON -DGDAL_ENABLE_DRIVER_PDF=ON
            -DPDFIUM_INCLUDE_DIR="${INSTALLDIR}"/include/pdfium
            -DPDFIUM_LIBRARY="${INSTALLDIR}"/lib/pdfium/libpdfium.a</i></div>
        <div><br>
        </div>
        <div>I get the following error :</div>
        <div><i>CMake Error at cmake/helpers/GdalDriverHelper.cmake:284
            (message):<br>
              gdal_target_link_libraries(): PRIVATE is a mandatory
            argument.<br>
            Call Stack (most recent call first):<br>
              frmts/pdf/CMakeLists.txt:53 (gdal_target_link_libraries)</i><br>
        </div>
        <div><br>
        </div>
        <div>If I remove <i>-DGDAL_ENABLE_DRIVER_PDF=ON </i>, I get
          GDAL compiled but without PDFium.</div>
        <div><br>
        </div>
        <div>Any idea?</div>
        <div>Thanks,</div>
        <div>Johannes</div>
        <div><br>
        </div>
        <div><br>
        </div>
      </div>
      <br>
      <fieldset></fieldset>
      <pre>_______________________________________________
gdal-dev mailing list
<a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">gdal-dev@lists.osgeo.org</a>
<a href="https://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">https://lists.osgeo.org/mailman/listinfo/gdal-dev</a>
</pre>
    </blockquote>
    <pre cols="72">-- 
<a href="http://www.spatialys.com" target="_blank">http://www.spatialys.com</a>
My software is free, but my time generally not.</pre>
  </div>

</blockquote></div>