]> xenbits.xensource.com Git - xen.git/commitdiff
tools/configure: fix pkg-config install path for FreeBSD
authorRoger Pau Monne <roger.pau@citrix.com>
Tue, 25 Oct 2016 09:53:28 +0000 (11:53 +0200)
committerWei Liu <wei.liu2@citrix.com>
Wed, 26 Oct 2016 11:37:34 +0000 (12:37 +0100)
pkg-config from FreeBSD ports doesn't have ${prefix}/share/pkgconfig in the
default search path, fix this by having a PKG_INSTALLDIR variable that can
be changed on a per-OS basis.

It would be best to use PKG_INSTALLDIR as defined by the pkg.m4 macro, but
sadly this also reports a wrong value on FreeBSD (${libdir}/pkgconfig, which
expands to /usr/local/lib/pkgconfig by default, and is also _not_ part of
the default pkg-config search path).

This patch should not change the behavior for Linux installs.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reported-by: Alexander Nusov <alexander.nusov@nfvexpress.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
Release-acked-by: Wei Liu <wei.liu2@citrix.com>
config/FreeBSD.mk
config/Paths.mk.in
tools/libxl/Makefile

index bb3a5d0bebc0c36998ddafca825e1c745b839467..afeaefbde27efe171683d800b2bcfc4214ab3acc 100644 (file)
@@ -2,3 +2,4 @@ include $(XEN_ROOT)/config/StdGNU.mk
 
 # No wget on FreeBSD base system
 WGET = ftp
+PKG_INSTALLDIR = ${prefix}/libdata/pkgconfig
index 62cea48a582911c0f059b36e5d6c2a9ed4226313..a60329514632a4f744507a4b687ede59cfe4c447 100644 (file)
@@ -56,3 +56,5 @@ XENFIRMWAREDIR           := @XENFIRMWAREDIR@
 
 XEN_CONFIG_DIR           := @XEN_CONFIG_DIR@
 XEN_SCRIPT_DIR           := @XEN_SCRIPT_DIR@
+
+PKG_INSTALLDIR           := ${SHAREDIR}/pkgconfig
index 79e40199ace2de01f50e214485b6fd6dbb3921aa..af0a3ad7cb13e416bf1ddebbe9b80b14409a110d 100644 (file)
@@ -320,8 +320,8 @@ install: all
        $(INSTALL_DATA) libxlutil.a $(DESTDIR)$(libdir)
        $(INSTALL_DATA) libxl.h libxl_event.h libxl_json.h _libxl_types.h _libxl_types_json.h _libxl_list.h libxl_utils.h libxl_uuid.h libxlutil.h $(DESTDIR)$(includedir)
        $(INSTALL_DATA) bash-completion $(DESTDIR)$(BASH_COMPLETION_DIR)/xl.sh
-       $(INSTALL_DATA) xenlight.pc $(DESTDIR)$(SHAREDIR)/pkgconfig/
-       $(INSTALL_DATA) xlutil.pc $(DESTDIR)$(SHAREDIR)/pkgconfig/
+       $(INSTALL_DATA) xenlight.pc $(DESTDIR)$(PKG_INSTALLDIR)
+       $(INSTALL_DATA) xlutil.pc $(DESTDIR)$(PKG_INSTALLDIR)
 
 .PHONY: clean
 clean: