Re: [gdal-dev] OpenJPEG JPEG2000 Driver

2023-02-14 Thread Mateusz Loskot
On Wed, 15 Feb 2023 at 01:34, Simon Eves wrote: > > I tried adding -DCMAKE_CPP_FLAGS="-fPIC" -DCMAKE_CXX_FLAGS="-fPIC" to the > OpenJPEG build CMake invocation, but that made no difference. > More CMake-idiomatic way is to use -DCMAKE_POSITION_INDEPENDENT_CODE=ON instead. It used to be there h

[gdal-dev] How to build GDAL without dependency on libtiff.so or libjpeg.so

2023-02-14 Thread Fengting Chen
Hi, In the old build system, I was able to build GDAL 3.4 using “—with-libtiff=internal” and “—with-jpeg=internal” . However, ldd on libgdal.so shows that it still depends on libtiff.so and libjpeg.so. How to build GDAL without this dependency? Thanks! _

Re: [gdal-dev] OpenJPEG JPEG2000 Driver

2023-02-14 Thread Simon Eves
OK, I'm an idiot. It's *CMAKE_C_FLAGS* not *CMAKE_CPP_FLAGS*. It works now. However, I am still surprised at the need to hack the *configure* script to make the test work. On Tue, Feb 14, 2023 at 4:33 PM Simon Eves wrote: > I recreated the compile/link test that *configure* is doing, and it al

Re: [gdal-dev] OpenJPEG JPEG2000 Driver

2023-02-14 Thread Simon Eves
I recreated the compile/link test that *configure* is doing, and it also fails outside. I then determined I could make it work by also adding *-lm* and *-lpthread* to the link. I hacked GDAL *configure* script to also add those two to *$LIBS* when it does the OpenJPEG link test, and now that pass

Re: [gdal-dev] Issues with SetColorTable() and multi-sample TIFF

2023-02-14 Thread Even Rouault
 would the solution involve installing GDAL from source? Yes, Ubuntu packages don't have the libkea dependency. FYI, GDAL from conda-forge has KEA support: https://gdal.org/download.html#conda -- http://www.spatialys.com My software is free, but my time generally not.

Re: [gdal-dev] Issues with SetColorTable() and multi-sample TIFF

2023-02-14 Thread afernandez
Hi Even, I checked and it doesn't seem that GDAL was built with KEA support. I built it with aptitude so my input was minimal. The installation included: $ sudo apt install gdal-bin libgdal-dev python3-gdal Should I install any other package or would the solution involve installing GDAL from sour

Re: [gdal-dev] Error when trying to build Docker Images

2023-02-14 Thread Even Rouault
Le 14/02/2023 à 23:45, Dirk Stenger a écrit : Thank you for the help. Your proposed solution works for ubuntu-small. However, when I am trying to build ubuntu-full, I get a new error: Did you "git pull" to get the latest state of the repository ? The error you get might come from the fact t

Re: [gdal-dev] Error when trying to build Docker Images

2023-02-14 Thread Dirk Stenger
Thank you for the help. Your proposed solution works for ubuntu-small. However, when I am trying to build ubuntu-full, I get a new error: ~/git/gdal/docker$ ubuntu-full/build.sh --platform linux/amd64 ... /gdal/frmts/pdf/pdfdataset.cpp: In function'int LoadPdfiumDocumentPage(const char*, const

Re: [gdal-dev] Error when trying to build Docker Images

