Skip to content

Commit

Permalink
[build]: allow to use extra inc/lib location to build the package (so…
Browse files Browse the repository at this point in the history
…nic-net#595)

Signed-off-by: Guohan Lu <[email protected]>
  • Loading branch information
lguohan authored Apr 8, 2020
1 parent 9b8c63e commit 74af900
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/default.mk

ifneq (${SWSS_COMMON_INC},)
SWSS_COMMON_CONFIG = "--with-swss-common-inc=${SWSS_COMMON_INC}"
endif

ifneq (${SWSS_COMMON_LIB},)
SWSS_COMMON_CONFIG += "--with-swss-common-lib=${SWSS_COMMON_LIB}"
LD_LIBRARY_PATH_CONFIG = LD_LIBRARY_PATH=${SWSS_COMMON_LIB}
endif

# see FEATURE AREAS in dpkg-buildflags(1)
#export DEB_BUILD_MAINT_OPTIONS = hardening=+all

Expand Down Expand Up @@ -50,7 +59,7 @@ binary-syncd-vs:

override_dh_auto_configure:
./autogen.sh
dh_auto_configure -- $(shell cat /tmp/syncd-build)
dh_auto_configure -- $(shell cat /tmp/syncd-build) ${SWSS_COMMON_CONFIG}

override_dh_install:
dh_install
Expand All @@ -62,7 +71,7 @@ override_dh_installinit:
dh_installinit --init-script=syncd

override_dh_shlibdeps:
dh_shlibdeps --dpkg-shlibdeps-params=--ignore-missing-info
$(LD_LIBRARY_PATH_CONFIG) dh_shlibdeps --dpkg-shlibdeps-params=--ignore-missing-info

override_dh_strip:
dh_strip -psyncd-rpc --dbg-package=syncd-rpc-dbg
Expand Down

0 comments on commit 74af900

Please sign in to comment.