./configure --prefix=/Users/douglasdommermuth/mpich2/mpich2-install --with-device=ch3:nemesis |& tee c.txt
As a result, I was able to install mpich.
Thank you, Doug.
On Mar 1, 2024, at 11:37 PM, Zhou, Hui <zhouh@anl.gov> wrote:
I don't know what is causing the error, but here are a few work arounds:
You may try configure with--with-device=ch3. It uses an older device that is in maintenance mode, but likely it will work for you.- Try install libfabric separately and configure mpich with
--with-libfabric=prefix You may trybrew install libfabric orbrew install mpich.
--
Hui
From: Douglas G Dommermuth via discuss <discuss@mpich.org>
Sent: Friday, March 1, 2024 6:09 PM
To: discuss@mpich.org <discuss@mpich.org>
Cc: Douglas G Dommermuth <dgd@mit.edu>
Subject: [mpich-discuss] Install errors on MAC OS Sonoma: "error: expected declaration specifiers or ‘...’ before string constant"This Message Is From an External SenderThis message came from outside your organization.I am compiling mpich 4.2.0 on a MacBook Air Apple M1 running macOS Sonoma 14.3.1. I am using gcc and gfortran versions 13.2.0. I get the following errors when I build MPICH:
/Applications/Xcode.app/Contents/Developer/usr/bin/make all-amdepbase=`echo util/info.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\gcc -DHAVE_CONFIG_H -I. -I./include -D_GNU_SOURCE -D__USE_XOPEN2K8 -DSYSCONFDIR=\"/Users/douglasdommermuth/mpich2/mpich2-install/etc\" -DRDMADIR=\"@rdmadir@\" -DPROVDLDIR=\"/Users/douglasdommermuth/mpich2/mpich2-install/lib/libfabric\" -I./prov/sockets/include -I./prov/sockets -Wall -O2 -DNDEBUG -MT util/info.o -MD -MP -MF $depbase.Tpo -c -o util/info.o util/info.c &&\mv -f $depbase.Tpo $depbase.PoIn file included from ./include/osx/osd.h:182,from ./include/ofi_osd.h:60,from util/info.c:38:/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/os/lock.h:114:33: error: expected declaration specifiers or ‘...’ before string constant114 | OS_SWIFT_UNAVAILABLE_FROM_ASYNC("Use OSAllocatedUnfairLock.performWhileLocked() for async-safe scoped locking")| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/os/lock.h:140:33: error: expected declaration specifiers or ‘...’ before string constant140 | OS_SWIFT_UNAVAILABLE_FROM_ASYNC("Use OSAllocatedUnfairLock.tryPerformWhileLocked() for async-safe scoped locking")| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/os/lock.h:154:33: error: expected declaration specifiers or ‘...’ before string constant154 | OS_SWIFT_UNAVAILABLE_FROM_ASYNC("Use OSAllocatedUnfairLock.performWhileLocked() for async-safe scoped locking")| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~./include/osx/osd.h: In function ‘pthread_spin_lock’:./include/osx/osd.h:194:9: warning: implicit declaration of function ‘os_unfair_lock_lock’ [-Wimplicit-function-declaration]194 | os_unfair_lock_lock(lock);| ^~~~~~~~~~~~~~~~~~~./include/osx/osd.h: In function ‘pthread_spin_unlock’:./include/osx/osd.h:200:9: warning: implicit declaration of function ‘os_unfair_lock_unlock’ [-Wimplicit-function-declaration]200 | os_unfair_lock_unlock(lock);| ^~~~~~~~~~~~~~~~~~~~~./include/osx/osd.h: In function ‘pthread_spin_trylock’:./include/osx/osd.h:206:16: warning: implicit declaration of function ‘os_unfair_lock_trylock’ [-Wimplicit-function-declaration]206 | return os_unfair_lock_trylock(lock) ? 0 : EBUSY;| ^~~~~~~~~~~~~~~~~~~~~~make[3]: *** [util/info.o] Error 1make[2]: *** [all] Error 2make[1]: *** [all-recursive] Error 1make: *** [all] Error 2It looks like errors in macOS’s command line tools. I don’t know how to circumvent the problem. Various text and log files are attached in mpich2.tar.gz. A copy of the lock.h code is also included in the zip file.
Thank you, Doug.