2023-02-14 Thread Even Rouault
Dual architecture amd64+arm64 builds are attempted by default (see https://github.com/OSGeo/gdal/tree/master/docker#multi-arch-images), which requires docker buildx to be setup|, or perhaps just ||binfmt to support arm64 through qemu||| If you just need amd64 builds, add "--platform linux/amd6

Re: [gdal-dev] Error when trying to build Docker Images

2023-02-14 Thread Dirk Stenger
Hi, No, it is an amd64 system. Regards, Dirk Am 14.02.23 um 19:00 schrieb Dirk Stenger: All, Unfortunately, when trying to build the GDAL Docker Image on a local machine (Ubuntu 22.04), the build fails with an error: Executed commands and logging: ~/git/gdal/docker/ubuntu-small$ ./bui

[gdal-dev] Convert NetCDF to GeoTIFF WGS 84

2023-02-14 Thread Javier Garcia
Hi, I would like to convert the next NetCDF file to a GeoTIFF WGS 84. NetCDF file `gdalinfo` output: Driver: netCDF/Network Common Data Format Files: /home/me/netcdf_file.nc Size is 512, 512 Metadata: NC_GLOBAL#altimetry=altiCERSAT NC_GLOBAL#altitude_resolution=n/a NC_GLOBAL#area=Ireland 2

Re: [gdal-dev] [Board] Travis usage of GRASS

2023-02-14 Thread Even Rouault
2 concurrent builds would probably be fine. (I also see we use s390x and Graviton2 for PROJ. It is sometimes useful because of subtle floating point differences that pop up and make the regression test suite fail. Easier to catch them at the time they are introduced rather that after release w

Re: [gdal-dev] Error when trying to build Docker Images

2023-02-14 Thread Laurențiu Nicola via gdal-dev
Hi, Is that an arm64 system? Laurentiu On Tue, Feb 14, 2023, at 20:00, Dirk Stenger wrote: > All, > > Unfortunately, when trying to build the GDAL Docker Image on a local machine > (Ubuntu 22.04), the build fails with an error: > > Executed commands and logging: > > ~/git/gdal/docker/ubuntu-

[gdal-dev] Error when trying to build Docker Images

2023-02-14 Thread Dirk Stenger
All, Unfortunately, when trying to build the GDAL Docker Image on a local machine (Ubuntu 22.04), the build fails with an error: Executed commands and logging: ~/git/gdal/docker/ubuntu-small$ ./build.sh ... debconf: delayingpackage configuration, since apt-utils is not installed Fetched 70.5

Re: [gdal-dev] Issues with SetColorTable() and multi-sample TIFF

2023-02-14 Thread Even Rouault
Le 14/02/2023 à 18:46, afernandez a écrit : Hello Even, Thank you for the quick reply. I'll try using GDAL subdatasets later this afternoon (although I'm not sure if this solution would become a bit messy for hundreds of files). The format KEA is completely new to me. I was able to install KE

Re: [gdal-dev] [Board] Travis usage of GRASS

2023-02-14 Thread Alan Snow
Pyproj uses Cirrus CI for osx arm64. It is currently free. On Tue, Feb 14, 2023, 11:50 AM Michael Smith wrote: > Even, > > If its actively being used, that’s fine. Was just re-evaluating after > talking with Howard. Could we drop the concurrency down without impacting > GDAL, GRASS and other pro

Re: [gdal-dev] [Board] Travis usage of GRASS

2023-02-14 Thread Michael Smith
Even, If its actively being used, that’s fine. Was just re-evaluating after talking with Howard. Could we drop the concurrency down without impacting GDAL, GRASS and other projects? And looks like I got the renewal dates swapped with mapserver. The OSGeo plan doesn’t renew until June. Right now

Re: [gdal-dev] Issues with SetColorTable() and multi-sample TIFF

2023-02-14 Thread afernandez
Hello Even, Thank you for the quick reply. I'll try using GDAL subdatasets later this afternoon (although I'm not sure if this solution would become a bit messy for hundreds of files). The format KEA is completely new to me. I was able to install KEALib but found only one source of information o

Re: [gdal-dev] [Board] Travis usage of GRASS

2023-02-14 Thread Even Rouault
Hi, just reacting to "We were considering cancelling OSGeo’s subscription". For GDAL, our current use of Travis-CI is to test portability on the Graviton2 ARM64 and s390x big-endian platforms (we use github CI for x64 Linux/Win/Mac). For Graviton2, this is more the ARM64 side of things than t

Re: [gdal-dev] Issues with SetColorTable() and multi-sample TIFF

2023-02-14 Thread Even Rouault
Hi, The TIFF format only supports only single color table per TIFF image, and it only makes sense for a single-sample TIFF. An alternative would be for you to create multiple TIFF image file directories in the same file (mapped as GDAL subdatasets), with one band per subdataset, by using the

[gdal-dev] Issues with SetColorTable() and multi-sample TIFF

2023-02-14 Thread afernandez
Hello, I'm using the GDAL Tools plugin within QGIS to plot some raster layers. The snippet reads: driver_name = 'GTIFF' driver = gdal.GetDriverByName(driver_name) ... gdal_ds = driver.Create("my_arguments") gdal_ds.SetProjection("my_projection") gdal_ds.SetGeoTransform("my_geo_transform") for band