ObjFW  Makefile at [823d308096]

File generators/Makefile artifact 20ac2c40c4 part of check-in 823d308096


PROG_NOINST = gen_tables${PROG_SUFFIX}
SRCS = gen_tables.m

.PHONY: run
run: all
	rm -f libobjfw.so.0 libobjfw.so.0.1 libobjfw.dll libobjfw.dylib
	if test -f ../src/libobjfw.so; then \
		ln -s ../src/libobjfw.so libobjfw.so.0; \
		ln -s ../src/libobjfw.so libobjfw.so.0.1; \
	elif test -f ../src/libobjfw.so.0.1; then \
		ln -s ../src/libobjfw.so.0.1 libobjfw.so.0.1; \
	fi
	if test -f ../src/libobjfw.dll; then \
		ln ../src/libobjfw.dll libobjfw.dll; \
	fi
	if test -f ../src/libobjfw.dylib; then \
		ln -s ../src/libobjfw.dylib libobjfw.dylib; \
	fi
	echo "Generating tables..."
	LD_LIBRARY_PATH=.$${LD_LIBRARY_PATH+:}$$LD_LIBRARY_PATH \
	DYLD_LIBRARY_PATH=.$${DYLD_LIBRARY_PATH+:}$$DYLD_LIBRARY_PATH \
	${TEST_LAUNCHER} ./${PROG_NOINST}; EXIT=$$?; \
	rm -f libobjfw.so.0 libobjfw.so.0.1 libobjfw.dll libobjfw.dylib; \
	exit $$EXIT

include ../buildsys.mk

CPPFLAGS += -I../src -I..
LIBS := -L../src -lobjfw ${LIBS}