Install Failure on M1 Mac

Hi AFNI team,

I am trying to install AFNI on an M1 Macbook Air. I followed all of the instructions here: https://afni.nimh.nih.gov/pub/dist/doc/htmldoc/background_install/install_instructs/steps_macOS_12_Silicon.html. Here is the terminal output from the final step:

(base) ian@Ians-MacBook-Air-2 ~ % tcsh OS_notes.macos_12_ARM_b_user.tcsh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 3324 100 3324 0 0 12928 0 --:--:-- --:--:-- --:--:-- 13035
set os = uname -s
uname -s
if ( 0 ) then
if ( Darwin != Darwin ) then
set cpu = uname -m
uname -m
if ( 0 ) then
set rver = R --version | head -n 1 | cut -d ' ' -f 3
R --version
cut -d -f 3
head -n 1
if ( 0 ) then
echo OS : Darwin
OS : Darwin
echo CPU : arm64
CPU : arm64
echo R ver : 4.3.1
R ver : 4.3.1
echo

defaults write org.macosforge.xquartz.X11 wm_ffm -bool true
defaults write org.x.X11 wm_ffm -bool true
defaults write com.apple.Terminal FocusFollowsMouse -string YES
curl -O https://afni.nimh.nih.gov/pub/dist/bin/misc/@update.afni.binaries
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 50203 100 50203 0 0 107k 0 --:--:-- --:--:-- --:--:-- 107k
tcsh @update.afni.binaries -no_recur -package anyos_text_atlas -bindir /Users/ian/abin
-- running @update.afni.binaries version 3.22, May 5, 2023
-- no current AFNI package found in path...
-- any downloads will be from https://afni.nimh.nih.gov via curl -O -f

-- attempting to install package anyos_text_atlas under
install dir: /Users/ian/abin...
-- have install dir
++ working in new temp dir, .tmp.install
-- skipping update of @update.afni.binaries
++ downloading test file: curl -O -f anyos_text_atlas/AFNI_version.txt ...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 42 100 42 0 0 139 0 --:--:-- --:--:-- --:--:-- 140

++ update needed, installing...

++ downloading full package: curl -O -f anyos_text_atlas.tgz ...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 89.9M 100 89.9M 0 0 8340k 0 0:00:11 0:00:11 --:--:-- 8526k
++ extracting package anyos_text_atlas.tgz...
++ syncing new binaries...
done, yay (binaries are under /Users/ian/abin)
/Users/ian/abin/init_user_dotfiles.py -shell_list bash zsh tcsh -do_updates path apsearch -dir_bin /Users/ian/abin
-- no .cshrc, will create one as a follower of .tcshrc
-- considered operations: path, apsearch

-- note: followers should not need edits, so edit flags should be 0
(have 1 follower(s), which can be ignored)

dot file mods : want 6 modifications across 4 files:

file path flatdir apsearch follower


.bashrc 1 0 1 0
.zshrc 1 0 1 0
.cshrc 0 0 0 1
.tcshrc 1 0 1 0

-- file .bashrc does not yet exist to back up
-- updated dot file .bashrc
-- backing up .zshrc to .zshrc.adot.bak
-- updated dot file .zshrc
-- file .cshrc does not yet exist to back up
-- updated dot file .cshrc
-- backing up .tcshrc to .tcshrc.adot.bak
-- updated dot file .tcshrc
source ~/.cshrc
source /Users/ian/.tcshrc
if ( -f /Users/ian/anaconda3/etc/profile.d/conda.csh ) then
source /Users/ian/anaconda3/etc/profile.d/conda.csh
setenv CONDA_EXE /Users/ian/anaconda3/bin/conda
setenv _CONDA_ROOT /Users/ian/anaconda3
setenv _CONDA_EXE /Users/ian/anaconda3/bin/conda
setenv CONDA_PYTHON_EXE /Users/ian/anaconda3/bin/python
if ( ! 1 ) then
if ( /Users/ian/anaconda3/bin/conda == ) then
endif
if ( alias conda == ) then
alias conda
if ( 1 ) then
set _CONDA_PFX=dirname "${_CONDA_EXE}"
dirname /Users/ian/anaconda3/bin/conda
set _CONDA_PFX=dirname "${_CONDA_PFX}"
dirname /Users/ian/anaconda3/bin
alias conda source /Users/ian/anaconda3/etc/profile.d/conda.csh
unset _CONDA_PFX
else
setenv CONDA_SHLVL 0
if ( ! 0 ) then
set prompt=
endif
else
else
setenv PATH /Users/ian/anaconda3/bin:/Users/ian/anaconda3/condabin:/opt/homebrew/bin:/opt/homebrew/sbin:/Library/Frameworks/Python.framework/Versions/3.11/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/opt/python/libexec/bin:/usr/local/opt/python/libexec/bin:/Users/ian/abin
if ( 1 ) then
if ( != ) then
endif
if ( arm64 == x86_64 ) then
set package = macos_13_ARM_clang
endif
build_afni.py -build_root /Users/ian/afni_build -package macos_13_ARM_clang

-- current AFNI: AFNI_23.2.12, anyos_text, Sep 29 2023
-- preparing build_root dir, /Users/ian/afni_build
-- creating build_root dir, /Users/ian/afni_build
-- running 'git clone' on afni repo ...
(please be patient)
-- have default git tag LAST_TAG, will checkout AFNI_23.2.12
-- checking out git tag AFNI_23.2.12
-- using repo branch (detached), tag AFNI_23.2.12
-- downloading AFNI atlas package, afni_atlases_dist.tgz
-- unpacking atlas package, afni_atlases_dist
-- downloading NiiVue, niivue_afni.umd.js

-- preparing to run 'make' build of package macos_13_ARM_clang
-- copying other_builds/Makefile.macos_13_ARM_clang to Makefile
-- building make target 'itall'
++ building ...
consider monitoring the build in a separate window with:
cd /Users/ian
tail -f /Users/ian/afni_build/build_src/log_make.txt
# use ctrl-c to terminate 'tail' command (not the build)
** error: failed run_cmd: make AFNI_WHOMADEIT=build itall >& log_make.txt
** error:
-- status: building FAILURE
see 'make' log file /Users/ian/afni_build/build_src/log_make.txt

-- shell/system command history is in:
/Users/ian/afni_build/hist_commands.txt

++ screen text history is in:
/Users/ian/afni_build/hist_messages.txt

rsync -av /Users/ian/afni_build/build_src/macos_13_ARM_clang/ /Users/ian/abin/
building file list ... rsync: link_stat "/Users/ian/afni_build/build_src/macos_13_ARM_clang/." failed: No such file or directory (2)
done

