Closed gbonnema closed 7 years ago
I solved this issue in the branch autotools (branch not pulled yet) using standard autotools methods. In stead of the hardcoded library (was set to "/usr/local/lib/xwpe" in the code), I just do a preprocessor error if LIBRARY_DIR is not defined. The value should always come from a userdefined value or the default out of the Makefile.am and configure.ac.
in
unixkeys.h
I found a conditional define for LIBRARY_DIR that I would not expect in the program code. I still have to find out what it does exactly, but it seems that xwpe stores data in that directory.I have to delve some deeper, but I am pretty sure, this should not be hard code, but part of the generation process of the autotools.
Let me know whether you agree,
EDIT: Correction. In the old Makefile.in this was coded in as $(LIBDIR)/xwpe. Nonetheless, I think directories or files should not be hardcoded into source. Better to fail gracefully than to hardcode a file or directory. Do you agree?