Skip to content

Commit b373a19

Browse files
committed
Add lib4bin hooks
Add lib4bin compression Add LIBDECOR_PLUGIN_DIR env Add GTK_IM_MODULE_FILE env Refactoring
1 parent f680adf commit b373a19

File tree

4 files changed

+261
-120
lines changed

4 files changed

+261
-120
lines changed

Cargo.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "sharun"
3-
version = "0.1.9"
3+
version = "0.2.1"
44
readme = "README.md"
55
license = "MIT"
66
repository = "https://github.com/VHSgunzo/sharun"
@@ -22,5 +22,8 @@ opt-level = 0
2222
[dependencies]
2323
which = "7.0.0"
2424
walkdir = "2.5.0"
25+
flate2 = "1.0.35"
2526
userland-execve = "0.2.0"
27+
include_file_compress = "0.1.3"
28+
nix = { version = "0.29.0", features = [ "fs" ] }
2629
dotenv = { git = "https://github.com/VHSgunzo/dotenv.git" }

README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ cp ./target/$(uname -m)-unknown-linux-musl/release/sharun .
3838
3939
[ Options ]:
4040
l, lib4bin [ARGS] Launch the built-in lib4bin
41-
-g, --gen-lib-path Generate library path file
41+
-g, --gen-lib-path Generate a lib.path file
4242
-v, --version Print version
4343
-h, --help Print help
4444
@@ -50,7 +50,7 @@ cp ./target/$(uname -m)-unknown-linux-musl/release/sharun .
5050

5151
## Usage lib4bin:
5252
```
53-
[ Usage ]: lib4bin [OPTIONS] /path/executable -- [STRACE CMD ARGS]
53+
[ Usage ]: lib4bin [OPTIONS] /path/executable -- [STRACE MODE EXEC ARGS]
5454
5555
[ Options ]:
5656
-a, --any-executable Pack any executable (env: ANY_EXECUTABLE=1)
@@ -59,7 +59,8 @@ cp ./target/$(uname -m)-unknown-linux-musl/release/sharun .
5959
-g, --gen-lib-path Generate a lib.path file (env: GEN_LIB_PATH=1)
6060
-h, --help Show this message
6161
-i, --patch-interpreter Patch INTERPRETER to a relative path (env: PATCH_INTERPRETER=1)
62-
-l, --libs-only Pack only libraries (env: LIBS_ONLY=1)
62+
-k, --with-hooks Pack additional files required for libraries (env: WITH_HOOKS=1)
63+
-l, --libs-only Pack only libraries without executables (env: LIBS_ONLY=1)
6364
-n, --not-one-dir Separate directories for each executable (env: ONE_DIR=0)
6465
-p, --hard-links Pack sharun and create hard links (env: HARD_LINKS=1)
6566
-q, --quiet-mode Show only errors (env: QUIET_MODE=1)
@@ -110,6 +111,8 @@ cp ./target/$(uname -m)-unknown-linux-musl/release/sharun .
110111
* `TK_LIBRARY` -- `${SHARUN_DIR}/shared/$LIB/tk*`
111112
* `GST_PLUGIN_PATH`, `GST_PLUGIN_SYSTEM_PATH`, `GST_PLUGIN_SYSTEM_PATH_1_0`, and `GST_PLUGIN_SCANNER` -- `${SHARUN_DIR}/shared/$LIB/gstreamer-*`
112113
* `GDK_PIXBUF_MODULEDIR` and `GDK_PIXBUF_MODULE_FILE` -- `${SHARUN_DIR}/shared/$LIB/gdk-pixbuf-*`
114+
* `LIBDECOR_PLUGIN_DIR` -- `${SHARUN_DIR}/shared/$LIB/libdecor/plugins-1`
115+
* `GTK_IM_MODULE_FILE` -- `${SHARUN_DIR}/shared/$LIB/gtk-*/*/immodules.cache`
113116

114117
* `XDG_DATA_DIRS` -- `${SHARUN_DIR}/share`
115118
* `VK_DRIVER_FILES` -- `${SHARUN_DIR}/share/vulkan/icd.d`

0 commit comments

Comments
 (0)