sent 29 bytes received 20 bytes 98.00 bytes/sec
total size is 0 speedup is 0.00
rsync error: some files could not be transferred (code 23) at /AppleInternal/Library/BuildRoots/d9889869-120b-11ee-b796-7a03568b17ac/Library/Caches/com.apple.xbs/Sources/rsync/rsync/main.c(996) [sender=2.6.9]

I can also send the 'make' log file but it seems too big to post here.

Sincerely,
Ian

Hi Ian,

Would you please send me a private message, and try to attach the log_make.txt file to it?

Thanks,

  • rick

Hello Rickr,
I am probably dealing with exactly the same error of the last installing step. Could you please help me as well? Thank you very much.

Hi Anna,

Would you mind sending me the output of:

afni_system_check.py -check_all

You can post that here or send as a private message (click on my name).

It seems that most issues here were with installing homebrew, based on a version of the commands that had a mistake (I listed the Intel path to brew, not realizing it was different from the ARM path). Maybe you are in that camp.

What is the output from: brew --version

I would show that in the system_check output, if you would like to send that.

Thanks,

  • rick

Thank you very much for your quick response!
I can't see the private message option in my account so I'm posting the output od afni check here. My homebrew version is 4.1.13.

architecture: 64bit
cpu type: arm
system: Darwin
release: 22.6.0
version: Darwin Kernel Version 22.6.0: Wed Jul 5 22:22:52 PDT 2023; root:xnu-8796.141.3~6/RELEASE_ARM64_T8103
distribution: 13.5.2
number of CPUs: 8
apparent login shell: zsh
shell RC file: .zshrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni :
:
AFNI_version.txt : AFNI_23.2.12, anyos_text, Sep 29 2023, local
which python : /Users/anna/fsl/bin/python
python version : 3.11.5
which R : /usr/local/bin/R
R version : R version 4.3.1 (aarch64-apple-darwin20)

instances of various programs found in PATH:
afni : 0
R : 1 (/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/bin/R)
python : 1 (/Users/anna/fsl/bin/python3.11)
python2 : 0
python3 : 2
/Users/anna/fsl/bin/python3.11
/usr/bin/python3

** have python3 but not python2

testing ability to start various programs...
afni : FAILURE
/bin/sh: afni: command not found
suma : FAILURE
/bin/sh: suma: command not found
3dSkullStrip : FAILURE
/bin/sh: 3dSkullStrip: command not found
3dAllineate : FAILURE
/bin/sh: 3dAllineate: command not found
3dRSFC : FAILURE
/bin/sh: 3dRSFC: command not found
SurfMesh : FAILURE
/bin/sh: SurfMesh: command not found
3dClustSim : FAILURE
/bin/sh: 3dClustSim: command not found
uber_subject.py : success
3dMVM : FAILURE
setenv: Too many arguments.

------------------------ dependent program tests -------------------------
checking for dependent programs...

which tcsh : /bin/tcsh
which Xvfb : /opt/X11/bin/Xvfb

checking for R packages...
rPkgsInstall -pkgs ALL -check : FAILURE
setenv: Too many arguments.

R RHOME : /Library/Frameworks/R.framework/Resources

------------------------------ python libs -------------------------------

++ module loaded: matplotlib.pyplot
module file : /Users/anna/fsl/lib/python3.11/site-packages/matplotlib/pyplot.py
matplotlib version : 3.7.2

-------------------------------- env vars --------------------------------
PATH = /usr/local/art/bin:/Applications/freesurfer/7.4.1/bin:/Applications/freesurfer/7.4.1/fsfast/bin:/Users/anna/fsl/bin:/Users/anna/fsl/share/fsl/bin:/Applications/freesurfer/7.4.1/mni/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/opt/local/bin:/opt/local/sbin:/Users/anna/fsl/share/fsl/bin:/Users/anna/fsl/share/fsl/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/Users/anna/abin:/opt/homebrew/opt/python/libexec/bin:/Users/anna/abin/

PYTHONPATH =
R_LIBS =
LD_LIBRARY_PATH =
DYLD_LIBRARY_PATH (sub-shell) = /Applications/freesurfer/7.4.1/lib/gcc/lib
DYLD_FALLBACK_LIBRARY_PATH (sub-shell) =

----------------------------- eval dot files -----------------------------

----------- AFNI $HOME files -----------

.afnirc                   : found
.sumarc                   : found
.afni/help/all_progs.COMP : found

--------- shell startup files ----------

** warning: .tcshrc does NOT seem to contain 'source .cshrc'
-- (csh and tcsh will use different files)
-- considered operations: path, flatdir, apsearch

-- note: followers should not need edits, so edit flags should be 0
(have 0 follower(s), which can be ignored)

dot file test : want 2 modifications across 3 files:

  file             path  flatdir  apsearch        follower
  ---------------  ----  -------  --------        --------
  .cshrc           0     0        0               0     
  .tcshrc          0     1        0               0     
  .zshrc           0     1        0               0     

------------------------------ data checks -------------------------------
data dir : missing AFNI_data6
data dir : missing AFNI_demos
data dir : missing suma_demo
data dir : missing afni_handouts
atlas : did not find TT_N27+tlrc

------------------------------ OS specific -------------------------------
XQuartz version : 2.8.5

which brew : /opt/homebrew/bin/brew
brew version : Homebrew 4.1.13
which port : /opt/local/bin/port
port version : Version: 2.8.1

++ found 1 dylib files under '/opt/X11/lib/flat_namespace'
-- found 'libXt' dylib files:
/opt/X11/lib/flat_namespace/libXt.6.dylib
-- recent OS X, cheating to check DYLD_LIBRARY_PATH in cur shell 'zsh'...
** env var DYLD_LIBRARY_PATH is set, but without /opt/X11/lib/flat_namespace
-- recent OS X, cheating to check DYLD_LIBRARY_PATH in shell 'tcsh'...
** env var DYLD_LIBRARY_PATH not set to contain /opt/X11/lib/flat_namespace

========================= summary, please fix: =========================

  • just be aware: login shell 'zsh', but our code examples use 'tcsh'
  • missing program: afni
  • failure under initial "AFNI and related program tests"
  • AFNI programs show FAILURE
  • missing R packages (see rPkgsInstall)
  • dot file test : want 2 modifications across 3 files:
  • insufficient data for AFNI bootcamp
    (see "Prepare for Bootcamp" on install pages)
  • possibly missing atlases
  • consider installing gcc under homebrew
  • consider installing glib under homebrew
  • please set DYLD_LIBRARY_PATH to include /opt/X11/lib/flat_namespace
  • please set DYLD_LIBRARY_PATH to /opt/X11/lib/flat_namespace in tcsh

Hi Anna,

You seem to have a more complex setup, with homebrew, macports and fsl.
Would you please run a build and let me know how it goes?

build_afni.py -build_root $HOME/afni_build -package macos_13_ARM_clang

