From 1f2a05e466c195dde83effd82c96d4329259d249 Mon Sep 17 00:00:00 2001 From: Nick White Date: Mon, 2 Aug 2021 17:28:03 +0100 Subject: rescribe: Add experimental m1 build --- cmd/rescribe/embed_darwin.go | 10 ---------- cmd/rescribe/embed_darwin_amd64.go | 10 ++++++++++ cmd/rescribe/embed_darwin_arm64.go | 10 ++++++++++ cmd/rescribe/getembeds.go | 1 + makefile | 3 +++ 5 files changed, 24 insertions(+), 10 deletions(-) delete mode 100644 cmd/rescribe/embed_darwin.go create mode 100644 cmd/rescribe/embed_darwin_amd64.go create mode 100644 cmd/rescribe/embed_darwin_arm64.go diff --git a/cmd/rescribe/embed_darwin.go b/cmd/rescribe/embed_darwin.go deleted file mode 100644 index 719c9cc..0000000 --- a/cmd/rescribe/embed_darwin.go +++ /dev/null @@ -1,10 +0,0 @@ -// Copyright 2021 Nick White. -// Use of this source code is governed by the GPLv3 -// license that can be found in the LICENSE file. - -package main - -import _ "embed" - -//go:embed tesseract-osx-v4.1.1.20191227.zip -var tesszip []byte diff --git a/cmd/rescribe/embed_darwin_amd64.go b/cmd/rescribe/embed_darwin_amd64.go new file mode 100644 index 0000000..719c9cc --- /dev/null +++ b/cmd/rescribe/embed_darwin_amd64.go @@ -0,0 +1,10 @@ +// Copyright 2021 Nick White. +// Use of this source code is governed by the GPLv3 +// license that can be found in the LICENSE file. + +package main + +import _ "embed" + +//go:embed tesseract-osx-v4.1.1.20191227.zip +var tesszip []byte diff --git a/cmd/rescribe/embed_darwin_arm64.go b/cmd/rescribe/embed_darwin_arm64.go new file mode 100644 index 0000000..a1ca9b8 --- /dev/null +++ b/cmd/rescribe/embed_darwin_arm64.go @@ -0,0 +1,10 @@ +// Copyright 2021 Nick White. +// Use of this source code is governed by the GPLv3 +// license that can be found in the LICENSE file. + +package main + +import _ "embed" + +//go:embed tesseract-osx-m1-v4.1.1.20210802.zip +var tesszip []byte diff --git a/cmd/rescribe/getembeds.go b/cmd/rescribe/getembeds.go index 1747d82..de000a8 100644 --- a/cmd/rescribe/getembeds.go +++ b/cmd/rescribe/getembeds.go @@ -44,6 +44,7 @@ func main() { "https://rescribe.xyz/rescribe/embeds/tessdata.20210622.zip", "https://rescribe.xyz/rescribe/embeds/tesseract-linux-v5.0.0-alpha.20210510.zip", "https://rescribe.xyz/rescribe/embeds/tesseract-osx-v4.1.1.20191227.zip", + "https://rescribe.xyz/rescribe/embeds/tesseract-osx-m1-v4.1.1.20210802.zip", "https://rescribe.xyz/rescribe/embeds/tesseract-w32-v5.0.0-alpha.20210506.zip", } for _, v := range urls { diff --git a/makefile b/makefile index 6ba1af5..d831938 100644 --- a/makefile +++ b/makefile @@ -8,5 +8,8 @@ default: rescribe-osx: GOOS=darwin GOARCH=amd64 go build -o $@ ./cmd/rescribe +rescribe-osx-m1: + GOOS=darwin GOARCH=arm64 go build -o $@ ./cmd/rescribe + rescribe.exe: GOOS=windows GOARCH=386 go build -o $@ ./cmd/rescribe -- cgit v1.2.1-24-ge1ad