#!/usr/bin/make -f

export AUTOPOINT = true

include /usr/share/cdbs/1/rules/autoreconf.mk
include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/gnome.mk

# List any files which are not installed
include /usr/share/cdbs/1/rules/utils.mk
common-binary-post-install-arch:: list-missing

# Ensure at build time that the library has no dependencies on undefined
# symbols, and speed up loading.
LDFLAGS += -Wl,-z,defs -Wl,-O1

DEB_CONFIGURE_EXTRA_FLAGS := --enable-spell=yes \
                             --enable-webkit=yes \
                             --enable-map=no \
                             --enable-location=no \
                             --enable-geocode=no \
                             --enable-gudev=yes \
                             --enable-call-logs=yes \
                             --enable-call=yes \
                             --enable-goa=yes \
                             --enable-libunity=yes \
                             --enable-nautilus-sendto=yes \
                             --enable-control-center-embedding=yes \
                             --enable-empathy-av \
                             --disable-schemas-compile

DEB_BUILD_ARCH_OS := $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)

ifeq ($(DEB_BUILD_ARCH_OS),linux)
  DEB_CONFIGURE_EXTRA_FLAGS += --with-connectivity=nm --enable-location=no
else ifeq ($(DEB_BUILD_ARCH_OS),kfreebsd)
  DEB_CONFIGURE_EXTRA_FLAGS += --with-connectivity=no --enable-location=no
else
  DEB_CONFIGURE_EXTRA_FLAGS += --with-connectivity=no --enable-location=no
endif

DEB_DH_MAKESHLIBS_ARGS_empathy = --no-act

include $(CURDIR)/debian/update-patches.mk