Thanks,

  • rick

Hi Rick! I might also have run into the same probelm. and the chech output shown below.

afni_system_check.py -check_all
-------------------------------- general ---------------------------------
architecture:         64bit
cpu type:             i386
system:               Darwin
release:              23.0.0
version:              Darwin Kernel Version 23.0.0: Fri Sep 15 14:42:42 PDT 2023; root:xnu-10002.1.13~1/RELEASE_X86_64
distribution:         14.0
number of CPUs:       12
apparent login shell: zsh
shell RC file:        .zshrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni           :
                     :
AFNI_version.txt     : AFNI_23.3.00, anyos_text, Oct 11 2023, local
which python         : /Users/xingyuliu/fsl/bin/python
python version       : 3.11.4
which R              : /usr/local/bin/R
R version            : R version 4.3.1 (x86_64-apple-darwin20)

instances of various programs found in PATH:
    afni    : 0
    R       : 1   (/Library/Frameworks/R.framework/Versions/4.3-x86_64/Resources/bin/R)
    python  : 3
      /Users/xingyuliu/fsl/bin/python3.11
      /usr/local/anaconda3/bin/python3.11
      /usr/local/Cellar/python@3.11/3.11.6/Frameworks/Python.framework/Versions/3.11/bin/python3.11
    python2 : 0
    python3 : 4
      /Users/xingyuliu/fsl/bin/python3.11
      /usr/local/anaconda3/bin/python3.11
      /usr/local/Cellar/python@3.11/3.11.6/Frameworks/Python.framework/Versions/3.11/bin/python3.11
      /usr/bin/python3

** have python3 but not python2

testing ability to start various programs...
    afni                 : FAILURE
        /bin/sh: afni: command not found
    suma                 : FAILURE
        /bin/sh: suma: command not found
    3dSkullStrip         : FAILURE
        /bin/sh: 3dSkullStrip: command not found
    3dAllineate          : FAILURE
        /bin/sh: 3dAllineate: command not found
    3dRSFC               : FAILURE
        /bin/sh: 3dRSFC: command not found
    SurfMesh             : FAILURE
        /bin/sh: SurfMesh: command not found
    3dClustSim           : FAILURE
        /bin/sh: 3dClustSim: command not found
    uber_subject.py      : success
    3dMVM                : FAILURE
        setenv: Too many arguments.

------------------------ dependent program tests -------------------------
checking for dependent programs...

which tcsh           : /bin/tcsh
which Xvfb           : /opt/X11/bin/Xvfb

checking for R packages...
    rPkgsInstall -pkgs ALL -check : FAILURE
        setenv: Too many arguments.

R RHOME : /Library/Frameworks/R.framework/Resources

------------------------------ python libs -------------------------------

++ module loaded: matplotlib.pyplot
   module file : /Users/xingyuliu/fsl/lib/python3.11/site-packages/matplotlib/pyplot.py
   matplotlib version : 3.8.0

-- python binaries under /usr/local/bin:
    /usr/local/bin/python3 (sym link to /usr/local/Cellar/python@3.11/3.11.6/Frameworks/Python.framework/Versions/3.11/bin/python3.11)

-------------------------------- env vars --------------------------------
PATH = /Applications/freesurfer/7.4.1/bin:/Applications/freesurfer/7.4.1/fsfast/bin:/Users/xingyuliu/fsl/bin:/Users/xingyuliu/fsl/share/fsl/bin:/Applications/freesurfer/7.4.1/mni/bin:/usr/local/anaconda3/bin:/usr/local/anaconda3/condabin:/Users/xingyuliu/bin:/usr/local/bin:/usr/local/bin:/usr/local/sbin:/Users/xingyuliu/fsl/share/fsl/bin:/Users/xingyuliu/fsl/share/fsl/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/X11/bin:/Library/Apple/usr/bin:/Applications/freesurfer/7.4.1/bin:/Applications/workbench/bin_macosx64:/usr/local/opt/python/libexec/bin:/Users/xingyuliu/abin

PYTHONPATH =
R_LIBS = /Users/xingyuliu/sw/R-4.3.1

LD_LIBRARY_PATH =
DYLD_LIBRARY_PATH (sub-shell) = /Applications/freesurfer/7.4.1/lib/gcc/lib
DYLD_FALLBACK_LIBRARY_PATH (sub-shell) =

----------------------------- eval dot files -----------------------------

----------- AFNI $HOME files -----------

    .afnirc                   : missing
    .sumarc                   : missing
    .afni/help/all_progs.COMP : missing

--------- shell startup files ----------

   -- good: .tcshrc seems to contain 'source .cshrc'
   -- considered operations: path, flatdir, apsearch

   -- note: followers should not need edits, so edit flags should be 0
      (have 1 follower(s), which can be ignored)

   dot file test : want 2 modifications across 3 files:

      file             path  flatdir  apsearch        follower
      ---------------  ----  -------  --------        --------
      .cshrc           0     1        0               0
      .tcshrc          0     0        0               1
      .zshrc           0     1        0               0

------------------------------ data checks -------------------------------
data dir : missing AFNI_data6
data dir : missing AFNI_demos
data dir : missing suma_demo
data dir : missing afni_handouts
atlas    : did not find TT_N27+tlrc

------------------------------ OS specific -------------------------------
XQuartz version      : 2.8.5

which brew           : /usr/local/bin/brew
brew version         : Homebrew 4.1.15

** consider linking /usr/local/Cellar/gcc/13.2.0/lib/gcc/current/libgomp.1.dylib under /usr/local/lib
++ found valid link /usr/local/lib/libglib-2.0.dylib
   to ../Cellar/glib/2.78.0/lib/libglib-2.0.dylib

=========================  summary, please fix:  =========================
*  just be aware: login shell 'zsh', but our code examples use 'tcsh'
*  missing program: afni
*  failure under initial "AFNI and related program tests"
*  AFNI programs show FAILURE
*  missing R packages (see rPkgsInstall)
*  please run: cp /Users/xingyuliu/abin/AFNI.afnirc ~/.afnirc
*  please run: "suma -update_env" for .sumarc
*  please run: apsearch -update_all_afni_help
*  dot file test : want 2 modifications across 3 files:
*  insufficient data for AFNI bootcamp
   (see "Prepare for Bootcamp" on install pages)
*  possibly missing atlases
*  consider linking /usr/local/Cellar/gcc/13.2.0/lib/gcc/current/libgomp.1.dylib under /usr/local/lib

Thank you so much for the help.
Best,
Xingyu

Hi Xingyu,

This seems a little questionable. Your system actually shows up not as an ARM mac, but as a 32-bit Intel one. Yet your R package is 64-bit (Intel), maybe some translating is going on there.

Can you verify, what is the output from

