Skip to content

Commit

Permalink
Merge build-aux-local/ in to build-aux/
Browse files Browse the repository at this point in the history
Signed-off-by: Luke Shumaker <[email protected]>
  • Loading branch information
LukeShu committed Nov 17, 2021
1 parent c3cf66e commit fc40a4d
Show file tree
Hide file tree
Showing 11 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
!manifests/emissary/emissary-crds.yaml
!post-compile.sh
!api/
!build-aux-local
!build-aux
!builder/server.crt
!builder/server.key
!cmd/
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ include $(OSS_HOME)/releng/release.mk

$(call module,ambassador,$(OSS_HOME))

include $(OSS_HOME)/build-aux-local/generate.mk
include $(OSS_HOME)/build-aux-local/lint.mk
include $(OSS_HOME)/build-aux/generate.mk
include $(OSS_HOME)/build-aux/lint.mk

include $(OSS_HOME)/docs/yaml.mk

Expand Down
2 changes: 0 additions & 2 deletions build-aux-local/.gitignore

This file was deleted.

2 changes: 2 additions & 0 deletions build-aux/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@

# generate.mk
/go1*.src.tar.gz
/go-version.txt
/pip-show.txt

# var.mk
/.var.*
Expand Down
12 changes: 6 additions & 6 deletions build-aux-local/generate.mk → build-aux/generate.mk
Original file line number Diff line number Diff line change
Expand Up @@ -328,26 +328,26 @@ $(OSS_HOME)/manifests/emissary/ambassador.yaml: $(OSS_HOME)/k8s-config/create_ya
#
# Generate report on dependencies

$(OSS_HOME)/build-aux-local/pip-show.txt: sync
$(OSS_HOME)/build-aux/pip-show.txt: sync
docker exec $$($(BUILDER)) sh -c 'pip freeze --exclude-editable | cut -d= -f1 | xargs pip show' > $@

$(OSS_HOME)/builder/requirements.txt: %.txt: %.in FORCE
$(BUILDER) pip-compile
.PRECIOUS: $(OSS_HOME)/builder/requirements.txt

$(OSS_HOME)/build-aux-local/go-version.txt: $(OSS_HOME)/builder/Dockerfile.base
$(OSS_HOME)/build-aux/go-version.txt: $(OSS_HOME)/builder/Dockerfile.base
sed -En 's,.*https://dl\.google\.com/go/go([0-9a-z.-]*)\.linux-amd64\.tar\.gz.*,\1,p' < $< > $@

$(OSS_HOME)/build-aux/go1%.src.tar.gz:
curl -o $@ --fail -L https://dl.google.com/go/$(@F)

$(OSS_HOME)/OPENSOURCE.md: $(tools/go-mkopensource) $(tools/py-mkopensource) $(OSS_HOME)/build-aux-local/go-version.txt $(OSS_HOME)/build-aux-local/pip-show.txt
$(MAKE) $(OSS_HOME)/build-aux/go$$(cat $(OSS_HOME)/build-aux-local/go-version.txt).src.tar.gz
$(OSS_HOME)/OPENSOURCE.md: $(tools/go-mkopensource) $(tools/py-mkopensource) $(OSS_HOME)/build-aux/go-version.txt $(OSS_HOME)/build-aux/pip-show.txt
$(MAKE) $(OSS_HOME)/build-aux/go$$(cat $(OSS_HOME)/build-aux/go-version.txt).src.tar.gz
set -e; { \
cd $(OSS_HOME); \
$(tools/go-mkopensource) --output-format=txt --package=mod --gotar=build-aux/go$$(cat $(OSS_HOME)/build-aux-local/go-version.txt).src.tar.gz; \
$(tools/go-mkopensource) --output-format=txt --package=mod --gotar=build-aux/go$$(cat $(OSS_HOME)/build-aux/go-version.txt).src.tar.gz; \
echo; \
{ sed 's/^---$$//' $(OSS_HOME)/build-aux-local/pip-show.txt; echo; } | $(tools/py-mkopensource); \
{ sed 's/^---$$//' $(OSS_HOME)/build-aux/pip-show.txt; echo; } | $(tools/py-mkopensource); \
} > $@

#
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion builder/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ ADD python python
RUN time pip install --no-deps -e python

# Run post-compile.sh
ADD build-aux-local build-aux-local
ADD build-aux build-aux
ADD post-compile.sh post-compile.sh
RUN bash post-compile.sh

Expand Down
4 changes: 2 additions & 2 deletions post-compile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ sudo install /buildroot/bin/capabilities_wrapper /opt/ambassador/bin/wrapper
# every other post-compile runs as well. So this is the place to recreate the
# /opt/image-build tree from scratch so the builder container stays valid.
sudo rm -rf /opt/image-build
sudo install -D -t /opt/image-build /buildroot/ambassador/build-aux-local/install.sh
sudo cp -a /buildroot/ambassador/build-aux-local/installers /opt/image-build/
sudo install -D -t /opt/image-build /buildroot/ambassador/build-aux/install.sh
sudo cp -a /buildroot/ambassador/build-aux/installers /opt/image-build/
sudo /opt/image-build/install.sh

# run any extra, local post-compile task
Expand Down

0 comments on commit fc40a4d

Please sign in to comment.