well, just copy/paste the lines to your terminal … then navigate in sublimes file chooser to ~/shmdir and you should be able to load/save files in /dev/shm to share them with other apps … (which is what the other thread was about)
If you’re creating your own sublimes-text snap, you probably can take a look this preloader.
It could override the path before really opening the target file.
yes, that is what i expected … the thread with the “workaround” you linked has nothing to do with that, it is about being able to share files between apps though /dev/shm
ERROR: ld.so: object ‘/snap/sublime-text/x1/lib/libsnapcraft-preload.so’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
well, for whatever strage reason the snapcraft-preload stuff seems to have landed in $SNAP/usr/local instead of the toplevel of $SNAP … not sure how that could happen if you didnt tinker with LIBPATH
so you probably want to patch usr/local/bin/snapcraft-preload to point to usr/local/lib instead of just lib/
though if thats really a snapcraft induced change as @lucyllewy suggests that smells really messy
(i personally often take quite some effort to not have such mess inside my snaps and have the prefix point properly to the toplevel $SNAP, having things default to add pointless directory struture that you need to compensate via hacks later feels very wrong)
yeah usr/ is fine as is / … i just dont want to also have usr/local/ in my snaps (and potentially have to patch common launchers and whatnot to make them respect this)
Admittedly we probably should have set this as a default parameter, but that boat has sailed now (as introducing that would break existing snaps relying on /usr/local).
@degville, is this change documented anywhere? I haven’t seen a migration guide for bringing a core18 snap up to core20 so if there isn’t one yet that would be a nice idea (I’m thinking I might have simply overlooked it)
If you are only changing the readme of preload to take this into account, maybe also add these lines to fix this warning:
The ‘snapcraft-preload’ part is missing libraries that are not included in the snap or base.
They can be satisfied by adding the following entry for this part
stage-packages:
lib32stdc++6
I believe work on a migration guide is underway, but for the time being I added some documentation for this case @ https://snapcraft.io/docs/cmake-plugin.