Mercurial > hgrepos > Python2 > PyMuPDF
comparison mupdf-source/scripts/destatic.sh @ 2:b50eed0cc0ef upstream
ADD: MuPDF v1.26.7: the MuPDF source as downloaded by a default build of PyMuPDF 1.26.4.
The directory name has changed: no version number in the expanded directory now.
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Mon, 15 Sep 2025 11:43:07 +0200 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 1:1d09e1dec1d9 | 2:b50eed0cc0ef |
|---|---|
| 1 # Simple script to make all static functions in the main source | |
| 2 # unstatic. This allows backtracing functions (such as that used | |
| 3 # in Memento, in particular on Android) to pick up symbol names | |
| 4 # nicely. | |
| 5 # | |
| 6 # This script can be reversed using restatic.sh | |
| 7 | |
| 8 # Allow for the fact that mujs might not be present | |
| 9 MUJS_SRC= | |
| 10 test -d thirdparty/mujs && MUJS_SRC=thirdparty/mujs | |
| 11 | |
| 12 # Convert everything | |
| 13 sed -i '/^static inline/b;/^static const/b;s!^static !/\*static \*/!' $(find source platform/android/viewer platform/java $MUJS_SRC -name '*.c') | |
| 14 | |
| 15 # Convert source/tools back again. | |
| 16 sed -i 's!/\*static \*/!static !' $(find source/tools -name '*.c') |