grep '^SYSTEM_NAME' ~/afni_build/build_src/Makefile

Thanks,

  • rick

Sorry for that! I did accidentally hit to built as ARM while troubleshooting. To correct this, I reran the build script (tcsh OS_notes.macos_12_intel_b_user.tcsh), SYSTEM_NAME = macos_12_x86_64.
The error was still there.

++ building (please be patient)...
** error: failed run_cmd: make AFNI_WHOMADEIT=build itall >& log_make.txt
-- status: building FAILURE
   see 'make' log file /Users/xingyuliu/afni_build/build_src/log_make.txt
** error: tail from log_make.txt:
   --------------------------------------------------
   make[1]: Entering directory '/Users/xingyuliu/afni_build/build_src'
   clang -arch x86_64 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I. -I/usr/local/include -I/opt/X11/include -I/usr/local/include/netpbm -I/usr/include -Icoxplot -Inifti/nifti2 -Inifti/niftilib -Inifti/nifticdf -Inifti/znzlib -I3DEdge/src -Irickr -Ileej3 -DHAVE_ZLIB -DHAVE_GIFTI -If2c -m64 -Wcomment -Wformat -DUSE_TRACING -DHAVE_XDBE -DDONT_USE_MCW_MALLOC  -I/opt/R/x86_64/include    -fPIC  -falign-functions=64 -Wall -g -O2  -c R_io.c -o R_io.o
   In file included from R_io.c:1:
   /Library/Frameworks/R.framework/Resources/include/R.h:43:11: fatal error: 'stdlib.h' file not found
   # include <stdlib.h> /* Not used by R itself, but widely assumed in packages */
   ^~~~~~~~~~
   1 error generated.
   make[1]: *** [/Library/Frameworks/R.framework/Resources/etc/Makeconf:191: R_io.o] Error 1
   make[1]: Leaving directory '/Users/xingyuliu/afni_build/build_src'
   make: *** [Makefile.INCLUDE:4213: R_io.so] Error 1
   --------------------------------------------------

This time the ckeck all output shows

-------------------------------- general ---------------------------------
architecture:         64bit
cpu type:             i386
system:               Darwin
release:              23.0.0
version:              Darwin Kernel Version 23.0.0: Fri Sep 15 14:42:42 PDT 2023; root:xnu-10002.1.13~1/RELEASE_X86_64
distribution:         14.0
number of CPUs:       12
apparent login shell: zsh
shell RC file:        .zshrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni           :
                     :
AFNI_version.txt     : AFNI_23.3.01, anyos_text, Oct 12 2023, local
which python         : /Users/xingyuliu/fsl/bin/python
python version       : 3.11.4
which R              : /usr/local/bin/R
R version            : R version 4.3.1 (x86_64-apple-darwin20)

instances of various programs found in PATH:
    afni    : 0
    R       : 1   (/Library/Frameworks/R.framework/Versions/4.3-x86_64/Resources/bin/R)
    python  : 3
      /Users/xingyuliu/fsl/bin/python3.11
      /usr/local/anaconda3/bin/python3.11
      /usr/local/Cellar/python@3.11/3.11.6/Frameworks/Python.framework/Versions/3.11/bin/python3.11
    python2 : 0
    python3 : 4
      /Users/xingyuliu/fsl/bin/python3.11
      /usr/local/anaconda3/bin/python3.11
      /usr/local/Cellar/python@3.11/3.11.6/Frameworks/Python.framework/Versions/3.11/bin/python3.11
      /usr/bin/python3

** have python3 but not python2

testing ability to start various programs...
    afni                 : FAILURE
        /bin/sh: afni: command not found
    suma                 : FAILURE
        /bin/sh: suma: command not found
    3dSkullStrip         : FAILURE
        /bin/sh: 3dSkullStrip: command not found
    3dAllineate          : FAILURE
        /bin/sh: 3dAllineate: command not found
    3dRSFC               : FAILURE
        /bin/sh: 3dRSFC: command not found
    SurfMesh             : FAILURE
        /bin/sh: SurfMesh: command not found
    3dClustSim           : FAILURE
        /bin/sh: 3dClustSim: command not found
    uber_subject.py      : success
    3dMVM                : FAILURE
        setenv: Too many arguments.

------------------------ dependent program tests -------------------------
checking for dependent programs...

which tcsh           : /bin/tcsh
which Xvfb           : /opt/X11/bin/Xvfb

checking for R packages...
    rPkgsInstall -pkgs ALL -check : FAILURE
        setenv: Too many arguments.

R RHOME : /Library/Frameworks/R.framework/Resources

------------------------------ python libs -------------------------------

++ module loaded: matplotlib.pyplot
   module file : /Users/xingyuliu/fsl/lib/python3.11/site-packages/matplotlib/pyplot.py
   matplotlib version : 3.8.0

-- python binaries under /usr/local/bin:
    /usr/local/bin/python3 (sym link to /usr/local/Cellar/python@3.11/3.11.6/Frameworks/Python.framework/Versions/3.11/bin/python3.11)

-------------------------------- env vars --------------------------------
PATH = /Applications/freesurfer/7.4.1/bin:/Applications/freesurfer/7.4.1/fsfast/bin:/Users/xingyuliu/fsl/bin:/Users/xingyuliu/fsl/share/fsl/bin:/Applications/freesurfer/7.4.1/mni/bin:/usr/local/anaconda3/bin:/usr/local/anaconda3/condabin:/Users/xingyuliu/bin:/usr/local/bin:/usr/local/bin:/usr/local/sbin:/Users/xingyuliu/fsl/share/fsl/bin:/Users/xingyuliu/fsl/share/fsl/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/X11/bin:/Library/Apple/usr/bin:/Applications/freesurfer/7.4.1/bin:/Applications/workbench/bin_macosx64:/usr/local/opt/python/libexec/bin:/Users/xingyuliu/abin

PYTHONPATH =
R_LIBS = /Users/xingyuliu/sw/R-4.3.1

LD_LIBRARY_PATH =
DYLD_LIBRARY_PATH (sub-shell) = /Applications/freesurfer/7.4.1/lib/gcc/lib
DYLD_FALLBACK_LIBRARY_PATH (sub-shell) =

----------------------------- eval dot files -----------------------------

----------- AFNI $HOME files -----------

    .afnirc                   : missing
    .sumarc                   : missing
    .afni/help/all_progs.COMP : missing

--------- shell startup files ----------

   -- good: .tcshrc seems to contain 'source .cshrc'
   -- considered operations: path, apsearch

   -- note: followers should not need edits, so edit flags should be 0
      (have 1 follower(s), which can be ignored)

   no modifications needed across 3 dot files

------------------------------ data checks -------------------------------
data dir : missing AFNI_data6
data dir : missing AFNI_demos
data dir : missing suma_demo
data dir : missing afni_handouts
atlas    : did not find TT_N27+tlrc

