The documentation does say Entries which cannot be determined are set to ''
so I guess we need a guard. Matt On Wed, Apr 5, 2023 at 5:04 PM Kaus, Boris <k...@uni-mainz.de> wrote: > That indeed seems to be the issue: > > sandbox:${WORKSPACE}/srcdir/petsc-3.18.0 # python3 > Python 3.9.7 (default, Nov 24 2021, 21:15:59) > [GCC 10.3.1 20211027] on linux > Type "help", "copyright", "credits" or "license" for more information. > >>> import platform > >>> platform.mac_ver() > ('', ('', '', ''), '') > >>> platform.mac_ver()[0].split('.') > [''] > >>> tuple([int(a) for a in platform.mac_ver()[0].split('.')]) > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > File "<stdin>", line 1, in <listcomp> > ValueError: invalid literal for int() with base 10: ‘' > > > On 5. Apr 2023, at 23:00, Satish Balay <ba...@mcs.anl.gov> wrote: > > Sorry, Was looking at the wrong place. > > v = tuple([int(a) for a in platform.mac_ver()[0].split('.')]) > > > Can you try: > > balay@ypro petsc % python3 > Python 3.9.6 (default, Mar 10 2023, 20:16:38) > [Clang 14.0.3 (clang-1403.0.22.14.1)] on darwin > Type "help", "copyright", "credits" or "license" for more information. > > import platform > platform.mac_ver() > > ('13.3', ('', '', ''), 'x86_64') > > platform.mac_ver()[0].split('.') > > ['13', '3'] > > tuple([int(a) for a in platform.mac_ver()[0].split('.')]) > > (13, 3) > > > > > Satish > > > > > On Wed, 5 Apr 2023, Kaus, Boris wrote: > > Don’t think so: > > sandbox:${WORKSPACE}/srcdir/petsc-3.18.0 # env > _=/usr/bin/env > VERBOSE=true > BUILD_LD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ld > OLDPWD=/workspace/srcdir/petsc-3.18.0 > host_libdir=/workspace/x86_64-linux-musl-cxx11/destdir/lib > nproc=8 > target=aarch64-apple-darwin20 > bindir=/workspace/destdir/bin > CC=cc > > READELF_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-readelf > host_bindir=/workspace/x86_64-linux-musl-cxx11/destdir/bin > > PATH=/opt/bin/aarch64-apple-darwin20-libgfortran5-cxx11-mpi+openmpi:/opt/aarch64-apple-darwin20/bin:/opt/bin/x86_64-linux-musl-cxx11:/opt/x86_64-linux-musl/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/workspace/x86_64-linux-musl-cxx11/destdir/bin:/workspace/destdir/bin > nbits=64 > BUILD_STRIP=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-strip > BUILD_OBJDUMP=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objdump > > CMAKE_TARGET_TOOLCHAIN=/opt/toolchains/aarch64-apple-darwin20-libgfortran5-cxx11-mpi+openmpi/target_aarch64-apple-darwin20.cmake > FC_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gfortran > FC=gfortran > SRC_NAME=PETSc > RANLIB_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ranlib > CC_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gcc > PS1=\[\]sandbox\[\]:\[\]${PWD//$WORKSPACE/$\{WORKSPACE\}}\[\] \$ > PKG_CONFIG_SYSROOT_DIR=/workspace/destdir > > LD_LIBRARY_PATH=/usr/lib/csl-musl-x86_64:/usr/local/lib64:/usr/local/lib:/usr/lib64:/usr/lib:/lib64:/lib:/workspace/x86_64-linux-musl-cxx11/destdir/lib:/opt/x86_64-linux-musl/x86_64-linux-musl/lib64:/opt/x86_64-linux-musl/x86_64-linux-musl/lib:/opt/aarch64-apple-darwin20/aarch64-apple-darwin20/lib:/opt/aarch64-apple-darwin20/lib:/workspace/destdir/lib64:/workspace/destdir/lib > HOSTOBJCOPY=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objcopy > HOSTOBJDUMP=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objdump > LIPO_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-lipo > HOSTSTRIP=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-strip > BUILD_OBJCOPY=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objcopy > ZERO_AR_DATE=1 > dlext=dylib > HIDDEN_PS1=\[\]sandbox\[\]:\[\]${PWD//$WORKSPACE/$\{WORKSPACE\}}\[\] \$ > CCACHE_COMPILERCHECK=content > AR_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ar > HOSTDSYMUTIL=dsymutil > SHLVL=1 > > OBJDUMP_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objdump > CXX_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-g++ > HOSTCXX=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-g++ > USER=kausb > BUILD_DSYMUTIL=dsymutil > CC_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gcc > > OBJCOPY_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objcopy > TERM=screen > LIPO_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-lipo > BUILD_LIPO=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-lipo > NM_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-nm > host_prefix=/workspace/x86_64-linux-musl-cxx11/destdir > FC_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gfortran > AR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ar > WORKSPACE=/workspace > STRIP_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-strip > HOSTRANLIB=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ranlib > RANLIB_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ranlib > DSYMUTIL_FOR_BUILD=dsymutil > HOSTAS=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-as > HOSTAR=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ar > BUILD_RANLIB=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ranlib > NM_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-nm > LD=/opt/bin/aarch64-apple-darwin20-libgfortran5-cxx11-mpi+openmpi/ld > HOSTLD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ld > bb_full_target=aarch64-apple-darwin20-libgfortran5-cxx11-mpi+openmpi > LLVM_TARGET=aarch64-apple-darwin20 > BUILD_READELF=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-readelf > CXX_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-g++ > libdir=/workspace/destdir/lib > > MESON_TARGET_TOOLCHAIN=/opt/toolchains/aarch64-apple-darwin20-libgfortran5-cxx11-mpi+openmpi/target_aarch64-apple-darwin20.meson > LLVM_HOST_TARGET=x86_64-linux-musl > STRIP_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-strip > AS_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-as > HISTFILE=/meta/.bash_history > HOME=/root > HOSTLIPO=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-lipo > includedir=/workspace/destdir/include > > MESON_HOST_TOOLCHAIN=/opt/toolchains/x86_64-linux-musl-cxx11/host_x86_64-linux-musl.meson > BUILD_FC=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gfortran > V=true > BUILD_CC=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gcc > HOSTCC=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gcc > AS_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-as > CXX=c++ > rust_target=aarch64-apple-darwin > rust_host=x86_64-unknown-linux-musl > HOSTFC=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-gfortran > exeext= > READELF_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-readelf > bb_target=aarch64-apple-darwin20 > SOURCE_DATE_EPOCH=0 > PWD=/workspace/srcdir/petsc-3.18.0 > MACOSX_DEPLOYMENT_TARGET=11.0 > proc_family=arm > BUILD_NM=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-nm > BUILD_CXX=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-g++ > LD_FOR_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ld > OBJDUMP_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objdump > OBJCOPY_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-objcopy > HOSTNM=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-nm > USE_CCACHE=false > BUILD_AR=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ar > BUILD_AS=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-as > prefix=/workspace/destdir > HOSTNAME=271f88c24b60 > CHARSET=UTF-8 > > PKG_CONFIG_PATH=/workspace/destdir/lib/pkgconfig:/workspace/destdir/lib64/pkgconfig:/workspace/destdir/share/pkgconfig > MACHTYPE=x86_64-linux-musl > HOSTREADELF=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-readelf > DSYMUTIL_BUILD=dsymutil > LD_BUILD=/opt/bin/x86_64-linux-musl-cxx11/x86_64-linux-musl-ld > host_includedir=/workspace/x86_64-linux-musl-cxx11/destdir/include > > CMAKE_HOST_TOOLCHAIN=/opt/toolchains/x86_64-linux-musl-cxx11/host_x86_64-linux-musl.cmake > SHELL=/bin/bash > > > On 5. Apr 2023, at 22:45, Satish Balay <ba...@mcs.anl.gov> wrote: > > Well this doesn't trigger the error for me. Do you have any env variables > set with unicode [non-ascii] chars? > > Satish > > --- > > balay@ypro petsc-3.19.0 % sw_vers > ProductName: macOS > ProductVersion: 13.3 > BuildVersion: 22E252 > balay@ypro petsc-3.19.0 % ./configure --with-mpi=0 > --prefix=/workspace/destdir/lib/petsc/double_real_Int32/ > > ============================================================================================= > Configuring PETSc to compile on your system > > ============================================================================================= > > ============================================================================================= > ***** WARNING ***** > You have a version of GNU make older than 4.0. It will work, but may not > support all the > parallel testing options. You can install the latest GNU make with your > package manager, > such as Brew or MacPorts, or use the --download-make option to get the > latest GNU make > > ============================================================================================= > Compilers: > C Compiler: gcc -fPIC -Wall -Wwrite-strings -Wno-unknown-pragmas > -fstack-protector -fno-stack-check -Qunused-arguments -fvisibility=hidden > -g3 -O0 > Version: Apple clang version 14.0.3 (clang-1403.0.22.14.1) > ... > ... > > > On Wed, 5 Apr 2023, Kaus, Boris wrote: > > It can be reproduced with this: > sandbox:${WORKSPACE}/srcdir/petsc-3.18.0 # ./configure > --prefix=/workspace/destdir/lib/petsc/double_real_Int32/ > > ******************************************************************************* > TypeError or ValueError possibly related to ERROR in COMMAND LINE > ARGUMENT while running ./configure > > ------------------------------------------------------------------------------- > invalid literal for int() with base 10: '' > > ******************************************************************************* > > > File "/workspace/srcdir/petsc-3.18.0/config/configure.py", line 457, in > petsc_configure > framework = > config.framework.Framework(['--configModules=PETSc.Configure','--optionsModule=config.compilerOptions']+sys.argv[1:], > loadArgDB = 0) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/framework.py", > line 101, in __init__ > self.createChildren() > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/framework.py", > line 338, in createChildren > self.getChild(moduleName) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/framework.py", > line 323, in getChild > config.setupDependencies(self) > File "/workspace/srcdir/petsc-3.18.0/config/PETSc/Configure.py", line 89, > in setupDependencies > self.registerPythonFile(utility,'config.utilities') > File "/workspace/srcdir/petsc-3.18.0/config/PETSc/Configure.py", line 49, > in registerPythonFile > utilityObj = > self.framework.require(directory+utilityName, self) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/framework.py", > line 343, in require > config = self.getChild(moduleName, keywordArgs) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/framework.py", > line 317, in getChild > config = type(self, *keywordArgs) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/utilities/macosFirewall.py", > line 12, in __init__ > self.isDarwin = config.setCompilers.Configure.isDarwin(self.log) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/setCompilers.py", > line 664, in isDarwin > if not isUname_value: config.setCompilers.Configure.isUname(log) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/setCompilers.py", > line 630, in isUname > v = tuple([int(a) for a in platform.mac_ver()[0].split('.')]) > File > "/workspace/srcdir/petsc-3.18.0/config/BuildSystem/config/setCompilers.py", > line 630, in <listcomp> > v = tuple([int(a) for a in platform.mac_ver()[0].split('.')]) > > > On 5. Apr 2023, at 22:32, Stefano Zampini <stefano.zamp...@gmail.com> > wrote: > > It seems there's some typo/error in the configure command that is being > executed. Can you post it here? > > Il giorno mer 5 apr 2023 alle ore 23:18 Kaus, Boris <k...@uni-mainz.de< > mailto:k...@uni-mainz.de <k...@uni-mainz.de>><mailto:k...@uni-mainz.de > <k...@uni-mainz.de>>> ha scritto: > Hi everyone, > > I’m trying to install precompiled binaries for PETSc 3.18.5 & 3.19.0 using > the BinaryBuilder cross-compilation: > https://github.com/JuliaPackaging/Yggdrasil/pull/6533, which mostly works > fine: https://buildkite.com/julialang/yggdrasil/builds/2093). > > Yet, on apple systems I receive a somewhat weird bug during the configure > step: > > [22:08:49] > ******************************************************************************* > [22:08:49] TypeError or ValueError possibly related to ERROR in > COMMAND LINE ARGUMENT while running ./configure > [22:08:49] > ------------------------------------------------------------------------------- > [22:08:49] invalid literal for int() with base 10: '' > [22:08:49] > ******************************************************************************* > [22:08:49] > [22:08:49] > [22:08:49] /workspace/srcdir/petsc-3.18.0/lib/petsc/conf/rules:860: > /workspace/srcdir/petsc-3.18.0//lib/petsc/conf/petscrules: No such file or > directory > [22:08:49] make[1]: *** No rule to make target > '/workspace/srcdir/petsc-3.18.0//lib/petsc/conf/petscrules'. Stop. > [22:08:49] /workspace/srcdir/petsc-3.18.0/lib/petsc/conf/rules:860: > /workspace/srcdir/petsc-3.18.0//lib/petsc/conf/petscrules: No such file or > directory > [22:08:49] make[1]: *** No rule to make target > '/workspace/srcdir/petsc-3.18.0//lib/petsc/conf/petscrules'. Stop. > [22:08:49] make: *** [GNUmakefile:17: > /workspace/srcdir/petsc-3.18.0//lib/petsc/conf/petscvariables] Error 2 > [22:08:49] make: *** Waiting for unfinished jobs.... > [22:08:49] make: *** [GNUmakefile:17: lib/petsc/conf/petscvariables] Error > 2 > > The log file is rather brief: > > sandbox:${WORKSPACE}/srcdir/petsc-3.18.0 # more configure.log > Executing: uname -s > stdout: Darwin > > It works fine for PETSc 3.16.5/3.17.5, and this first occurs in 3.18.0. > Is there something that changed between 3.17 & 3.18 that could cause this? > > The build system seems to use python3.9 (3.4+ as required) > > Thanks! > Boris > > > > > > > -- > Stefano > > > -- What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead. -- Norbert Wiener https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>