macos name both libs by arch

pull/88/head
Dan Ballard 5 months ago
parent b3bb69829a
commit 07b496fc48
  1. 11
      .drone.yml
  2. 10
      Makefile

@ -161,18 +161,15 @@ steps:
- name: build-macos-x64
commands:
- export PATH=$PATH:/usr/local/go/bin/
- make macos
- make libCwtch.x64.dylib
- name: build-macos-arm64
when:
event:
- push
#event:
# - push
status: [ success ]
commands:
- export PATH=$PATH:/usr/local/go/bin/
- ./switch-ffi.sh
- export VERSION=$(cat VERSION)
- export BUILDDATE=$(cat BUILDDATE)
- env GOARCH=arm64 GOOS=darwin CGO_ENABLED=1 go build -ldflags "-X main.buildVer=$VERSION -X main.buildDate=$BUILDDATE" -buildmode c-shared -o libCwtch.arm64.dylib
- make libCwtch.arm.dylib
- name: deploy-buildfiles
environment:
BUILDFILES_KEY:

@ -8,7 +8,7 @@ all: linux android windows
linux: libCwtch.so
macos: libCwtch.dylib
macos: libCwtch.x64.dylib libCwtch.arm.dylib
android: cwtch.aar
@ -18,9 +18,13 @@ libCwtch.so: lib.go
./switch-ffi.sh
go build -ldflags "-X main.buildVer=$(shell git describe --tags) -X main.buildDate=$(shell date +%G-%m-%d-%H-%M)" -buildmode c-shared -o libCwtch.so
libCwtch.dylib: lib.go
libCwtch.x64.dylib: lib.go
./switch-ffi.sh
go build -ldflags "-X main.buildVer=$(shell git describe --tags) -X main.buildDate=$(shell date +%G-%m-%d-%H-%M)" -buildmode c-shared -o libCwtch.dylib
go build -ldflags "-X main.buildVer=$(shell git describe --tags) -X main.buildDate=$(shell date +%G-%m-%d-%H-%M)" -buildmode c-shared -o libCwtch.x64.dylib
libCwtch.arm.dylib: lib.go
./switch-ffi.sh
env GOARCH=arm64 GOOS=darwin CGO_ENABLED=1 go build -ldflags "-X main.buildVer=$(shell git describe --tags) -X main.buildDate=$(shell date +%G-%m-%d-%H-%M)" -buildmode c-shared -o libCwtch.arm64.dylib
cwtch.aar: lib.go
./switch-gomobile.sh

Loading…
Cancel
Save