#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
#export DH_OPTIONS=-v

DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)

ifeq ($(DEB_HOST_ARCH_OS),illumos)
	LIBS = -lsocket -lnsl
endif

%:
	dh  $@

override_dh_auto_build:
	prefix=$(CURDIR)/debian/cvsps/usr LIBS="$(LIBS)" $(MAKE)

override_dh_auto_install:
	prefix=$(CURDIR)/debian/cvsps/usr LIBS="$(LIBS)" $(MAKE) install
