0

I'm learning about how to use gRPC with GOLANG on a Macbook Pro/ macOS Big Sur / 11.6.8, using the instructions on the Protocol Buffer Compiler Installation page, where it instructs the reader to use curl to download the protoc compiler archive, and unzip to expand the archive. I'm executing the following command sequence:

curl -LO https://github.com/protocolbuffers/protobuf/releases/protoc-21.4-osx-universal_binary.zip
unzip protoc-21.4-osx-universal_binary.zip -d /Users/rodrigosilveira/.local

The unzip execution fails, with the following message:

Archive:  protoc-21.4-osx-universal_binary.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of protoc-21.4-osx-universal_binary.zip or
        protoc-21.4-osx-universal_binary.zip.zip, and cannot find protoc-21.4-osx-universal_binary.zip.ZIP, period.

DEBUG NOTES:

Unzip works without using curl

  • visit the Protocol Buffers v21.4 page
  • double click the protoc-21.4-osx-universal_binary.zip file,
  • unzip to expand the protoc-21.4-osx-universal_binary.zip archive in my local Downloads folder

Existing SO answers do not help

Rodrigo Silveira
  • 141
  • 2
  • 15
  • 1
    unzip is complaining because you haven't downloaded the zip file at all. See https://stackoverflow.com/questions/25923939/how-do-i-download-binary-files-of-a-github-release for details of downloading github assets – pmqs Aug 08 '22 at 17:43
  • Ouch, a total debugging blindspot on my part, thanks. – Rodrigo Silveira Aug 08 '22 at 23:57

1 Answers1

1

The current URL for this utility is

https://github.com/protocolbuffers/protobuf/releases/download/v21.5/protoc-21.5-osx-universal_binary.zip

The previous one return "Not found" and this is the reason you get this zip error

Romeo Ninov
  • 6,538
  • 1
  • 22
  • 31