wolfgentleman
August 9th, 2014, 10:39 AM
I have a set of binaries, 2 regular and 3+ libraries. Some libraries are in sub-folders. I want to launch the main binary in such a way that it places any files it creates into a folder above it. Here is a generic layout before and after the run.
Before:
BaseDir
exec
lib1.so
libDir
library1a.so
library1b.so
textfile.txt
OtherDir
After (how it is now):
BaseDir
exec
lib1.so
libDir
library1a.so
library1b.so
textfile.txt
someDir
generatedFile.txt
otherGeneratedFile.txt
OtherDir
After (how I want it):
BaseDir
exec
lib1.so
libDir
library1a.so
library1b.so
textfile.txt
OtherDir
someDir
generatedFile.txt
otherGeneratedFile.txt
So, how can I launch it in such a way that it writes/reads generated files/folders to 'OtherDir', but still use the libraries and run the other executable (which is in a sub-directory of 'BaseDir') without linking the entire contents of 'BaseDir' into 'OtherDir'. I just so everyone knows: this is a closed source and commercial program that, with the permission of the developers, I am making a deb package for. The files it generates are databases and uploaded content, of which would get destroyed on an upgrade - I did it without backing up the folder and poof...
Before:
BaseDir
exec
lib1.so
libDir
library1a.so
library1b.so
textfile.txt
OtherDir
After (how it is now):
BaseDir
exec
lib1.so
libDir
library1a.so
library1b.so
textfile.txt
someDir
generatedFile.txt
otherGeneratedFile.txt
OtherDir
After (how I want it):
BaseDir
exec
lib1.so
libDir
library1a.so
library1b.so
textfile.txt
OtherDir
someDir
generatedFile.txt
otherGeneratedFile.txt
So, how can I launch it in such a way that it writes/reads generated files/folders to 'OtherDir', but still use the libraries and run the other executable (which is in a sub-directory of 'BaseDir') without linking the entire contents of 'BaseDir' into 'OtherDir'. I just so everyone knows: this is a closed source and commercial program that, with the permission of the developers, I am making a deb package for. The files it generates are databases and uploaded content, of which would get destroyed on an upgrade - I did it without backing up the folder and poof...