title: protobuf: .proto file not under source directory
body: <p>I'm new to protobuf. Following the official tutorial <a href="https://developers.google.com/protocol-buffers/docs/gotutorial" rel="nofollow noreferrer">https://developers.google.com/protocol-buffers/docs/gotutorial</a>, I downloaded the latest release and tried to run the example <code>examples/addressbook.proto</code></p>
  
  <p>Inside <code>addressbook.proto</code>, there is a line 
  <code>import "google/protobuf/timestamp.proto";</code>, </p>
  
  <p>so one would need to provide a source directory (the <code>-I=</code>) so as to import this.</p>
  
  <p>My problem is that, in the downloaded release, I have <code>addressbook.proto</code> under <code>examples</code> while the needed <code>google/protobuf/timestamp.proto</code> is under <code>src</code></p>
  
  <p>When I do </p>
  
  <p><code>protoc examples/addressbook.proto --python_out=. -I=src</code></p>
  
  <p>I get an error </p>
  
  <blockquote>
    <p>examples/addressbook.proto: File does not reside within any path
    specified using --proto_path (or -I)</p>
  </blockquote>
  
  <p>I tried playing around with using <code>--proto_path</code> and got the same error.</p>
  
  <p>The issue is solved when I manually move the <code>addresbook.proto</code> under <code>src</code>, so that the needed package and the .proto are both under the same dir (specified by <code>-I=src</code>). </p>
  
  <p>However, I wonder if there is a solution when the <strong>.proto</strong> file and the other to-be-imported packages are under different directories.</p>