Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

protobuf and eigen scripts don't seem to be working. #39

Open
NRKEYES opened this issue May 19, 2018 · 4 comments
Open

protobuf and eigen scripts don't seem to be working. #39

NRKEYES opened this issue May 19, 2018 · 4 comments

Comments

@NRKEYES
Copy link

NRKEYES commented May 19, 2018

I might be missing something obvious, but no matter what I have tried so far these commands fail. Was there something in an update that broke this? It seems to be related to a GREP issue.

sudo ./protobuf.sh install ~/Chemistry/tensorFlow cmake/Modules cmake/Modules
Finding Protobuf version in /Users/nkeyes/Chemistry/tensorFlow using method 0...
usage: grep [-abcDEFGHhIiJLlmnOoqRSsUVvwxZ] [-A num] [-B num] [-C[num]]
[-e pattern] [-f file] [--binary-files=value] [--color=when]
[--context[=num]] [--directories=action] [--label] [--line-buffered]
[--null] [pattern] [file ...]
Finding Protobuf version in /Users/nkeyes/Chemistry/tensorFlow using method 1...
usage: grep [-abcDEFGHhIiJLlmnOoqRSsUVvwxZ] [-A num] [-B num] [-C[num]]
[-e pattern] [-f file] [--binary-files=value] [--color=when]
[--context[=num]] [--directories=action] [--label] [--line-buffered]
[--null] [pattern] [file ...]
Finding Protobuf version in /Users/nkeyes/Chemistry/tensorFlow using method 2...
usage: grep [-abcDEFGHhIiJLlmnOoqRSsUVvwxZ] [-A num] [-B num] [-C[num]]
[-e pattern] [-f file] [--binary-files=value] [--color=when]
[--context[=num]] [--directories=action] [--label] [--line-buffered]
[--null] [pattern] [file ...]
Finding Protobuf version in /Users/nkeyes/Chemistry/tensorFlow using method 3...
usage: grep [-abcDEFGHhIiJLlmnOoqRSsUVvwxZ] [-A num] [-B num] [-C[num]]
[-e pattern] [-f file] [--binary-files=value] [--color=when]
[--context[=num]] [--directories=action] [--label] [--line-buffered]
[--null] [pattern] [file ...]
Finding Protobuf version in /Users/nkeyes/Chemistry/tensorFlow using method 4...

@acidtonic
Copy link

acidtonic commented Jun 7, 2018

I ran into a similar issue but for me the grep just never matched.

I manually looked into the workspace.bzl file and the eigen entry used to be inside a "native.new_http_archive" entry but now it's in "tf_http_archive" thus the regex needs to be changed.

#ARCHIVE_HEADER="native.new_http_archive\(\s*"
ARCHIVE_HEADER="tf_http_archive\(\s*"

After commenting out the original and using the replacement line shown above, everything works again.

For the protobuf.sh script the same thing happened but the fix was slightly different.

#HTTP_HEADER="native.http_archive\(\s"
HTTP_HEADER="tf_http_archive\(\s"

Good luck!

@joeylitalien
Copy link

Apple switched from GNU grep to BSD grep in MacOS 10.8 so the two scripts will fail on Darwin due to the unknown -P grep option. Following @acidtonic fix, if you do brew install grep and replace every occurrences of grep by ggrep, you should be able to run both scripts on Mac, assuming you also have wget installed.

@MatthewScholefield
Copy link

Another problem is that for me, <tensorflow-source>/tensorflow/workspace.bzl had been changed to use vairables for protobuf urls which messed things up. To fix it I had to manually remove the PROTOBUF_URLS (or something similar) variable and replace it with the actual constant value.

@ShubhamSrivastava93
Copy link

I manually set

  PROTOBUF_URLS = ["https://mirror.bazel.build/github.com/google/protobuf/archive/v3.6.0.tar.gz",
	"https://github.com/google/protobuf/archive/v3.6.0.tar.gz", ]
  PROTOBUF_URL="https://mirror.bazel.build/github.com/google/protobuf/archive/v3.6.0.tar.gz"
  PROTOBUF_FOLDER="protobuf-3.6.0"

Note: set the values according to your /tensorflow/workspace.bzl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants