Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use GDAL vsipreload trick to be able to use the vsifile api for all files #1342

Closed
wants to merge 1 commit into from

Conversation

etiennesky
Copy link
Contributor

this pull request relates to issue http://hub.qgis.org/issues/10124

See the issue for more details and a test file. This commit adds the feature to debian builds but some issues remain

  • where to put the vsipreload.cpp file, in core/ or in providers/? similarly which debian package this goes into?
  • how to enable this automatically for other linux systems and when doing a simple "make install"
  • small packaging issue in debian, the .so file does not have the package version number

@mhugent
Copy link
Contributor

mhugent commented May 12, 2014

assigned to @jef-n

@etiennesky
Copy link
Contributor Author

@jef-n any thoughts about this?

@strk
Copy link
Contributor

strk commented Sep 10, 2015

@etiennesky if this is still applicable, could you rebase to master and force-push ?
That way travis will also take a look at the code

@m-kuhn
Copy link
Member

m-kuhn commented May 14, 2016

@rouault any idea about this PR?

@rouault
Copy link
Contributor

rouault commented May 14, 2016

Several comments :

  • there's no legal problem in bundling vsipreload.cpp in QGIS. X/MIT is compatible with any other licenses
  • but normally this code should rather remain close to GDAL because it is close to its internals. And it should probably rather built and packaged as part of GDAL, if the need to make it more easily usable as currently arose
  • vsipreload is mostly a hack, and I wouldn't guarantee it is 100% bullet proof. It might potentially crash on /vsiXXXX paths if some glibc call has been forgotten to be overloaded (the calls to overload might depend on the versions of glibc). Standard glibc I/O operations on normal files (non /vsiXXXX paths) shouldn't be affected otherwise, except a slight slowdown (at least theoretically. I didn't benchmark) due to the extra processing done to check if the filename or FILE* object is a GDAL /vsiXXX/ path.
  • the scope of application in QGIS use cases is mostly restricted to netCDF, HDF4/5 files and a few estoreric formats contained in a compressed archive, so I'm not sure if the risk / benefit ratio is really worth it (obviously this is a biased opinion depending on the scope of interest of the user)

@m-kuhn
Copy link
Member

m-kuhn commented Aug 10, 2016

Closing this as of @rouault comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants