Skip to content

Commit 9219708

Browse files
committed
build: fix protobuf out-of-tree build
Otherwise it aborts with "File does not reside within any path specified using --proto_path (or -I)" Signed-off-by: David Lamparter <[email protected]>
1 parent bf6005d commit 9219708

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

grpc/subdir.am

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,12 @@ EXTRA_DIST += grpc/frr-northbound.proto
2323

2424
AM_V_PROTOC = $(am__v_PROTOC_$(V))
2525
am__v_PROTOC_ = $(am__v_PROTOC_$(AM_DEFAULT_VERBOSITY))
26-
am__v_PROTOC_0 = @echo " PROTOC" $@;
26+
am__v_PROTOC_0 = @echo " PROTOC " $@;
2727
am__v_PROTOC_1 =
2828

2929
SUFFIXES += .pb.h .pb.cc .grpc.pb.cc
3030

3131
.proto.pb.cc:
32-
$(AM_V_PROTOC)$(PROTOC) -I$(top_srcdir) --cpp_out=$(top_srcdir) $(top_srcdir)/$^
32+
$(AM_V_PROTOC)$(PROTOC) -I$(top_srcdir) --cpp_out=$(top_builddir) $^
3333
.proto.grpc.pb.cc:
34-
$(AM_V_PROTOC)$(PROTOC) -I$(top_srcdir) --grpc_out=$(top_srcdir) --plugin=protoc-gen-grpc=`which grpc_cpp_plugin` $(top_srcdir)/$^
34+
$(AM_V_PROTOC)$(PROTOC) -I$(top_srcdir) --grpc_out=$(top_builddir) --plugin=protoc-gen-grpc=`which grpc_cpp_plugin` $^

qpb/subdir.am

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,15 @@ if HAVE_PROTOBUF
3535

3636
# Rules
3737
.proto.pb.h:
38-
$(PROTOC) -I$(top_srcdir) --cpp_out=$(top_srcdir) $(top_srcdir)/$^
38+
$(PROTOC) -I$(top_srcdir) --cpp_out=$(top_builddir) $^
3939

4040
AM_V_PROTOC_C = $(am__v_PROTOC_C_$(V))
4141
am__v_PROTOC_C_ = $(am__v_PROTOC_C_$(AM_DEFAULT_VERBOSITY))
4242
am__v_PROTOC_C_0 = @echo " PROTOC_C" $@;
4343
am__v_PROTOC_C_1 =
4444

4545
.proto.pb-c.c:
46-
$(AM_V_PROTOC_C)$(PROTOC_C) -I$(top_srcdir) --c_out=$(top_srcdir) $(top_srcdir)/$^
46+
$(AM_V_PROTOC_C)$(PROTOC_C) -I$(top_srcdir) --c_out=$(top_builddir) $^
4747
.pb-c.c.pb-c.h:
4848
@/bin/true
4949

0 commit comments

Comments
 (0)