Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

questions about script findplugin.sh #2972

Closed
edwardhartnett opened this issue Aug 11, 2024 · 1 comment
Closed

questions about script findplugin.sh #2972

edwardhartnett opened this issue Aug 11, 2024 · 1 comment

Comments

@edwardhartnett
Copy link
Contributor

edwardhartnett commented Aug 11, 2024

Related to #2348

We have: ./plugins/findplugin.in

This is turned into findplugin.sh by configure and gets copied to multiple directories during the build by configure.ac:

for FP in plugins nc_test4 nczarr_test examples/C ; do
AC_CONFIG_FILES(${FP}/findplugin.sh:plugins/findplugin.in, [chmod ugo+x ${FP}/findplugin.sh])
done

And this results in:

find . -name "findplugin.sh"
./nc_test4/findplugin.sh
./examples/C/findplugin.sh
./nczarr_test/findplugin.sh
./plugins/findplugin.sh

findplugin is called from multiple test scripts, for example nc_test4/tst_filter_vlen.sh:

# Load the findplugins function
. ${builddir}/findplugin.sh
echo "findplugin.sh loaded"

findplugin h5deflate
echo "HDF5_PLUGIN_DIR=$HDF5_PLUGIN_DIR"

We clean these in our Makefile.am files:

find . -name Makefile.am |xargs grep findplugin
./nc_test4/Makefile.am:DISTCLEANFILES = findplugin.sh run_par_test.sh
./examples/C/Makefile.am:DISTCLEANFILES = findplugin.sh
./nczarr_test/Makefile.am:DISTCLEANFILES = findplugin.sh ${BUILT_SOURCES}
./plugins/Makefile.am:EXTRA_DIST = CMakeLists.txt findplugin.in
./plugins/Makefile.am:DISTCLEANFILES = H5Znoop1.c H5Znoop2.c ncjson.h findplugin.sh

Is there any documentation for this? If not, I can prepare some, once I understand it.

@DennisHeimbigner seems like all the plugin directory information should be available at configure-time. Why then have a script to find it at run-time?

@DWesl
Copy link
Contributor

DWesl commented Aug 15, 2024

Three of the four versions of findplugin.sh look like they are for tests, which might be run before installing the plugins to the location determined at build-time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants