Skip to content

Commit cfd3a3c

Browse files
committed
test-gather-topology.sh: Disable test when cross-compiling
In case one uses binfmt to be able to run the cross-built library & programs, the content of /proc/cpuinfo is supposed to be the guest cpu content, while cat will have gotten the host cpu content. Actually at the moment qemu erroneously gives the host cpu content, see https://gitlab.com/qemu-project/qemu/-/issues/2004 but once that will get fixed, cross-compiled gather-topology testing will fail (as expected), so disable it in that case. Refs #638
1 parent 2c16044 commit cfd3a3c

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

config/hwloc.m4

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
dnl -*- Autoconf -*-
22
dnl
33
dnl Copyright © 2009-2023 Inria. All rights reserved.
4-
dnl Copyright © 2009-2012, 2015-2017, 2020 Université Bordeaux
4+
dnl Copyright © 2009-2012, 2015-2017, 2020, 2023 Université Bordeaux
55
dnl Copyright © 2004-2005 The Trustees of Indiana University and Indiana
66
dnl University Research and Technology
77
dnl Corporation. All rights reserved.
@@ -1849,6 +1849,7 @@ AC_DEFUN([HWLOC_DO_AM_CONDITIONALS],[
18491849
AM_CONDITIONAL([HWLOC_XML_LIBXML_BUILD_STATIC], [test "x$hwloc_xml_libxml_component" = "xstatic"])
18501850
18511851
AM_CONDITIONAL([HWLOC_HAVE_CXX], [test "x$hwloc_have_cxx" = "xyes"])
1852+
AM_CONDITIONAL([HWLOC_CROSS_COMPILING], [test "x$cross_compiling" = "xyes"])
18521853
])
18531854
hwloc_did_am_conditionals=yes
18541855
])dnl

tests/hwloc/linux/gather/Makefile.am

+2
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@
22
# Copyright © 2010 Cisco Systems, Inc. All rights reserved.
33
# See COPYING in top-level directory.
44

5+
if !HWLOC_CROSS_COMPILING
56
if HWLOC_HAVE_LINUX
67
if HWLOC_HAVE_OPENAT
78
if HWLOC_HAVE_BUNZIPP
89
TESTS = test-gather-topology.sh
910
endif HWLOC_HAVE_BUNZIPP
1011
endif HWLOC_HAVE_OPENAT
1112
endif HWLOC_HAVE_LINUX
13+
endif !HWLOC_CROSS_COMPILING

0 commit comments

Comments
 (0)