------------------------------ OS specific -------------------------------
XQuartz version      : 2.8.5

which brew           : /usr/local/bin/brew
brew version         : Homebrew 4.1.15

** consider linking /usr/local/Cellar/gcc/13.2.0/lib/gcc/current/libgomp.1.dylib under /usr/local/lib
++ found valid link /usr/local/lib/libglib-2.0.dylib
   to ../Cellar/glib/2.78.0/lib/libglib-2.0.dylib

=========================  summary, please fix:  =========================
*  just be aware: login shell 'zsh', but our code examples use 'tcsh'
*  missing program: afni
*  failure under initial "AFNI and related program tests"
*  AFNI programs show FAILURE
*  missing R packages (see rPkgsInstall)
*  please run: cp /Users/xingyuliu/abin/AFNI.afnirc ~/.afnirc
*  please run: "suma -update_env" for .sumarc
*  please run: apsearch -update_all_afni_help
*  insufficient data for AFNI bootcamp
   (see "Prepare for Bootcamp" on install pages)
*  possibly missing atlases
*  consider linking /usr/local/Cellar/gcc/13.2.0/lib/gcc/current/libgomp.1.dylib under /usr/local/lib

Thank you very much!
Xingyu

Thank you for your answer Rick.
"Glad" to hear about my complex setup :slight_smile:
When I run a build it returns me an error message
build_afni.py -build_root $HOME/afni_build -package macos_13_ARM_clang

-- current AFNI: AFNI_23.2.12, anyos_text, Sep 29 2023
-- cleaning old build root dir, /Users/anna/afni_build
-- preparing build_root dir, /Users/anna/afni_build
-- have default git tag LAST_TAG, will checkout AFNI_23.3.01
-- checking out git tag AFNI_23.3.01
-- using repo branch (detached), tag AFNI_23.3.01
-- will reuse existing atlas directory, afni_atlases_dist
-- removing old NiiVue backup, prev.niivue_afni.umd.js
-- moving old niivue niivue_afni.umd.js to prev.niivue_afni.umd.js
-- downloading NiiVue, niivue_afni.umd.js

-- preparing to run 'make' build of package macos_13_ARM_clang
-- copying other_builds/Makefile.macos_13_ARM_clang to Makefile
-- building make target 'itall'
++ building ...
consider monitoring the build in a separate window with:
cd /Users/anna/Downloads
tail -f /Users/anna/afni_build/build_src/log_make.txt
# use ctrl-c to terminate 'tail' command (not the build)
** error: failed run_cmd: make AFNI_WHOMADEIT=build itall >& log_make.txt
** error:
-- status: building FAILURE
see 'make' log file /Users/anna/afni_build/build_src/log_make.txt

-- shell/system command history is in:
/Users/anna/afni_build/hist_commands.txt

++ screen text history is in:
/Users/anna/afni_build/hist_messages.txt

I will be really glad for any advice!

Hi Anna,

Thanks for the log file. It looks like openmp is missing. Would you please run the brew install commands again, to be sure everything is there?

brew install libpng jpeg expat freetype fontconfig openmotif  \
             libomp gsl glib pkg-config gcc libiconv autoconf \
             libxt mesa mesa-glu libxpm

There are also netpbm, xquartz and such. But since you have xquartz, let's start with this.
Install these packages and then please give the build another try:

build_afni.py -build_root $HOME/afni_build -package macos_13_ARM_clang

Hopefully that will work, but if not, please send an updated log_make.txt file.

Thanks,

  • rick

Hi Rick,

I might be having the same issue as others in this thread, the installation got stuck at the following step:

Installation error
tcsh OS_notes.macos_12_ARM_b_user.tcsh
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5083  100  5083    0     0  12684      0 --:--:-- --:--:-- --:--:-- 12675
set os = `uname -s`
uname -s
if ( 0 ) then
if ( Darwin != Darwin ) then
set cpu = `uname -m`
uname -m
if ( 0 ) then
set rver = `R --version | head -n 1 | cut -d ' ' -f 3`
R --version
cut -d   -f 3
head -n 1
if ( 0 ) then
echo OS    : Darwin
OS    : Darwin
echo CPU   : arm64
CPU   : arm64
echo R ver : 4.3.1
R ver : 4.3.1
echo 

defaults write org.macosforge.xquartz.X11 wm_ffm -bool true
defaults write org.x.X11 wm_ffm -bool true
defaults write com.apple.Terminal FocusFollowsMouse -string YES
if ( ! -f /Users/ramotlab/abin/init_user_dotfiles.py ) then
echo ++ installing AFNI anyos_text_atlas
++ installing AFNI anyos_text_atlas
curl -O https://afni.nimh.nih.gov/pub/dist/bin/misc/@update.afni.binaries
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 60026  100 60026    0     0  83219      0 --:--:-- --:--:-- --:--:-- 83138
tcsh @update.afni.binaries -no_recur -package anyos_text_atlas -bindir /Users/ramotlab/abin
-- running @update.afni.binaries version 3.27, February 4, 2025
-- no current AFNI package found in path...
-- any downloads will be from https://afni.nimh.nih.gov via curl -O -f

-- attempting to install package anyos_text_atlas under
   install dir: /Users/ramotlab/abin...
++ creating install dir
/Users/ramotlab/abin

++ working in new temp dir, .tmp.install
-- skipping update of @update.afni.binaries
++ downloading test file: curl -O -f anyos_text_atlas/AFNI_version.txt ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100    48  100    48    0     0    108      0 --:--:-- --:--:-- --:--:--   108

++ update needed, installing...

++ downloading full package: curl -O -f anyos_text_atlas.tgz ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 65.9M  100 65.9M    0     0  14.5M      0  0:00:04  0:00:04 --:--:-- 15.1M
++ extracting package anyos_text_atlas.tgz...
-- nothing to back up or sync
++ installing new binaries...
done, yay (binaries are under /Users/ramotlab/abin)
else
echo ++ setting up user dotfiles
++ setting up user dotfiles
/Users/ramotlab/abin/init_user_dotfiles.py -shell_list bash zsh tcsh -do_updates path apsearch -dir_bin /Users/ramotlab/abin
-- good: .tcshrc seems to contain 'source .cshrc'
-- considered operations: path, apsearch

-- note: followers should not need edits, so edit flags should be 0
   (have 1 follower(s), which can be ignored)

dot file mods : want 3 modifications across 4 files:

   file             path  flatdir  apsearch        follower
   ---------------  ----  -------  --------        --------
   .bashrc          1     0        0               0     
   .zshrc           1     0        1               0     
   .cshrc           0     0        0               0     
   .tcshrc          0     0        0               1     

