kythe.io@v0.0.68-0.20240422202219-7225dbc01741/kythe/extractors/openjdk8/Dockerfile (about)

     1  # Copyright 2015 The Kythe Authors. All rights reserved.
     2  #
     3  # Licensed under the Apache License, Version 2.0 (the "License");
     4  # you may not use this file except in compliance with the License.
     5  # You may obtain a copy of the License at
     6  #
     7  #   http://www.apache.org/licenses/LICENSE-2.0
     8  #
     9  # Unless required by applicable law or agreed to in writing, software
    10  # distributed under the License is distributed on an "AS IS" BASIS,
    11  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  # See the License for the specific language governing permissions and
    13  # limitations under the License.
    14  
    15  FROM google/kythe-base
    16  # TODO(schroederc): reuse //kythe/java/com/google/devtools/kythe/extractors/java/standalone:docker
    17  
    18  # Output location for .kzip files
    19  VOLUME /idx
    20  
    21  RUN apt-get update && \
    22      apt-get upgrade -y && \
    23      apt-get install -y mercurial curl zsh \
    24        ant build-essential autoconf automake binutils cpio procps gawk m4 file libmotif-dev libcups2-dev libfreetype6-dev libasound2-dev libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev unzip zip && \
    25      apt-get clean -y
    26  ENTRYPOINT ["/usr/bin/zsh"]
    27  
    28  RUN hg clone http://hg.openjdk.java.net/jdk8/jdk8/ /tmp/jdk8
    29  WORKDIR /tmp/jdk8
    30  
    31  RUN sh ./get_source.sh
    32  RUN sh ./configure \
    33        --with-freetype-lib=/usr/lib/x86_64-linux-gnu --with-freetype-include=/usr/include/freetype2
    34  
    35  # Fix make4.0 issue
    36  RUN curl http://hg.openjdk.java.net/jdk9/dev/hotspot/raw-rev/e8d4d0db1f06 \
    37      | tail -n+10 \
    38      | patch -d hotspot -p1
    39  
    40  # Ensure all dependencies are present
    41  RUN LOG= make JOBS=4 jdk
    42  
    43  ADD kythe/java/com/google/devtools/kythe/extractors/java/standalone/javac_extractor_deploy.jar /kythe/bin/
    44  ADD kythe/extractors/openjdk/extract.sh /kythe/bin/
    45  
    46  # Extract compilations when run
    47  ENTRYPOINT ["/kythe/bin/extract.sh"]