# BlinkenLib # version 0.6.0 date 2008-05-15 # Copyright 2004-2008 Stefan Schuermans # Copyleft: GNU public license - http://www.gnu.org/copyleft/gpl.html # a blinkenarea.org project INSTALL=install VERSION_MAJOR=0 VERSION_MINOR=6 VERSION_REVISION=0 VERSION=$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_REVISION) ENV_PREFIX=$(shell echo $$PREFIX) STOW_DIR=/usr/local/stow STOW_PREFIX=$(STOW_DIR)/BlinkenLib-$(VERSION) DEF_PREFIX=/usr/local ifneq ($(ENV_PREFIX),) PREFIX=$(ENV_PREFIX) else ifeq ($(shell if [ -d $(STOW_DIR) ]; then echo stow; fi),stow) PREFIX=$(STOW_PREFIX) else PREFIX=$(DEF_PREFIX) endif endif HEADERS=BlinkenLib.h BlinkenMovie.h BlinkenFrame.h BlinkenColorizer.h config.h LIBS=libBlinkenLib.a libBlinkenLib.so.$(VERSION) EXECS=BlinkenConv BlinkenSend BlinkenRecv BlinkenOutput .phony: all conf clean distclean install uninstall all: conf $(MAKE) -C BlinkenLib all conf: $(MAKE) -C config all clean: conf $(MAKE) -C BlinkenLib clean distclean: clean $(MAKE) -C config clean install: all $(INSTALL) -d $(PREFIX)/include/BlinkenLib $(INSTALL) -t $(PREFIX)/include/BlinkenLib $(addprefix BlinkenLib/, $(HEADERS)) $(INSTALL) -d $(PREFIX)/lib $(INSTALL) -t $(PREFIX)/lib $(addprefix BlinkenLib/, $(LIBS)) ln -sf libBlinkenLib.so.$(VERSION) $(PREFIX)/lib/libBlinkenLib.so.$(VERSION_MAJOR) ln -sf libBlinkenLib.so.$(VERSION_MAJOR) $(PREFIX)/lib/libBlinkenLib.so $(INSTALL) -d $(PREFIX)/bin $(INSTALL) -t $(PREFIX)/bin $(addprefix BlinkenLib/, $(EXECS)) uninstall: rm -f $(addprefix $(PREFIX)/bin/, $(EXECS)) rm -f $(PREFIX)/lib/libBlinkenLib.so rm -f $(PREFIX)/lib/libBlinkenLib.so.$(VERSION_MAJOR) rm -f $(addprefix $(PREFIX)/lib/, $(LIBS)) rm -rf $(PREFIX)/include/BlinkenLib