If you want to use or test the latest features this can be done quite easily by setting a few environment variables:
I save this commands in a file new_gdal.sh. After running
source new_gdal.shYou will be able to use all the latest gdal tools.
johan@x1:~$ source ~/latest_gdal.sh johan@x1:~$ gdalinfo --version GDAL 2.3.0dev, released 2017/99/99
Actually if you use this command, also tools dynamically linked to gdal will be using this latest version.
johan@x1:~$ saga_cmd io_gdal ____________________________ ##### ## ##### ## ### ### ## ### ### # ## ## #### # ## ### ##### ## # ##### ##### # ## ##### # ## ____________________________ SAGA Version: 6.4.0 Library: GDAL/OGR Category: Import/Export File: /usr/local/lib/saga/libio_gdal.so Description: Interface to Frank Warmerdam's Geospatial Data Abstraction Library (GDAL). Version 2.3.0devNote that this will work well for packages dynamically linked to the C api. If packages are linked to the C++ api, they may need recompilation.
If you are on windows, you could have a look at SDKShell.bat (part of the builds from Tamas Szekeres).
Note: I actually wrote this blogpost because in his presentation on FOSDEM Jeremy Mayeres recommended using Docker for using the latest version of GDAL. I think that solution is overkill for desktop usage, and using environment variables is easier.