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

make: always generate proto files sans rust #6861

Merged
merged 2 commits into from
Feb 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,8 @@ ifneq ($(FUZZING),0)
endif
ifneq ($(RUST),0)
include cln-rpc/Makefile
include cln-grpc/Makefile
endif
include cln-grpc/Makefile

$(MSGGEN_GENALL)&: doc/schemas/*.request.json doc/schemas/*.schema.json
PYTHONPATH=contrib/msggen $(PYTHON) contrib/msggen/msggen/__main__.py
Expand All @@ -389,7 +390,6 @@ $(GRPC_GEN)&: cln-grpc/proto/node.proto cln-grpc/proto/primitives.proto
$(PYTHON) -m grpc_tools.protoc -I cln-grpc/proto cln-grpc/proto/primitives.proto --python_out=$(GRPC_PATH)/ --experimental_allow_proto3_optional
find $(GRPC_DIR)/ -type f -name "*.py" -print0 | xargs -0 sed -i'.bak' -e 's/^import \(.*\)_pb2 as .*__pb2/from pyln.grpc import \1_pb2 as \1__pb2/g'
find $(GRPC_DIR)/ -type f -name "*.py.bak" -print0 | xargs -0 rm -f
endif

# We make pretty much everything depend on these.
ALL_GEN_HEADERS := $(filter %gen.h,$(ALL_C_HEADERS))
Expand Down
6 changes: 5 additions & 1 deletion contrib/docker/Dockerfile.alpine
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ RUN apk update && \
libtool \
net-tools \
postgresql-dev \
py3-mako \
linux-headers \
py3-pip \
python3 \
python3-dev \
sqlite-dev \
Expand All @@ -29,6 +30,9 @@ COPY . /source

RUN git clone /source /repo --recursive && \
cd /repo && \
python3 -m pip install poetry && \
poetry export --without-hashes --with=dev > requirements.txt && \
python3 -m pip install -r requirements.txt --ignore-installed --force && \
./configure --enable-static --prefix=/usr && \
make -j $(nproc) && \
make install
Expand Down
Loading