In bash, if try to run the function basename within the -exec option of find, it doesn't seem to do anything. As an example:
find . -name "*pdf" -exec echo $(basename {}) \;
yields the filename including the directory, i.e., the same as the result of
find . -name "*pdf" -exec echo {} \;
Why does this happen?