#!/usr/bin/make -f
# -*- makefile -*-
# This file was originally written by Joey Hess and Craig Small.
# As a special exception, when this file is copied by dh-make into a
# dh-make output file, you may use that output file without restriction.
# This special exception was added by Craig Small in version 0.37 of dh-make.

DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)

.PHONY: override_dh_auto_configure \
        override_dh_auto_build-indep \
        override_dh_strip 

%:
	dh $@ --parallel

override_dh_auto_configure:
	dh_auto_configure -- \
            -DUSE_EXTERNAL_URDF:BOOL=True \
            -DUSE_UPSTREAM_CFLAGS:BOOL=False \
            -DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo

override_dh_auto_build-indep:
	dh_auto_build -- doc # Generate documentation.

# Test suite is only able to run on amd64
# Still needs debugging
ifneq ($(DEB_BUILD_ARCH), amd64)
override_dh_auto_test:
	true
endif
 
override_dh_strip:
	dh_strip -a --dbg-package=libsdformat2-dbg
