Jump to content

Modding:Installing SMAPI on Mac: Difference between revisions

From Stardew Valley Wiki
imported>Pathoschild
remove new 'StardewModdingAPI will damage your computer' section (the fix is now included in the SMAPI installer)
imported>Pathoschild
Line 27: Line 27:


==Troubleshooting==
==Troubleshooting==
===Error message: "Malware blocked and moved to trash"===
This means macOS blocked SMAPI because it isn't signed with a paid Apple code signing certificate.
SMAPI does not contain malware. The error is due to new security restrictions on macOS that we're investigating. All new builds are detected as malware, even if they're identical to previously working versions. Note that all files on Nexus are scanned by 65 different antiviruses; you can click the green checkmarks on [{{nexus mod|2400}}?tab=files SMAPI's Nexus download page] for the results.
Temporary workaround for affected players:
<ol>
<li>Install SMAPI 4.1.7 instead. From the [{{nexus mod|2400}}?tab=files Files tab on Nexus], look under 'Optional files' for a download.</li>
<li>From Spotlight, open the Terminal app.</li>
<li>Enter this command for the Steam version of the game:
<syntaxhighlight lang="sh">
codesign --force --sign - "Library/Application Support/Steam/steamapps/common/Stardew Valley/Contents/MacOS/StardewModdingAPI"
</syntaxhighlight>
Or this one for the GOG version:
<syntaxhighlight lang="sh">
codesign --force --sign - "/Applications/Stardew Valley.app/Contents/MacOS/StardewModdingAPI"
</syntaxhighlight>
</li>
<li>Make sure both commands output nothing. If they show an error message, resolve the error or [[Modding:Help|ask for help]].</p>
</li>
</ol>
(This only 'signs' SMAPI so it can be played, it does not disable security or antivirus checks.)
===Error message: "Operation not permitted: 'internal'"===
===Error message: "Operation not permitted: 'internal'"===
To fix that error:
To fix that error:

Revision as of 16:35, 7 December 2024

This page explains how to install SMAPI (the tool which lets you use mods) on macOS.

See instructions for: Android • Linux • Steam Deck • Windows.

Install

Quick note: As of version 4.0.0, SMAPI uses NET 6.0, which is supported on Mac 10.15 (Catalina) or later. These instructions will fail if you're on Mac 10.12 (Sierra), Mac 10.13 (High Sierra), or 10.14 (Mohave), in which case, see: Modding:Player Guide/Troubleshooting#SMAPI doesn't work with the compatibility branch

  1. Download the latest version of SMAPI (see a pictorial guide).
  2. Extract the .zip file somewhere (but not in your game folder!).
  3. Right-click install on Mac.command and choose open.
  4. Follow the on-screen instructions.¹

That's it! Just launch the game to play with mods. You don't need to change your Steam launch options. (That's only needed on Windows).

¹To install manually instead, see instructions in the installer's readme.

Update

Just install the new version; the installer will automatically clean up previous versions.

Uninstall

  1. Launch the installer again (see install steps).
  2. When prompted, choose the uninstall option.

Troubleshooting

Error message: "Malware blocked and moved to trash"

This means macOS blocked SMAPI because it isn't signed with a paid Apple code signing certificate.

SMAPI does not contain malware. The error is due to new security restrictions on macOS that we're investigating. All new builds are detected as malware, even if they're identical to previously working versions. Note that all files on Nexus are scanned by 65 different antiviruses; you can click the green checkmarks on SMAPI's Nexus download page for the results.

Temporary workaround for affected players:

  1. Install SMAPI 4.1.7 instead. From the Files tab on Nexus, look under 'Optional files' for a download.
  2. From Spotlight, open the Terminal app.
  3. Enter this command for the Steam version of the game:
    codesign --force --sign - "Library/Application Support/Steam/steamapps/common/Stardew Valley/Contents/MacOS/StardewModdingAPI"
    

    Or this one for the GOG version:

    codesign --force --sign - "/Applications/Stardew Valley.app/Contents/MacOS/StardewModdingAPI"
    
  4. Make sure both commands output nothing. If they show an error message, resolve the error or ask for help.

(This only 'signs' SMAPI so it can be played, it does not disable security or antivirus checks.)

Error message: "Operation not permitted: 'internal'"

To fix that error:

  1. Open System Preferences.
  2. Go to "Security and Privacy" and then the "Privacy" tab.
  3. Scroll down to "Full Disk Access".
  4. Click the lock button to make changes.
  5. Use the + button to add Terminal to the list of apps.
    • Try again to run install on MacOS.command.

Can't launch installer on Ventura

Common solutions:

  • Install iTerm and set it to be your default Terminal.
  • Or temporarily disable System Integrity Protection. This isn't a great solution because it leaves your computer vulnerable, and you absolutely shouldn't leave your computer in this state.

Other issues