From nobody Thu May 2 21:15:36 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail(p=none dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1573834635; cv=none; d=zoho.com; s=zohoarc; b=D3iqe6uwYFT80gULwqbgfgFeEZkKE7VctHZriaP/yTTu3AvDnj/K86gYZo8PEgrlV8LJc/jcXwU4VhPGfjbO++Lw7tZeiqdcuJcFRI89Ob8YArHx9+ChEo4yNweuOiMAvufNnaX6Fty9Y0X4/1Tv7nn0rt+g8wiRUGZPRO6exFk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1573834635; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=EZAWoUBZX6ybVxTWnCYRm19d6A5FfArexWhKl6ZCCKE=; b=mXjl5lWoDhKTpJApnAmxKzxfXxyXFgXmZ3PrEJPm0OZkG0MgS6ccriIqnaiLHCX9NqwTJ5qSOSZpQKjEJqnfjtcKjbSZ8WgZ4dJX8WbFBoCQoPis4Ncw75Te0QdCKO+P7VQgZpcR67+Ifsc3lo3p9T7JwDkj2Qr0YhB8eUtRh9w= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1573834635122425.72268349738135; Fri, 15 Nov 2019 08:17:15 -0800 (PST) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1iVeGI-0003pk-FL; Fri, 15 Nov 2019 16:15:54 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1iVeGG-0003pD-UA for xen-devel@lists.xenproject.org; Fri, 15 Nov 2019 16:15:52 +0000 Received: from esa6.hc3370-68.iphmx.com (unknown [216.71.155.175]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 30d994c8-07c3-11ea-984a-bc764e2007e4; Fri, 15 Nov 2019 16:15:51 +0000 (UTC) X-Inumbo-ID: 30d994c8-07c3-11ea-984a-bc764e2007e4 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1573834551; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=uFsINF959KpmSs5vVmdqRMUHp5UENCAiWAWbyxzMbNs=; b=aETMQBXLHDAyikP0BMJO9qAloUaj7/C8gfvaXwjr70xzSnRzPD+5Ld8P +9VcrUXe42H6xyBuHyYaNVtqHBL+1ixU/pBZHcezaSTWmtplmepcQ4bgM PDxQbUokfbqSA6e52oXsa4h2tFStt3xtHDWvxdR2yeLElcYKAJuAtJKbl A=; Authentication-Results: esa6.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none; spf=None smtp.pra=anthony.perard@citrix.com; spf=Pass smtp.mailfrom=anthony.perard@citrix.com; spf=None smtp.helo=postmaster@mail.citrix.com Received-SPF: none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Received-SPF: None (esa6.hc3370-68.iphmx.com: no sender authenticity information available from domain of anthony.perard@citrix.com) identity=pra; client-ip=162.221.158.21; receiver=esa6.hc3370-68.iphmx.com; envelope-from="anthony.perard@citrix.com"; x-sender="anthony.perard@citrix.com"; x-conformance=sidf_compatible Received-SPF: Pass (esa6.hc3370-68.iphmx.com: domain of anthony.perard@citrix.com designates 162.221.158.21 as permitted sender) identity=mailfrom; client-ip=162.221.158.21; receiver=esa6.hc3370-68.iphmx.com; envelope-from="anthony.perard@citrix.com"; x-sender="anthony.perard@citrix.com"; x-conformance=sidf_compatible; x-record-type="v=spf1"; x-record-text="v=spf1 ip4:209.167.231.154 ip4:178.63.86.133 ip4:195.66.111.40/30 ip4:85.115.9.32/28 ip4:199.102.83.4 ip4:192.28.146.160 ip4:192.28.146.107 ip4:216.52.6.88 ip4:216.52.6.188 ip4:162.221.158.21 ip4:162.221.156.83 ip4:168.245.78.127 ~all" Received-SPF: None (esa6.hc3370-68.iphmx.com: no sender authenticity information available from domain of postmaster@mail.citrix.com) identity=helo; client-ip=162.221.158.21; receiver=esa6.hc3370-68.iphmx.com; envelope-from="anthony.perard@citrix.com"; x-sender="postmaster@mail.citrix.com"; x-conformance=sidf_compatible IronPort-SDR: nVzFnONYrem1l/B8FtGz3IMJHGuVYfnHTiNSf/ZGDG6e91lDdQ/Vkcfv1TJhgSgr2WaP1y8a0o h+/SyVBk5z9Ovih7fuc3SyrQbz+61KoXUA+6HiOpNgiRw52aLH0sU9Pxx5HcVHyCiNCqTxZVcT zu3xKCKy9TTG2bXd9wkA7ne2xXqTaX9dbYnW8XFeQW4JPiR8gvle4IwYLsKRCAzRakgXqmU/iw pwm4/EfWW0SqH9K3GwgJD65+AkBsCZBtQqHSk4Ed465oCni3cElBDp+IwEGmibF5LoVrhA73a4 isA= X-SBRS: 2.7 X-MesageID: 8804499 X-Ironport-Server: esa6.hc3370-68.iphmx.com X-Remote-IP: 162.221.158.21 X-Policy: $RELAYED X-IronPort-AV: E=Sophos;i="5.68,308,1569297600"; d="scan'208";a="8804499" From: Anthony PERARD To: Date: Fri, 15 Nov 2019 16:15:32 +0000 Message-ID: <20191115161532.1231811-1-anthony.perard@citrix.com> X-Mailer: git-send-email 2.24.0 MIME-Version: 1.0 Subject: [Xen-devel] [XEN PATCH for-4.13] configure: Fix test for python 3.8 X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: =?UTF-8?q?J=C3=BCrgen=20Gro=C3=9F?= , Samuel Thibault , Ian Jackson , Wei Liu , Anthony PERARD Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) https://docs.python.org/3.8/whatsnew/3.8.html#debug-build-uses-the-same-abi= -as-release-build > To embed Python into an application, a new --embed option must be > passed to python3-config --libs --embed to get -lpython3.8 (link the > application to libpython). To support both 3.8 and older, try > python3-config --libs --embed first and fallback to python3-config > --libs (without --embed) if the previous command fails. Signed-off-by: Anthony PERARD Acked-by: Wei Liu --- Notes: You may want to rerun ./autogen.sh on commit. configure | 14 +------------- docs/configure | 14 +------------- m4/python_devel.m4 | 11 +++++++++-- stubdom/configure | 14 +------------- tools/configure | 33 +++++++++++++-------------------- 5 files changed, 25 insertions(+), 61 deletions(-) diff --git a/configure b/configure index 4d258eb61534..6ddcf52d9c1b 100755 --- a/configure +++ b/configure @@ -644,7 +644,6 @@ infodir docdir oldincludedir includedir -runstatedir localstatedir sharedstatedir sysconfdir @@ -723,7 +722,6 @@ datadir=3D'${datarootdir}' sysconfdir=3D'${prefix}/etc' sharedstatedir=3D'${prefix}/com' localstatedir=3D'${prefix}/var' -runstatedir=3D'${localstatedir}/run' includedir=3D'${prefix}/include' oldincludedir=3D'/usr/include' docdir=3D'${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -976,15 +974,6 @@ do | -silent | --silent | --silen | --sile | --sil) silent=3Dyes ;; =20 - -runstatedir | --runstatedir | --runstatedi | --runstated \ - | --runstate | --runstat | --runsta | --runst | --runs \ - | --run | --ru | --r) - ac_prev=3Drunstatedir ;; - -runstatedir=3D* | --runstatedir=3D* | --runstatedi=3D* | --runstated=3D= * \ - | --runstate=3D* | --runstat=3D* | --runsta=3D* | --runst=3D* | --runs= =3D* \ - | --run=3D* | --ru=3D* | --r=3D*) - runstatedir=3D$ac_optarg ;; - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=3Dsbindir ;; -sbindir=3D* | --sbindir=3D* | --sbindi=3D* | --sbind=3D* | --sbin=3D* \ @@ -1122,7 +1111,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir runstatedir + libdir localedir mandir do eval ac_val=3D\$$ac_var # Remove trailing slashes. @@ -1275,7 +1264,6 @@ Fine tuning of the installation directories: --sysconfdir=3DDIR read-only single-machine data [PREFIX/etc] --sharedstatedir=3DDIR modifiable architecture-independent data [PREF= IX/com] --localstatedir=3DDIR modifiable single-machine data [PREFIX/var] - --runstatedir=3DDIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=3DDIR object code libraries [EPREFIX/lib] --includedir=3DDIR C header files [PREFIX/include] --oldincludedir=3DDIR C header files for non-gcc [/usr/include] diff --git a/docs/configure b/docs/configure index e81644752f43..ca5e28264634 100755 --- a/docs/configure +++ b/docs/configure @@ -634,7 +634,6 @@ infodir docdir oldincludedir includedir -runstatedir localstatedir sharedstatedir sysconfdir @@ -711,7 +710,6 @@ datadir=3D'${datarootdir}' sysconfdir=3D'${prefix}/etc' sharedstatedir=3D'${prefix}/com' localstatedir=3D'${prefix}/var' -runstatedir=3D'${localstatedir}/run' includedir=3D'${prefix}/include' oldincludedir=3D'/usr/include' docdir=3D'${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -964,15 +962,6 @@ do | -silent | --silent | --silen | --sile | --sil) silent=3Dyes ;; =20 - -runstatedir | --runstatedir | --runstatedi | --runstated \ - | --runstate | --runstat | --runsta | --runst | --runs \ - | --run | --ru | --r) - ac_prev=3Drunstatedir ;; - -runstatedir=3D* | --runstatedir=3D* | --runstatedi=3D* | --runstated=3D= * \ - | --runstate=3D* | --runstat=3D* | --runsta=3D* | --runst=3D* | --runs= =3D* \ - | --run=3D* | --ru=3D* | --r=3D*) - runstatedir=3D$ac_optarg ;; - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=3Dsbindir ;; -sbindir=3D* | --sbindir=3D* | --sbindi=3D* | --sbind=3D* | --sbin=3D* \ @@ -1110,7 +1099,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir runstatedir + libdir localedir mandir do eval ac_val=3D\$$ac_var # Remove trailing slashes. @@ -1263,7 +1252,6 @@ Fine tuning of the installation directories: --sysconfdir=3DDIR read-only single-machine data [PREFIX/etc] --sharedstatedir=3DDIR modifiable architecture-independent data [PREF= IX/com] --localstatedir=3DDIR modifiable single-machine data [PREFIX/var] - --runstatedir=3DDIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=3DDIR object code libraries [EPREFIX/lib] --includedir=3DDIR C header files [PREFIX/include] --oldincludedir=3DDIR C header files for non-gcc [/usr/include] diff --git a/m4/python_devel.m4 b/m4/python_devel.m4 index e365cd658e0e..bbf1e0354b2b 100644 --- a/m4/python_devel.m4 +++ b/m4/python_devel.m4 @@ -23,8 +23,15 @@ AS_IF([test x"$pyconfig" =3D x"no"], [ ], [ dnl If python-config is found use it CPPFLAGS=3D"$CFLAGS `$PYTHON-config --cflags`" - LDFLAGS=3D"$LDFLAGS `$PYTHON-config --ldflags`" - LIBS=3D"$LIBS `$PYTHON-config --libs`" + dnl We need to use --embed with python 3.8 but not with earlier versio= n so + dnl check if it is recognized. + python_devel_embed=3D"" + if $PYTHON-config --embed >/dev/null 2>/dev/null; then + python_devel_embed=3D"--embed" + fi + LDFLAGS=3D"$LDFLAGS `$PYTHON-config --ldflags $python_devel_embed`" + LIBS=3D"$LIBS `$PYTHON-config --libs $python_devel_embed`" + unset python_devel_embed ]) =20 AC_CHECK_HEADER([Python.h], [], diff --git a/stubdom/configure b/stubdom/configure index beeb8db2e1fc..95ed9810efc9 100755 --- a/stubdom/configure +++ b/stubdom/configure @@ -661,7 +661,6 @@ infodir docdir oldincludedir includedir -runstatedir localstatedir sharedstatedir sysconfdir @@ -751,7 +750,6 @@ datadir=3D'${datarootdir}' sysconfdir=3D'${prefix}/etc' sharedstatedir=3D'${prefix}/com' localstatedir=3D'${prefix}/var' -runstatedir=3D'${localstatedir}/run' includedir=3D'${prefix}/include' oldincludedir=3D'/usr/include' docdir=3D'${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -1004,15 +1002,6 @@ do | -silent | --silent | --silen | --sile | --sil) silent=3Dyes ;; =20 - -runstatedir | --runstatedir | --runstatedi | --runstated \ - | --runstate | --runstat | --runsta | --runst | --runs \ - | --run | --ru | --r) - ac_prev=3Drunstatedir ;; - -runstatedir=3D* | --runstatedir=3D* | --runstatedi=3D* | --runstated=3D= * \ - | --runstate=3D* | --runstat=3D* | --runsta=3D* | --runst=3D* | --runs= =3D* \ - | --run=3D* | --ru=3D* | --r=3D*) - runstatedir=3D$ac_optarg ;; - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=3Dsbindir ;; -sbindir=3D* | --sbindir=3D* | --sbindi=3D* | --sbind=3D* | --sbin=3D* \ @@ -1150,7 +1139,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir runstatedir + libdir localedir mandir do eval ac_val=3D\$$ac_var # Remove trailing slashes. @@ -1303,7 +1292,6 @@ Fine tuning of the installation directories: --sysconfdir=3DDIR read-only single-machine data [PREFIX/etc] --sharedstatedir=3DDIR modifiable architecture-independent data [PREF= IX/com] --localstatedir=3DDIR modifiable single-machine data [PREFIX/var] - --runstatedir=3DDIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=3DDIR object code libraries [EPREFIX/lib] --includedir=3DDIR C header files [PREFIX/include] --oldincludedir=3DDIR C header files for non-gcc [/usr/include] diff --git a/tools/configure b/tools/configure index 82947ad30834..c43c8c21be12 100755 --- a/tools/configure +++ b/tools/configure @@ -770,7 +770,6 @@ infodir docdir oldincludedir includedir -runstatedir localstatedir sharedstatedir sysconfdir @@ -896,7 +895,6 @@ datadir=3D'${datarootdir}' sysconfdir=3D'${prefix}/etc' sharedstatedir=3D'${prefix}/com' localstatedir=3D'${prefix}/var' -runstatedir=3D'${localstatedir}/run' includedir=3D'${prefix}/include' oldincludedir=3D'/usr/include' docdir=3D'${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -1149,15 +1147,6 @@ do | -silent | --silent | --silen | --sile | --sil) silent=3Dyes ;; =20 - -runstatedir | --runstatedir | --runstatedi | --runstated \ - | --runstate | --runstat | --runsta | --runst | --runs \ - | --run | --ru | --r) - ac_prev=3Drunstatedir ;; - -runstatedir=3D* | --runstatedir=3D* | --runstatedi=3D* | --runstated=3D= * \ - | --runstate=3D* | --runstat=3D* | --runsta=3D* | --runst=3D* | --runs= =3D* \ - | --run=3D* | --ru=3D* | --r=3D*) - runstatedir=3D$ac_optarg ;; - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=3Dsbindir ;; -sbindir=3D* | --sbindir=3D* | --sbindi=3D* | --sbind=3D* | --sbin=3D* \ @@ -1295,7 +1284,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir runstatedir + libdir localedir mandir do eval ac_val=3D\$$ac_var # Remove trailing slashes. @@ -1448,7 +1437,6 @@ Fine tuning of the installation directories: --sysconfdir=3DDIR read-only single-machine data [PREFIX/etc] --sharedstatedir=3DDIR modifiable architecture-independent data [PREF= IX/com] --localstatedir=3DDIR modifiable single-machine data [PREFIX/var] - --runstatedir=3DDIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=3DDIR object code libraries [EPREFIX/lib] --includedir=3DDIR C header files [PREFIX/include] --oldincludedir=3DDIR C header files for non-gcc [/usr/include] @@ -3378,7 +3366,7 @@ else We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) <<= 31)) +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 =3D=3D 721 && LARGE_OFF_T % 2147483647 =3D=3D 1) ? 1 : -1]; @@ -3424,7 +3412,7 @@ else We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) <<= 31)) +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 =3D=3D 721 && LARGE_OFF_T % 2147483647 =3D=3D 1) ? 1 : -1]; @@ -3448,7 +3436,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.= $ac_ext We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) <<= 31)) +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 =3D=3D 721 && LARGE_OFF_T % 2147483647 =3D=3D 1) ? 1 : -1]; @@ -3493,7 +3481,7 @@ else We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) <<= 31)) +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 =3D=3D 721 && LARGE_OFF_T % 2147483647 =3D=3D 1) ? 1 : -1]; @@ -3517,7 +3505,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.= $ac_ext We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) <<= 31)) +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) int off_t_is_large[(LARGE_OFF_T % 2147483629 =3D=3D 721 && LARGE_OFF_T % 2147483647 =3D=3D 1) ? 1 : -1]; @@ -7460,8 +7448,13 @@ if test x"$pyconfig" =3D x"no"; then : else =20 CPPFLAGS=3D"$CFLAGS `$PYTHON-config --cflags`" - LDFLAGS=3D"$LDFLAGS `$PYTHON-config --ldflags`" - LIBS=3D"$LIBS `$PYTHON-config --libs`" + python_devel_embed=3D"" + if $PYTHON-config --embed >/dev/null 2>/dev/null; then + python_devel_embed=3D"--embed" + fi + LDFLAGS=3D"$LDFLAGS `$PYTHON-config --ldflags $python_devel_embed`" + LIBS=3D"$LIBS `$PYTHON-config --libs $python_devel_embed`" + unset python_devel_embed =20 fi =20 --=20 Anthony PERARD _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel