Clean up Dockerfile a bit
This commit is contained in:
		
					parent
					
						
							
								7c6363debe
							
						
					
				
			
			
				commit
				
					
						cc2ca85a91
					
				
			
		
					 1 changed files with 24 additions and 13 deletions
				
			
		
							
								
								
									
										37
									
								
								Dockerfile
									
										
									
									
									
								
							
							
						
						
									
										37
									
								
								Dockerfile
									
										
									
									
									
								
							| 
						 | 
				
			
			@ -1,13 +1,15 @@
 | 
			
		|||
# [Choice] bionic (18.04), focal (20.04)
 | 
			
		||||
ARG VARIANT="focal"
 | 
			
		||||
 | 
			
		||||
## build tools
 | 
			
		||||
FROM ubuntu:${VARIANT} AS build
 | 
			
		||||
ENV DEBIAN_FRONTEND="noninteractive"
 | 
			
		||||
 | 
			
		||||
RUN DEBIAN_FRONTEND="noninteractive" apt-get update && \
 | 
			
		||||
    DEBIAN_FRONTEND="noninteractive" apt-get -y install \
 | 
			
		||||
            tzdata gcc g++ gperf bison flex texinfo help2man make libncurses5-dev \
 | 
			
		||||
            python3-dev autoconf automake libtool libtool-bin gawk wget bzip2 xz-utils unzip \
 | 
			
		||||
            patch libstdc++6 rsync git meson ninja-build
 | 
			
		||||
RUN apt-get update && \
 | 
			
		||||
    apt-get -y install \
 | 
			
		||||
        tzdata gcc g++ gperf bison flex texinfo help2man make libncurses5-dev \
 | 
			
		||||
        python3-dev autoconf automake libtool libtool-bin gawk wget bzip2 xz-utils unzip \
 | 
			
		||||
        patch libstdc++6 rsync git meson ninja-build
 | 
			
		||||
 | 
			
		||||
WORKDIR /build
 | 
			
		||||
RUN wget http://crosstool-ng.org/download/crosstool-ng/crosstool-ng-1.26.0.tar.xz && \
 | 
			
		||||
| 
						 | 
				
			
			@ -22,15 +24,24 @@ RUN wget http://crosstool-ng.org/download/crosstool-ng/crosstool-ng-1.26.0.tar.x
 | 
			
		|||
    
 | 
			
		||||
ADD ct-ng.config .config
 | 
			
		||||
RUN /usr/local/ct/bin/ct-ng build
 | 
			
		||||
RUN cd /build/ && git clone https://github.com/fail0verflow/hbc.git /build/hbc && cd /build/hbc/channel/wiiload && make
 | 
			
		||||
RUN git clone https://github.com/fail0verflow/bootmii-utils.git /build/bootmii-utils && cd /build/bootmii-utils/client && make 
 | 
			
		||||
## Final build image
 | 
			
		||||
FROM  ubuntu:${VARIANT}
 | 
			
		||||
RUN cd /build/ && \
 | 
			
		||||
    git clone https://github.com/fail0verflow/hbc.git /build/hbc && \
 | 
			
		||||
    cd /build/hbc/channel/wiiload && \
 | 
			
		||||
    git checkout 13305cfbe5db47eebc5e62aeed14f7adfbb83a5a && \
 | 
			
		||||
    make
 | 
			
		||||
RUN git clone https://github.com/fail0verflow/bootmii-utils.git /build/bootmii-utils && \
 | 
			
		||||
    cd /build/bootmii-utils/client && \
 | 
			
		||||
    git checkout a32b8f6520d136677213fcbb730035a7e89567e2 && \
 | 
			
		||||
    make
 | 
			
		||||
 | 
			
		||||
RUN DEBIAN_FRONTEND="noninteractive" apt-get update && \
 | 
			
		||||
    DEBIAN_FRONTEND="noninteractive" apt-get -y install \
 | 
			
		||||
            patch ninja-build make bc ccache gcc libncurses-dev \
 | 
			
		||||
            kmod bison flex libssl-dev openssl
 | 
			
		||||
## final build image
 | 
			
		||||
FROM  ubuntu:${VARIANT}
 | 
			
		||||
ENV DEBIAN_FRONTEND="noninteractive"
 | 
			
		||||
 | 
			
		||||
RUN apt-get update && \
 | 
			
		||||
    apt-get -y install \
 | 
			
		||||
        patch ninja-build make bc ccache gcc libncurses-dev \
 | 
			
		||||
        kmod bison flex libssl-dev openssl
 | 
			
		||||
 | 
			
		||||
COPY --from=build /root/x-tools/powerpc-unknown-linux-gnu/ /usr/local/crosstool
 | 
			
		||||
COPY --from=build /build/hbc/channel/wiiload/wiiload /usr/local/crosstool/bin/wiiload
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue