Skip to content

Commit

Permalink
Merge pull request #567 from AdoptOpenJDK/new_build_scripts
Browse files Browse the repository at this point in the history
Bring in new build scripts to master
  • Loading branch information
karianna authored Sep 26, 2018
2 parents 340b34e + 48b8d6d commit a37292a
Show file tree
Hide file tree
Showing 83 changed files with 6,518 additions and 2,325 deletions.
5 changes: 1 addition & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
openjdk/
target
.idea/
alsa-lib*
freetype*
workspace
115 changes: 115 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
# Changelog for openjdk-build scripts

## Version 1.0.0 (14 May 2018)

See [Commit History](https://github.com/AdoptOpenJDK/openjdk-build/commits/master)
up until May the 14th 2018.

## Version 2.0.0 (TBA)

A major overhaul to split out Docker and Native builds, fix a host of small
issues and place build jobs into Groovy Pipeline scripts.

### Core Build Changes

1. _configureBuild.sh_ added. The pre-build configuration logic now resides in
this script.
1. _native-build.sh_ added. This script is invoked for building (Adopt) OpenJDK
binaries natively.
1. _docker-build.sh_ added. This script is invoked for building (Adopt) OpenJDK
binaries in a Docker container.
1. _sbin/prepareWorkspace.sh_ added
1. _sbin/colour-codes.sh_ removed to simplify code
1. _makejdk.sh_ removed - please use _makejdk-any-platform.sh_ or (rarely)
_sbin/build.sh_ instead.
1. _sbin/common-functions.sh_ removed and its logic split
1. _sbin/common/common.sh_ added
1. _sbin/common/config_init.sh_ added
1. _sbin/common/constants.sh_ added
1. _sbin/build.template_ added for saving off the configure configuration.
1. _sbin/signalhandler.sh_ moved to _signalhandler.sh_
1. _sbin/build.sh_ enhanced, now requires a 'saved' build configuration to run.
This 'saved' build configuration is created by _makejdk-any-platform.sh_ but
can be generated manually as well.
1. _sign.sh_ added for code signing functionality.


#### _makejdk-any-platform.sh_, _build.sh_, _makejdk.sh_ usage changes

1. More versions added, `jdk8u | jdk9 | jdk10 | jfx | amber` are now all supported
1. `-B` is now used for specifying the build number (long form `--build-number`).
1. `-bv` is removed, (long form `--variant` changes to `--build-variant`).
1. `-c` (long form `--clean-docker-build`) added to build from a clean docker container.
1. `-ca` changes to `-C`, (long form `--configure-args` stays the same).
1. `-D` (long form `--docker`) added for building in a docker container.
1. `-dsgc` is removed, (long form `--disable-shallow-git-clone` stays the same).
1. `-ftd` changes to `-f`, (long form `--freetype-dir` stays the same).
1. `-h` (long form `--help`) added.
1. `-i` (long form `--ignore-container`) added to ignore existing docker container.
1. `-j, --jtreg` and `-js, --jtreg-subsets` are removed as tests should be run
via the openjdk-tests repo / project.
1. `-J` (long form `--jdk-boot-dir` added to set JDK boot dir.
1. `-nc` changes to `-n`, (long form `--no-colour` stays the same).
1. `-p` (long form `--processors`) added to set number of processors in docker build.
1. `-sf` changes to `-F`, (long form `--skip-freetype` stays the same).
1. `--sudo` added to run the docker container as root.
1. `--tmp-space-build` (set a temporary build space if regular workspace is unavailable).
1. `-T` (long form `--target-file-name` added to specify the final name of the binary.
1. `-u` (long form `--update-version`) added to specify the update version.
1. `-V` (long form `--jvm-variant` specify the JVM variant (server or client).

Please see _makejdk-any-platform.1_ man page for full details.

### Test Changes

1. _sbin/jtreg.sh_ removed (superseded by the openjdk-tests project).
1. _sbin/jtreg_prep.sh_ removed (superseded by the openjdk-tests project).

### Docker Support

1. `-D` (long form `--docker`) has been added for building in a docker container.
1. `-c` (long form `--clean-docker-build`) has been added to build from a clean
docker container.
1. `-i` (long form `--ignore-container`) has been added to ignore existing docker
container.
1. `-p` (long form `--processors`) added to set number of processors in docker build.
1. `--sudo` added to run the docker container as root.
1. _docker-build.sh_ added. This script is invoked for building (Adopt) OpenJDK
binaries in a Docker container.
1. _docker/jdk<X>/x86_64/ubuntu/Dockerfile_ updated for various bug fixes.
1. _docker/jdk<X>/x86_64/ubuntu/dockerConfiguration.sh_ files added. These
contain Docker specific environment variables that the build scripts need (as
opposed to falsely picking up the underlying native env).

### Build Farm Support

1. New _build-farm/make-adopt-build-farm.sh_ added for the new AdoptOpenJDK
Build Farm jenkins pipeline to build Adopt OpenJDK binaries. Sets the default
environment variables that are currently set in individual jobs. This allows
us to now track and version these variables.
1. New _build-farm/set-platform-specific-configurations.sh_ added for the new
AdoptOpenJDK Build Farm jenkins pipeline to build Adopt OpenJDK binaries. Sets
the default environment variables that are currently set in individual jobs.
This allows us to now track and version these variables.
1. New _build-farm/set-platform-specific-configurations/<platform>.sh added for
the new AdoptOpenJDK Build Farm jenkins pipeline to build Adopt OpenJDK binaries.
Sets the default environment variables for specific platforms that are currently
set in individual jobs. This allows us to now track and version these variables.
1. New _build-farm/sign-releases.sh added for the new AdoptOpenJDK Build Farm
jenkins pipeline to code sign Adopt OpenJDK binaries (Mac and Windows for now).
1. _pipelines/build/build_base_file.groovy_ added. This co-ordinates the various
pipeline builds.
1. _pipelines/build/openjdk\_build\_pipeline.groovy_ added. This forms the base
pipeline code for each build.
1. _pipelines/build/openjdk\<version\>\_\<variant\>\_\<nightly\|release\>\_pipeline.groovy_
files added. These will eventually replace the existing individual jobs with a
Pipeline for each version and variant.

### Documentation and Misc

1. _README.md_ updated to reflect new scripts
1. _images/AdoptOpenJDK_Build_Script_Relationships.png_ added to show script
relationship.
1. _.gitignore_ changed to reflect new `workspace` base directory, please check
your local .gitignore for the diff.
1. _makejdk-any-platform.1_ man page updated to reflect new script usage
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ We ask that you include a line similar to the following as part of your pull req
```
DCO 1.1 Signed-off-by: Random J Developer
```
“DCO” stands for “Developer Certificate of Origin,” and refers to [the same text used in the Linux Kernel community](http://elinux.org/Developer_Certificate_Of_Origin). Of course, you should replace "Random J Developer" by your own real name.
“DCO” stands for “Developer Certificate of Origin,” and refers to [the same text used in the Linux Kernel community](https://elinux.org/Developer_Certificate_Of_Origin). Of course, you should replace "Random J Developer" by your own real name.

By adding this simple comment, you are telling the community that you wrote the code you are contributing, or you have the right to pass on the code that you are contributing.

Expand All @@ -39,7 +39,7 @@ All the project's source files must start with a comment, as near to the top of

We don't place explicit copyright statements in the project source files. The project comprises many distinct pieces of code, spread across numerous source files, and authored by a variety of individuals. Managing copyright statements is unproductive and [can lead to confusion and contention around the edge cases](https://opensource.com/law/14/n2/copyright-statements-source-files). Rather we utilize [the NOTICE file](https://github.com/AdoptOpenJDK/openjdk-build/blob/master/NOTICE) mechanism as a way to acknowledge copyright broadly where there is a valid reason to do so.

Finally, for similar reasons to avoiding individual copyright statements, we don't maintain `@author` tags in source files. There are good arguments to suggest that [author tags discourage open contribution](http://producingoss.com/en/managing-volunteers.html#territoriality), and we depend upon Git to maintain that information for the project.
Finally, for similar reasons to avoiding individual copyright statements, we don't maintain `@author` tags in source files. There are good arguments to suggest that [author tags discourage open contribution](https://producingoss.com/en/managing-volunteers.html#territoriality), and we depend upon Git to maintain that information for the project.

### Ensuring high quality
After we receive your pull request the [Travis pull request builder](https://travis-ci.org/AdoptOpenJDK/openjdk-build) will test your changes and ensure they meet the coding style guidelines. Watch for the results posted as a comment to the PR, and investigate and fix any failures.
Expand Down
4 changes: 2 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
https://www.apache.org/licenses/

TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION

Expand Down Expand Up @@ -192,7 +192,7 @@
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0
https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
Expand Down
Loading

0 comments on commit a37292a

Please sign in to comment.