diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 38 |
1 files changed, 20 insertions, 18 deletions
@@ -1,29 +1,31 @@ -all: debug - -build: stage0.stamp stage1.stamp stage2.stamp # stage3.stamp - -debug: stage2.stamp - docker container prune -f - mkdir -p framebuf - docker run -it --mount type=bind,source=$(abspath framebuf),target=/framebuf cryptech-builder:stage2 /xilinx-unpack/builder +all: stage0.stamp stage1.stamp stage2.stamp stage3.stamp stage0.stamp: - mkdir -p stage0/jessie_chroot - cd stage0; sudo /usr/sbin/debootstrap --foreign jessie jessie_chroot - sudo tar -C stage0/jessie_chroot -c . | docker import - cryptech-builder:stage0 - sudo rm -rf stage0/jessie_chroot + mkdir -p fs/cryptech-builder + sudo /usr/sbin/debootstrap --foreign jessie fs + sudo tar -C fs -xf Xilinx_ISE_DS_Lin_14.7_1015_1.tar + sudo tar -C fs -c . | docker import - cryptech-builder:stage0 + sudo rm -rf fs touch $@ -stage1.stamp: stage0.stamp stage1/Dockerfile - cd stage1; docker build -t cryptech-builder:stage1 . +stage1.stamp: stage0.stamp + docker run -it --name cryptech-builder-stage1 \ + --mount type=bind,source=$(abspath .),target=/cryptech-builder \ + cryptech-builder:stage0 /cryptech-builder/stage1 + docker commit -c 'USER builder' cryptech-builder-stage1 cryptech-builder:stage2 + docker container rm cryptech-builder-stage1 touch $@ -stage2.stamp: stage1.stamp stage2/Dockerfile - cd stage2; docker build -t cryptech-builder:stage2 . +stage2.stamp: stage1.stamp + docker run -it --name cryptech-builder-stage2 \ + --mount type=bind,source=$(abspath .),target=/cryptech-builder \ + cryptech-builder:stage1 /cryptech-builder/stage2 + docker commit -c 'USER builder' cryptech-builder-stage2 cryptech-builder:stage2 + docker container rm cryptech-builder-stage2 touch $@ -stage3.stamp: stage2.stamp stage3/Dockerfile - cd stage3; docker build -t cryptech-builder:stage3 . +stage3.stamp: stage2.stamp + docker build -t cryptech-builder . touch $@ clean: |