mattias/spikboll wrote:
Hello, I have written a small app for school that uses a small module (written by me) and crt. It compiles fine with --automake, but I need to have a Makefile. My problem is that I don't know how to tell make to find crt.pas & co.
should I move crt.pas, gpc.pas and all files they depend on into the build directory?
No. `gpc --print-file-name=units' will output the directory name (igf installed correctly). In GNU make, something like this should work: GPC_UNIT_PATH:=$(shell $(PC) $(PFLAGS) --print-file-name=units) If it must work with other makes, I don't know what will work -- in the worst case, a recursive make invocation might do, something like: all: $(MAKE) GPC_UNIT_PATH=`$(PC) $(PFLAGS) --print-file-name=units` progs Of course, you could also put `gpc --automake' into the Makefile if that's "allowed" ... Frank -- Frank Heckenbach, frank@g-n-u.de, http://fjf.gnu.de/, 7977168E GPC To-Do list, latest features, fixed bugs: http://www.gnu-pascal.de/todo.html GPC download signing key: 51FF C1F0 1A77 C6C2 4482 4DDC 117A 9773 7F88 1707