-- backing up .bashrc to .bashrc.adot.bak
-- updated dot file .bashrc
-- backing up .zshrc to .zshrc.adot.bak
-- updated dot file .zshrc
which init_user_dotfiles.py
/Users/ramotlab/abin/init_user_dotfiles.py
if ( 0 ) then
if ( arm64 == x86_64 ) then
set package = macos_13_ARM
endif
echo ++ compiling AFNI package macos_13_ARM
++ compiling AFNI package macos_13_ARM
echo ++ running: build_afni.py -build_root ~/afni_build -package macos_13_ARM
++ running: build_afni.py -build_root ~/afni_build -package macos_13_ARM
build_afni.py -build_root /Users/ramotlab/afni_build -package macos_13_ARM

-- build_afni.py, version 0.14, November 17, 2024
-- current AFNI: AFNI_25.0.07, anyos_text_atlas, Feb 25 2025
-- preparing build_root dir, /Users/ramotlab/afni_build
-- creating build_root dir, /Users/ramotlab/afni_build
-- running 'git clone' on afni repo ...
   (please be patient)
-- have default git tag LAST_TAG, will checkout AFNI_25.0.07
-- checking out git tag AFNI_25.0.07
-- using repo branch (detached), tag AFNI_25.0.07
-- downloading AFNI atlas package, afni_atlases_dist.tgz
-- unpacking atlas package, afni_atlases_dist
-- downloading NiiVue, niivue_afni.umd.js

-- preparing to run 'make' build of package macos_13_ARM
-- copying README files
-- copying Makefile.macos_13_ARM to Makefile
-- building make target 'itall'

-- consider monitoring the build in a separate window with:
       cd /Users/ramotlab
       tail -f /Users/ramotlab/afni_build/build_src/log_make.txt
       # use ctrl-c to terminate 'tail' command (not the build)
++ building (please be patient)...
** error: failed run_cmd: make AFNI_WHOMADEIT=build itall >& log_make.txt
-- status: building FAILURE
   see 'make' log file /Users/ramotlab/afni_build/build_src/log_make.txt
** error: tail from log_make.txt:
   --------------------------------------------------
   |                  ^~~~~~~~~~~
   (cd leej3; \
   /opt/homebrew/bin/gcc-14 -arch arm64 -DDARWIN -DARM_M1 -O1 -m64 -Wall -Wno-deprecated-declarations -Wcomment -Wformat -DUSE_TRACING -DHAVE_XDBE -DDONT_USE_MCW_MALLOC  -c whats_my_exepath.c; \
   /bin/cp -f whats_my_exepath.o ..; \
   cd ..)
   /bin/rm -f afni
   /opt/homebrew/bin/gcc-14 -arch arm64 -DDARWIN -DARM_M1 -O1 -m64 -Wall -Wno-deprecated-declarations -Wcomment -Wformat -DUSE_TRACING -DHAVE_XDBE -DDONT_USE_MCW_MALLOC  -DWHATS_MY_EXEPATH -o afni afni.o afni_func.o afni_widg.o afni_warp.o afni_fimmer.o afni_slice_short.o afni_slice_float.o afni_filer.o afni_slice_byte.o  afni_slice_complex.o afni_pcor.o afni_pcor_float.o afni_transforms.o pbar.o afni_graph.o afni_plugin.o afni_cluster.o parser.o parser_int.o afni_plugout.o afni_fimfunc.o afni_setup.o afni_receive.o mcw_graf.o afni_splash.o afni_pplug_env.o afni_pplug_2dfunc.o afni_friends.o afni_ttren.o afni_pplug_1dfunc.o afni_driver.o afni_niml.o afni_sumafunc.o afni_slice_rgbyte.o afni_version.o afni_lock.o afni_vol2surf.o afni_pplug_instacorr.o afni_pplug_instacalc.o afni_pplug_tstat.o afni_whelp.o whats_my_exepath.o  -m64 -dynamic -L. -L/opt/homebrew/lib -L/opt/X11/lib -L/usr/lib  -lmrix -lcoxplot -lmri  libXmHTML.a libjpeg.a -lmri -lf2c -lXm -ljpeg -lXt -lXft -lfontconfig -lpng16 -liconv -lXmu -lXp -lXpm -lXext -lX11 -lz -lexpat  -lm -lc -lm -lc
   ld: file not found: libjpeg.a
   collect2: error: ld returned 1 exit status
   make: *** [afni] Error 1
   --------------------------------------------------

** warning: in conda environment
   CONDA_SHLVL = 0, CONDA_DEFAULT_ENV = base

-- shell/system command history is in:
      /Users/ramotlab/afni_build/hist_commands.txt

++ screen text history is in:
      /Users/ramotlab/afni_build/hist_messages.txt

rehash
if ( ! 1 ) then
echo -- already have R_LIBS=/Users/ramotlab/sw/R-4.3.1
-- already have R_LIBS=/Users/ramotlab/sw/R-4.3.1
endif
if ( ! -d /Users/ramotlab/sw/R-4.3.1/data.table ) then
echo -- already have directory /Users/ramotlab/sw/R-4.3.1
-- already have directory /Users/ramotlab/sw/R-4.3.1
endif
if ( -f /opt/X11/bin/Xvfb ) then
which Xvfb
if ( 0 ) then
echo -- already have Xvfb in PATH
-- already have Xvfb in PATH
endif
else
if ( ! -f ~/.afnirc ) then
echo ++ running:  cp ~/abin/AFNI.afnirc ~/.afnirc
++ running:  cp ~/abin/AFNI.afnirc ~/.afnirc
cp /Users/ramotlab/abin/AFNI.afnirc /Users/ramotlab/.afnirc
endif
if ( ! -f ~/.sumarc ) then
if ( ! -f ~/.afni/help/all_progs.COMP ) then
echo ++ running: apsearch -update_all_afni_help
++ running: apsearch -update_all_afni_help
apsearch -update_all_afni_help
apsearch: Command not found.

When I run afni_system_check.py -check_all in zsh where I did all the previous installation steps, I get zsh: command not found: afni_system_check.py which is somewhat confusing, but in bash it gives me this:

afni_system_check.py in bash
bash-3.2$ afni_system_check.py -check_all
-------------------------------- general ---------------------------------
architecture:         64bit 
cpu type:             x86_64
system:               Darwin
release:              24.3.0
version:              Darwin Kernel Version 24.3.0: Thu Jan  2 20:24:16 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T6000
distribution:         10.16 (sw_vers 15.3.1)
number of CPUs:       20
user:                 ramotlab
apparent login shell: zsh  (current shell is bash)
shell RC file:        .bashrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni           :
                     : 
