Skip to content

Commit

Permalink
[build]: allow to use extra inc/lib location to build the package (#595)
Browse files Browse the repository at this point in the history
Signed-off-by: Guohan Lu <[email protected]>
  • Loading branch information
lguohan authored and abdosi committed Oct 6, 2021
1 parent 40d3487 commit 6cfb3ec
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 @@ -56,7 +65,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 @@ -68,7 +77,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 6cfb3ec

Please sign in to comment.