Skip to content

Commit

Permalink
Mention the protobuf bug in Readme
Browse files Browse the repository at this point in the history
As suggested in kraiskil#39
  • Loading branch information
kraiskil committed Jan 29, 2024
1 parent 69e7615 commit fd9d824
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,9 @@ cmake -DCMAKE_BUILD_TYPE=Release ..
make onnx2c
```

### FAQ

### Getting `error: ‘class onnx::ModelProto’ has no member named ‘ParseFromIstream’;` ?
#### Getting `error: ‘class onnx::ModelProto’ has no member named ‘ParseFromIstream’;` ?

If you have ProtoBuf 3.6 or earlier, you need the following modification to `onnx/onnx/onnx.proto`

Expand All @@ -60,6 +61,13 @@ With ProtoBuf 3.12 (e.g. Ubuntu 20.10 onwards) this modification is not needed.

Versions between 3.6 and 3.12 are uninvestigated.

#### Seeing build error `void* __builtin_memset ... is out of the bounds ...` ?

On (at least) protobuf 3.6, which ships as default on Ubuntu 20.04, the build fails when onnx2c is build in `Release` mode.

Change the buildstep above to `cmake -DCMAKE_BUILD_TYPE=Debug ..`
Or update your protobuf.
See kraiskil/onnx2c#39 and onnx/onnx#4756.

Usage
-----
Expand Down

0 comments on commit fd9d824

Please sign in to comment.