diff options
| author | lijia <[email protected]> | 2024-04-09 10:11:58 +0800 |
|---|---|---|
| committer | lijia <[email protected]> | 2024-04-09 10:11:58 +0800 |
| commit | cf28256a57399fff8f0bd4e4267d57c17a49a685 (patch) | |
| tree | f56d6466f383865dd75dce7c6c74dced64729110 /cmake/PreInstall.sh | |
| parent | d2344728cc2fbec37b2186c05634ac509d2fc3c4 (diff) | |
fix build RPM package, update cmake/Preinsall, cmake/PreUninstallv0.0.1
Diffstat (limited to 'cmake/PreInstall.sh')
| -rw-r--r-- | cmake/PreInstall.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/cmake/PreInstall.sh b/cmake/PreInstall.sh new file mode 100644 index 0000000..db2b917 --- /dev/null +++ b/cmake/PreInstall.sh @@ -0,0 +1,13 @@ +DST=${RPM_INSTALL_PREFIX}/sapp/ + +mkdir -p ${DST}/stellar_plugin +touch ${DST}/stellar_plugin/spec.toml + +if ! grep -q '^\./plug/stellar_plugin/http_decoder.so' "${DST}/stellar_plugin/spec.toml"; then + echo -e "\n" >> "${DST}/stellar_plugin/spec.toml" + echo -e "[[plugin]]" >> "${DST}/stellar_plugin/spec.toml" + echo -e "path = \"./stellar_plugin/http_decoder/http_decoder.so\"" >> "${DST}/stellar_plugin/spec.toml" + echo -e "init = \"http_decoder_init\"" >> "${DST}/stellar_plugin/spec.toml" + echo -e "exit = \"http_decoder_exit\"" >> "${DST}/stellar_plugin/spec.toml" + echo -e "\n" >> "${DST}/stellar_plugin/spec.toml" +fi |
