You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adds ENV variable that can be used to redirect /usr/include files from wrapper_open (#42)
* Redirect usr/include from open
* Some renames
* fix typo
* Combine both redirects into a single function
* Docs.md
* Allow override to auto redirect of /usr/lib as well change the env var from IDO_CC to USR_LIB
* PR review
* Fix comment
* Exit instead of silently fail
* get_env_var
* Fix usr/include doc comment
* move comment
IDO recomp currently has two forms of path redirection, both involving the `/usr` folder.
5
+
6
+
### `/usr/lib`
7
+
In order for users to not having to worry about installing the binaries in particular locations in `/usr/lib`, recomp automatically redirects `/usr/lib/` paths. This is done by determining the location of `cc` and redirecting to the same directory. This does mean all the binaries and `err.english.cc` are expected to be a part of a single flattened directory.
8
+
9
+
It is also possible to override the auto redirect by using the environment variable `USR_LIB` with the desired redirection path. This can be used if the binaries are not in a flattened directory with `cc` or if on Linux and are unable to read `/proc/self/exe`.
10
+
11
+
Wrapper functions implementing this redirection:
12
+
*`init_file`
13
+
*`wrapper_execvp`
14
+
15
+
### /usr/include
16
+
The other form of redirection is completely optional and is done by setting the environment variable `USR_INCLUDE` to the desired redirection path. This will than redirect all opened files files there. This is done so that the `mdebug` section file paths will still use `/usr/include` path, but the files themselves can be located elsewhere for greater flexibility.
0 commit comments