visit-dav / visit

VisIt - Visualization and Data Analysis for Mesh-based Scientific Data
https://visit.llnl.gov
BSD 3-Clause "New" or "Revised" License
440 stars 116 forks source link

incorrectly identified arch as "darwin-ppc" or "darwin-i386" on macOS arm64 #20022

Open BenWibking opened 1 week ago

BenWibking commented 1 week ago

Describe the bug

Issue 1. When packaging the Visit install on a macOS arm64 machine, build_visit labels the arch as darwin-ppc.

Issue 2. When running the launcher script $VISIT_INSTALL_DIR/bin/visit, it tries to load the binaries from a darwin-i386 subdirectory.

To Reproduce

Steps to reproduce the behavior. For example:

  1. Run ./build_visit on latest develop on a Mac
  2. See the directories and files created by the packaging script are labeled darwin-ppc.

Expected behavior

It should identify the arch as darwin-arm64 (or similar).

Attachments

Build log:

Desktop

Additional context

For issue 2, it looks like the problem is in internallauncher:

        elif self.os == "darwin":
            mach = self.uname("-m")
            release = self.uname("-r")
            version = [int(x) for x in release.split(".")]
            self.osver = version[0]
            if version[0] >= 11:
                if mach == "x86_64":
                    supportedarches.append("darwin-x86_64")
                    supportedarches.append("darwin-i386")
                else:
                    supportedarches.append("darwin-i386") # this line gets executed

The value of mach on this machine is arm64.

BenWibking commented 1 week ago

If internallauncher is updated to include a mach == "arm64" case, I think this issue should also get fixed: https://github.com/visit-dav/visit/issues/18867.

cyrush commented 1 week ago

@BenWibking thanks! We will try to resolve this during our release process for 3.4.2.