AFNI_version.txt     : AFNI_25.0.07, anyos_text_atlas, Feb 25 2025, local
which python         : /opt/anaconda3/bin/python
python version       : 3.11.7
which R              : /usr/local/bin/R
R version            : R version 4.3.1 (aarch64-apple-darwin20)

instances of various programs found in PATH:
    afni    : 0 
    R       : 1   (/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/bin/R)
    python  : 2 
      /opt/anaconda3/bin/python3.11
      /opt/homebrew/Cellar/python@3.13/3.13.2/Frameworks/Python.framework/Versions/3.13/bin/python3.13
    python2 : 0 
    python3 : 3 
      /opt/homebrew/Cellar/python@3.13/3.13.2/Frameworks/Python.framework/Versions/3.13/bin/python3.13
      /opt/anaconda3/bin/python3.11
      /usr/bin/python3

testing ability to start various programs...
    afni                 : FAILURE
        /bin/sh: afni: command not found
    suma                 : FAILURE
        /bin/sh: suma: command not found
    3dSkullStrip         : FAILURE
        /bin/sh: 3dSkullStrip: command not found
    3dAllineate          : FAILURE
        /bin/sh: 3dAllineate: command not found
    3dRSFC               : FAILURE
        /bin/sh: 3dRSFC: command not found
    SurfMesh             : FAILURE
        /bin/sh: SurfMesh: command not found
    3dClustSim           : FAILURE
        /bin/sh: 3dClustSim: command not found
    build_afni.py        : success
    uber_subject.py      : success
    3dMVM                : FAILURE
        
    rPkgsInstall         : FAILURE
        

------------------------ dependent program tests -------------------------
checking for dependent programs...

which tcsh           : /bin/tcsh
tcsh version         : 6.21.00
which Xvfb           : /opt/X11/bin/Xvfb

checking for R packages...
    rPkgsInstall -pkgs ALL -check : FAILURE
        

R RHOME : /Library/Frameworks/R.framework/Resources

------------------------------ python libs -------------------------------

++ module loaded: matplotlib.pyplot
   module file : /opt/anaconda3/lib/python3.11/site-packages/matplotlib/pyplot.py
   matplotlib version : 3.8.0

++ module loaded: flask
   module file : /opt/anaconda3/lib/python3.11/site-packages/flask/__init__.py
   flask version : 3.0.3

++ module loaded: flask_cors
   module file : /opt/anaconda3/lib/python3.11/site-packages/flask_cors/__init__.py
   flask_cors version : 3.0.10

-------------------------------- env vars --------------------------------
PATH                       = /opt/homebrew/bin:/opt/homebrew/sbin:/opt/anaconda3/bin:/opt/anaconda3/condabin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/X11/bin:/opt/homebrew/opt/python/libexec/bin:/Library/Frameworks/R.framework/Resources:/usr/local/gfortran/bin:/usr/local/opt/python/libexec/bin:/opt/homebrew/opt/python/libexec/bin:/opt/homebrew/opt/python/libexec/bin:/opt/homebrew/opt/python/libexec/bin:/Users/ramotlab/abin

PYTHONPATH (sub-shell) = 
R_LIBS                     = /Users/ramotlab/sw/R-4.3.1
LD_LIBRARY_PATH (sub-shell) = 
DYLD_LIBRARY_PATH (sub-shell) = 
DYLD_FALLBACK_LIBRARY_PATH (sub-shell) = 
CONDA_SHLVL                = 1
CONDA_DEFAULT_ENV          = base
CC (sub-shell) = 

----------------------------- eval dot files -----------------------------

----------- AFNI $HOME files -----------

    .afnirc                   : found
    .sumarc                   : found
    .afni/help/all_progs.COMP : missing

--------- shell startup files ----------

   -- good: .tcshrc seems to contain 'source .cshrc'
   -- considered operations: path, apsearch
   
   -- note: followers should not need edits, so edit flags should be 0
      (have 1 follower(s), which can be ignored)
   
   no modifications needed across 4 dot files
   
------------------------------ data checks -------------------------------
data dir : missing AFNI_data6
data dir : missing AFNI_demos
data dir : missing suma_demo
data dir : missing afni_handouts
atlas    : did not find TT_N27+tlrc

------------------------------ OS specific -------------------------------
** failed to parse X version string, '(null)'
  ** for macos install instructions, see:

    https://afni.nimh.nih.gov/pub/dist/doc/htmldoc/background_install/install_instructs/steps_mac.html

XQuartz version      : (null)

which brew           : /opt/homebrew/bin/brew
brew version         : Homebrew 4.4.22

which git            : /usr/bin/git
git version          : git version 2.39.5 (Apple Git-154)
which gcc            : /usr/bin/gcc
gcc version          : Apple clang version 16.0.0 (clang-1600.0.26.6)

** found no gcc-* under /usr/local/bin
brew gcc(s)          : 
CommandLineTools SDK : MacOSX15.2.sdk

=========================  summary, please fix:  =========================
*  just be aware: login shell 'zsh', but our code examples use 'tcsh'
*  missing program: afni
*  failure under initial "AFNI and related program tests"
*  AFNI programs show FAILURE
*  missing R packages (see rPkgsInstall)
*  please run: apsearch -update_all_afni_help
*  insufficient data for AFNI bootcamp
   (see "Prepare for Bootcamp" on install pages)
*  possibly missing atlases
*  strange XQuartz version: (null)
*  consider installing gcc under homebrew
*  consider installing glib under homebrew

For completeness, brew --version gives Homebrew 4.4.22.

I'd be happy for any advice regarding the installation.

Thanks,
Jan

Hi Jan,

It is probably in your home abin. What is the output from this?

~/abin/afni_system_check.py -check_all

Thanks,

-rick

Hi Rick,

Thank you for your swift reply. The output of that is the same as I sent before:

~/abin/afni_system_check.py -check_all
-------------------------------- general ---------------------------------
architecture:         64bit 
cpu type:             x86_64
system:               Darwin
release:              24.3.0
version:              Darwin Kernel Version 24.3.0: Thu Jan  2 20:24:16 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T6000
distribution:         10.16 (sw_vers 15.3.1)
number of CPUs:       20
user:                 ramotlab
apparent login shell: zsh
shell RC file:        .zshrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni           :
                     : 
AFNI_version.txt     : AFNI_25.0.07, anyos_text_atlas, Feb 25 2025, local
which python         : /opt/anaconda3/bin/python
python version       : 3.11.7
which R              : /usr/local/bin/R
R version            : R version 4.3.1 (aarch64-apple-darwin20)

instances of various programs found in PATH:
    afni    : 0 
    R       : 1   (/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/bin/R)
    python  : 2 
      /opt/anaconda3/bin/python3.11
      /opt/homebrew/Cellar/python@3.13/3.13.2/Frameworks/Python.framework/Versions/3.13/bin/python3.13
    python2 : 0 
    python3 : 3 
      /opt/anaconda3/bin/python3.11
      /opt/homebrew/Cellar/python@3.13/3.13.2/Frameworks/Python.framework/Versions/3.13/bin/python3.13
      /usr/bin/python3

