Skip to content

Commit

Permalink
Fix Mac Build
Browse files Browse the repository at this point in the history
  • Loading branch information
JustinTimperio committed Dec 31, 2024
1 parent 91d81c4 commit 7a48bd0
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 6 deletions.
19 changes: 18 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,32 @@ jobs:

- name: Build
run: |
## Install Dependencies
sudo apt update -y
sudo apt install -y docker golang git
sudo apt install -y docker golang git zip gzip tar
go install github.com/fyne-io/fyne-cross@latest
## Check out the macos SDK from git
git clone -n --depth=1 --filter=tree:0 https://github.com/alexey-lysiuk/macos-sdk.git
cd macos-sdk
git sparse-checkout set --no-cone /MacOSX12.3.sdk
git checkout
cd ..
## Build the App
~/go/bin/fyne-cross linux -arch=amd64,arm64 -app-id="OnionSoup"
~/go/bin/fyne-cross windows -arch=amd64,arm64 -app-id="Onion.Soup"
~/go/bin/fyne-cross darwin -arch=amd64,arm64 -app-id="Onion.Soup" --macosx-sdk-path /home/runner/work/onionsoup/onionsoup/macos-sdk/MacOSX12.3.sdk
## Pack Up Each Release
mv fyne-cross/dist/linux-amd64/onionsoup.tar.xz fyne-cross/onionsoup_linux_amd64.tar.xz
mv fyne-cross/dist/linux-arm64/onionsoup.tar.xz fyne-cross/onionsoup_linux_arm64.tar.xz
mv fyne-cross/dist/windows-amd64/onionsoup.exe.zip fyne-cross/onionsoup_windows_amd64.exe.zip
mv fyne-cross/dist/windows-arm64/onionsoup.exe.zip fyne-cross/onionsoup_windows_arm64.exe.zip
tar -czf onionsoup_mac_amd64.tar.gz -C fyne-cross/dist/darwin-amd64/onionsoup.app onionsoup.app
tar -czf onionsoup_mac_arm64.tar.gz -C fyne-cross/dist/darwin-arm64/onionsoup.app onionsoup.app
mv onionsoup_mac_amd64.tar.gz fyne-cross/onionsoup_mac_amd64.tar.gz
mv onionsoup_mac_arm64.tar.gz fyne-cross/onionsoup_mac_arm64.tar.gz
- name: Release
uses: softprops/action-gh-release@v2
Expand All @@ -41,4 +56,6 @@ jobs:
fyne-cross/onionsoup_linux_arm64.tar.xz
fyne-cross/onionsoup_windows_amd64.exe.zip
fyne-cross/onionsoup_windows_arm64.exe.zip
fyne-cross/onionsoup_mac_amd64.tar.gz
fyne-cross/onionsoup_mac_arm64.tar.gz
token: ${{ secrets.GH_TOKEN }}
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,13 @@ This example highlights how 2 parties (Alice and Bob), can bootstrap a conversat

### Windows
1. Download the prebuilt `exe.zip` from the Release page and extract it.
2. Download and install the tor expert bundle from [here](https://www.torproject.org/download/tor/) and start the daemon service with `c:\Tor\tor.exe –-service install`
3. Open OnionSoup!
2. Download and extract the tor expert bundle from [here](https://www.torproject.org/download/tor/)
3. Add the path of the extracted `tor` exe to your `path` variable in the `Environment Variables` menu.
4. Open OnionSoup!

### Mac
*Mac Builds are currently not working, please see [this issue](https://github.com/JustinTimperio/onionsoup/issues/1)*
1. Download the prebuilt `tar.gz` from the Release page and extract it to your Applications folder.
2. Open OnionSoup!

## Building from Source

Expand All @@ -60,9 +62,8 @@ To bundle the assets into the program run:
```

### Mac
*Mac Builds are currently not working, please see [this issue](https://github.com/JustinTimperio/onionsoup/issues/1)*
```bash
~/go/bin/fyne-cross darwin -arch=amd64,arm64 -app-id="Onion.Soup" --macosx-sdk-path /full-path/macos-sdk/MacOSX15.2.sdk
~/go/bin/fyne-cross darwin -app-id="Onion.Soup" --macosx-sdk-path /path/to/macos-sdk/MacOSX12.3.sdk
```


Expand Down
1 change: 1 addition & 0 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ func NewRouteHandler() (*RouteHandler, error) {

t, err := tor.Start(nil, &tor.StartConf{
DataDir: path.Join(os.TempDir(), "tor", randomString(10)),
RetainTempDataDir: false,
})
if err != nil {
return nil, err
Expand Down

0 comments on commit 7a48bd0

Please sign in to comment.