#Copyright (C) 2007 Justin M. Tulloss

include @top_builddir@/defs.mak

ifdef ROOTDIR
	SET_ROOT_DIR = "--root=$(ROOTDIR)"
endif

all:
	$(PYTHON) setup.py build_ext $(DEBUGFLAGS) -I@top_builddir@/libcwiid -L@top_builddir@/libcwiid -lcwiid

install:
	$(PYTHON) setup.py install --install-lib=${libdir}/python@PYTHON_VERSION@/site-packages $(SET_ROOT_DIR)

uninstall:
	rm -f $(ROOTDIR)${libdir}/python@PYTHON_VERSION@/site-packages/cwiid.so

clean:
	rm -rf build

distclean: clean
	rm Makefile

.PHONY: all install uninstall clean distclean