testing ability to start various programs...
    afni                 : FAILURE
        /bin/sh: afni: command not found
    suma                 : FAILURE
        /bin/sh: suma: command not found
    3dSkullStrip         : FAILURE
        /bin/sh: 3dSkullStrip: command not found
    3dAllineate          : FAILURE
        /bin/sh: 3dAllineate: command not found
    3dRSFC               : FAILURE
        /bin/sh: 3dRSFC: command not found
    SurfMesh             : FAILURE
        /bin/sh: SurfMesh: command not found
    3dClustSim           : FAILURE
        /bin/sh: 3dClustSim: command not found
    build_afni.py        : FAILURE
        /bin/sh: build_afni.py: command not found
    uber_subject.py      : FAILURE
        /bin/sh: uber_subject.py: command not found
    3dMVM                : FAILURE
        /bin/sh: 3dMVM: command not found
    rPkgsInstall         : FAILURE
        /bin/sh: rPkgsInstall: command not found

have failures, testing programs under implied /Users/ramotlab/abin...
    afni                 : FAILURE
        /bin/sh: /Users/ramotlab/abin/afni: No such file or directory
    suma                 : FAILURE
        /bin/sh: /Users/ramotlab/abin/suma: No such file or directory
    3dSkullStrip         : FAILURE
        /bin/sh: /Users/ramotlab/abin/3dSkullStrip: No such file or directory
    3dAllineate          : FAILURE
        /bin/sh: /Users/ramotlab/abin/3dAllineate: No such file or directory
    3dRSFC               : FAILURE
        /bin/sh: /Users/ramotlab/abin/3dRSFC: No such file or directory
    SurfMesh             : FAILURE
        /bin/sh: /Users/ramotlab/abin/SurfMesh: No such file or directory
    3dClustSim           : FAILURE
        /bin/sh: /Users/ramotlab/abin/3dClustSim: No such file or directory
    build_afni.py        : success
    uber_subject.py      : success
    3dMVM                : success
    rPkgsInstall         : success

------------------------ dependent program tests -------------------------
checking for dependent programs...

which tcsh           : /bin/tcsh
tcsh version         : 6.21.00
which Xvfb           : /opt/X11/bin/Xvfb

checking for R packages...
    rPkgsInstall -pkgs ALL -check : FAILURE
        /bin/sh: rPkgsInstall: command not found

R RHOME : /Library/Frameworks/R.framework/Resources

------------------------------ python libs -------------------------------

++ module loaded: matplotlib.pyplot
   module file : /opt/anaconda3/lib/python3.11/site-packages/matplotlib/pyplot.py
   matplotlib version : 3.8.0

++ module loaded: flask
   module file : /opt/anaconda3/lib/python3.11/site-packages/flask/__init__.py
   flask version : 3.0.3

++ module loaded: flask_cors
   module file : /opt/anaconda3/lib/python3.11/site-packages/flask_cors/__init__.py
   flask_cors version : 3.0.10

-------------------------------- env vars --------------------------------
PATH                       = /opt/anaconda3/bin:/opt/anaconda3/condabin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/X11/bin:/opt/homebrew/bin:/opt/homebrew/opt/python/libexec/bin:/Library/Frameworks/R.framework/Resources:/usr/local/gfortran/bin:/usr/local/opt/python/libexec/bin:/opt/homebrew/opt/python/libexec/bin:/opt/homebrew/opt/python/libexec/bin:/opt/homebrew/opt/python/libexec/bin

PYTHONPATH (sub-shell) = 
R_LIBS                     = /Users/ramotlab/sw/R-4.3.1
LD_LIBRARY_PATH (sub-shell) = 
DYLD_LIBRARY_PATH (sub-shell) = 
DYLD_FALLBACK_LIBRARY_PATH (sub-shell) = 
CONDA_SHLVL                = 1
CONDA_DEFAULT_ENV          = base
CC (sub-shell) = 

----------------------------- eval dot files -----------------------------

----------- AFNI $HOME files -----------

    .afnirc                   : found
    .sumarc                   : found
    .afni/help/all_progs.COMP : missing

--------- shell startup files ----------

   init_user_dotfiles.py: Command not found.
------------------------------ data checks -------------------------------
data dir : missing AFNI_data6
data dir : missing AFNI_demos
data dir : missing suma_demo
data dir : missing afni_handouts
atlas    : did not find TT_N27+tlrc

------------------------------ OS specific -------------------------------
** failed to parse X version string, '(null)'
  ** for macos install instructions, see:

    https://afni.nimh.nih.gov/pub/dist/doc/htmldoc/background_install/install_instructs/steps_mac.html

XQuartz version      : (null)

which brew           : /opt/homebrew/bin/brew
brew version         : Homebrew 4.4.22

which git            : /usr/bin/git
git version          : git version 2.39.5 (Apple Git-154)
which gcc            : /usr/bin/gcc
gcc version          : Apple clang version 16.0.0 (clang-1600.0.26.6)

** found no gcc-* under /usr/local/bin
brew gcc(s)          : 
CommandLineTools SDK : MacOSX15.2.sdk

=========================  summary, please fix:  =========================
*  just be aware: login shell 'zsh', but our code examples use 'tcsh'
*  missing program: afni
*  failure under initial "AFNI and related program tests"
*  AFNI programs show FAILURE
*  consider adding /Users/ramotlab/abin to your PATH
*  missing R packages (see rPkgsInstall)
*  please run: apsearch -update_all_afni_help
*  failure running init_user_dotfiles.py -test
*  insufficient data for AFNI bootcamp
   (see "Prepare for Bootcamp" on install pages)
*  possibly missing atlases
*  strange XQuartz version: (null)
*  consider installing gcc under homebrew
*  consider installing glib under homebrew

Thanks,
Jan

Hi Jan,

Sorry, I did not initially notice those arrows to open and close parts of your reply.

There are 3 aspects of the ASC output that are a bit odd. It shows your CPU as x86_64, even though the OS and other bits show ARM. There is no detected XQuartz version, and there is no detected gcc (though this is probably because of the first point). To be sure, what is the output from

uname -m

But that is probably not relevant to the build problem. To be sure, do you have any security updates waiting to go in, notably anything from CommandLineTools?

It seems likely that I will want to see your complete build output, so I will send you a private message about that.

Thanks,

-rick

1 Like

I found this link that showed that if you choose an old Intel-based bash shell, then you could have the wrong architecture identified.

https://apple.stackexchange.com/questions/458124/after-moving-to-apple-silicon-terminal-arch-is-still-i386