1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-03-28 14:56:28 +01:00

Cleanup CDT repo related to the docker + Java 21 updates

- Fix links for cdt-infra
- The cdt-infra git repo is now archived, so this commit updates
the links to the current values.
- Add new Docker related files to the gitattributes as text files
- Update DEFAULT_BUFFER_SIZE for Java 21's value when building JNI,
this also means the dll/exe need a rebuild
- add a toolchains.xml since we use Java 21 toolchain, but most bundles
are Java 17 still
This commit is contained in:
Jonah Graham 2024-04-26 11:34:11 -04:00
parent 9fb6260b6a
commit cc66780e92
21 changed files with 55 additions and 17 deletions

3
.gitattributes vendored
View file

@ -44,8 +44,11 @@ Makefile text
# Build files # Build files
*.Jenkinsfile text *.Jenkinsfile text
Jenkinsfile text Jenkinsfile text
Dockerfile text
*.yaml text *.yaml text
*.yml text *.yml text
.dockerignore text
uid_entrypoint text
# Qt # Qt
*.pro text *.pro text

View file

@ -16,9 +16,17 @@ mvn package
and the resulting p2 repository will be in `releng/org.eclipse.cdt.repo/target/repository` and the resulting p2 repository will be in `releng/org.eclipse.cdt.repo/target/repository`
The current set of options to Maven used for building on the CI can be seen in the Jenkinsfiles on [cdt-infra](https://github.com/eclipse-cdt/cdt-infra/tree/master/jenkins/pipelines/cdt) The current set of options to Maven used for building on the CI can be seen in the [Jenkinsfile](https://github.com/eclipse-cdt/cdt/blob/main/Jenkinsfile) and GitHub actions [workflows](https://github.com/eclipse-cdt/cdt/tree/main/.github/workflows)
To build CDT plug-ins you need a standard Maven & Java developement environment. The Dockerfiles used for CDT's images are published in [cdt-infra](https://github.com/eclipse-cdt/cdt-infra/tree/master/docker). The requirements for running all tests successfully and for rebuilding non-Java parts of CDT are much more extensive than standard Maven & Java and include items such as GCC, GDB, yarn, Node, etc. Refer to the Dockerfiles for the current versions of those dependencies. To build CDT plug-ins you need a standard Maven & Java development environment. The Dockerfiles used for CDT's images are published in [docker](https://github.com/eclipse-cdt/cdt/tree/main/docker). The requirements for running all tests successfully and for rebuilding non-Java parts of CDT are much more extensive than standard Maven & Java and include items such as GCC, GDB, yarn, Node, etc. Refer to the Dockerfiles for the current versions of those dependencies.
### Checking code cleanliness
The CI build automatically run code cleanliness checks. To run them on your computer it is recommended to use the Docker image, for example like this from the root of the checked out CDT repo:
```sh
docker run --rm -it -v $(git rev-parse --show-toplevel):/work -w /work/$(git rev-parse --show-prefix) --cap-add=SYS_PTRACE --security-opt seccomp=unconfined quay.io/eclipse-cdt/cdt-infra-plus-eclipse-install:latest releng/scripts/check_code_cleanliness.sh
```
### Profiles ### Profiles
@ -123,7 +131,7 @@ There are a few special values that can be specified (see BaseParametrizedTestCa
The default, defined in the root pom.xml, it is blank, which uses `gdb` and `gdbserver`. The default, defined in the root pom.xml, it is blank, which uses `gdb` and `gdbserver`.
See BaseParametrizedTestCase for more info. See BaseParametrizedTestCase for more info.
To build all gdb versions for testing CDT see [download-build-gdb.sh](https://github.com/eclipse-cdt/cdt-infra/blob/master/docker/scripts/download-build-gdb.sh) To build all gdb versions for testing CDT see [download-build-gdb.sh](https://github.com/eclipse-cdt/cdt/blob/main/docker/scripts/download-build-gdb.sh)
#### native #### native

View file

@ -27,10 +27,10 @@ SPDX-License-Identifier: EPL-2.0
The project maintains the following source code repositories: The project maintains the following source code repositories:
* https://github.com/eclipse-cdt/.github
* https://github.com/eclipse-cdt/cdt * https://github.com/eclipse-cdt/cdt
* https://github.com/eclipse-cdt/cdt-infra
* https://github.com/eclipse-cdt/cdt-lsp * https://github.com/eclipse-cdt/cdt-lsp
* https://github.com/eclipse-cdt/.eclipsefdn
* https://github.com/eclipse-cdt/.github
## Cryptography ## Cryptography

View file

@ -1,6 +1,6 @@
## Code Formatting ## Code Formatting
These are the coding style recommendations that are in place with project setting. They are enforced by the [build process](https://github.com/eclipse-cdt/cdt-infra/tree/master/jenkins/pipelines/cdt/verify#cdt-verify-code-cleanliness) and auto-save actions in Eclipse. These are the coding style recommendations that are in place with project setting. They are enforced by the build process (as defined in [Jenkinsfile](https://github.com/eclipse-cdt/cdt/blob/main/Jenkinsfile) and GitHub actions [workflows](https://github.com/eclipse-cdt/cdt/tree/main/.github/workflows)) and auto-save actions in Eclipse.
* Preserve formatting and style of old code when making patches * Preserve formatting and style of old code when making patches
* Use default "Eclipse" code formatting for Java for new code * Use default "Eclipse" code formatting for Java for new code
@ -13,7 +13,7 @@ Externalize strings (excluding exception arguments, tests and special identifier
## Eclipse Java Errors/Warnings ## Eclipse Java Errors/Warnings
All CDT plugins override default compiler error/warning and use project specific errors/warnings. This enforced by the [build process](https://github.com/eclipse-cdt/cdt-infra/tree/master/jenkins/pipelines/cdt/verify#cdt-verify-code-cleanliness). All CDT plugins override default compiler error/warning and use project specific errors/warnings. This enforced by the build process (as defined in [Jenkinsfile](https://github.com/eclipse-cdt/cdt/blob/main/Jenkinsfile) and GitHub actions [workflows](https://github.com/eclipse-cdt/cdt/tree/main/.github/workflows)).
All committers and contributors submitting patches should enable [API tooling](http://wiki.eclipse.org/PDE/API_Tools/User_Guide#API_Tooling_Setup) by setting target baseline platform. Do not commit code with API errors. All committers and contributors submitting patches should enable [API tooling](http://wiki.eclipse.org/PDE/API_Tools/User_Guide#API_Tooling_Setup) by setting target baseline platform. Do not commit code with API errors.

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2 Bundle-ManifestVersion: 2
Bundle-Name: %pluginName Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.cdt.core.native;singleton:=true Bundle-SymbolicName: org.eclipse.cdt.core.native;singleton:=true
Bundle-Version: 6.3.300.qualifier Bundle-Version: 6.3.400.qualifier
Bundle-Activator: org.eclipse.cdt.internal.core.natives.CNativePlugin Bundle-Activator: org.eclipse.cdt.internal.core.natives.CNativePlugin
Bundle-Vendor: %providerName Bundle-Vendor: %providerName
Bundle-Localization: plugin Bundle-Localization: plugin

View file

@ -10,7 +10,7 @@ extern "C" {
#undef org_eclipse_cdt_utils_pty_PTYInputStream_MAX_SKIP_BUFFER_SIZE #undef org_eclipse_cdt_utils_pty_PTYInputStream_MAX_SKIP_BUFFER_SIZE
#define org_eclipse_cdt_utils_pty_PTYInputStream_MAX_SKIP_BUFFER_SIZE 2048L #define org_eclipse_cdt_utils_pty_PTYInputStream_MAX_SKIP_BUFFER_SIZE 2048L
#undef org_eclipse_cdt_utils_pty_PTYInputStream_DEFAULT_BUFFER_SIZE #undef org_eclipse_cdt_utils_pty_PTYInputStream_DEFAULT_BUFFER_SIZE
#define org_eclipse_cdt_utils_pty_PTYInputStream_DEFAULT_BUFFER_SIZE 8192L #define org_eclipse_cdt_utils_pty_PTYInputStream_DEFAULT_BUFFER_SIZE 16384L
#undef org_eclipse_cdt_utils_pty_PTYInputStream_MAX_BUFFER_SIZE #undef org_eclipse_cdt_utils_pty_PTYInputStream_MAX_BUFFER_SIZE
#define org_eclipse_cdt_utils_pty_PTYInputStream_MAX_BUFFER_SIZE 2147483639L #define org_eclipse_cdt_utils_pty_PTYInputStream_MAX_BUFFER_SIZE 2147483639L
/* /*

View file

@ -10,7 +10,7 @@ extern "C" {
#undef org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_SKIP_BUFFER_SIZE #undef org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_SKIP_BUFFER_SIZE
#define org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_SKIP_BUFFER_SIZE 2048L #define org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_SKIP_BUFFER_SIZE 2048L
#undef org_eclipse_cdt_utils_spawner_SpawnerInputStream_DEFAULT_BUFFER_SIZE #undef org_eclipse_cdt_utils_spawner_SpawnerInputStream_DEFAULT_BUFFER_SIZE
#define org_eclipse_cdt_utils_spawner_SpawnerInputStream_DEFAULT_BUFFER_SIZE 8192L #define org_eclipse_cdt_utils_spawner_SpawnerInputStream_DEFAULT_BUFFER_SIZE 16384L
#undef org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_BUFFER_SIZE #undef org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_BUFFER_SIZE
#define org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_BUFFER_SIZE 2147483639L #define org_eclipse_cdt_utils_spawner_SpawnerInputStream_MAX_BUFFER_SIZE 2147483639L
/* /*

View file

@ -23,7 +23,7 @@
<relativePath>../../pom.xml</relativePath> <relativePath>../../pom.xml</relativePath>
</parent> </parent>
<version>6.3.300-SNAPSHOT</version> <version>6.3.400-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.core.native</artifactId> <artifactId>org.eclipse.cdt.core.native</artifactId>
<packaging>eclipse-plugin</packaging> <packaging>eclipse-plugin</packaging>

View file

@ -117,7 +117,6 @@ RUN export JVERSION=${JDK17_VERSION} \
&& find $JHOME/include \ && find $JHOME/include \
&& rm -rf /tmp/x && rm -rf /tmp/x
# Default to JAVA21 being in use # Default to JAVA21 being in use
ENV PATH="${JAVA21_HOME}/bin:${PATH}" ENV PATH="${JAVA21_HOME}/bin:${PATH}"
ENV JAVA_HOME ${JAVA21_HOME} ENV JAVA_HOME ${JAVA21_HOME}
@ -129,6 +128,8 @@ RUN curl -fsSL https://archive.apache.org/dist/maven/maven-3/$MAVEN_VERSION/bina
&& ln -s /usr/share/maven/bin/mvn /usr/bin/mvn && ln -s /usr/share/maven/bin/mvn /usr/bin/mvn
ENV MAVEN_HOME /usr/share/maven ENV MAVEN_HOME /usr/share/maven
RUN mkdir -p ${HOME}/.m2
COPY toolchains.xml ${HOME}/.m2
#Fix permissions for OpenShift & standard k8s #Fix permissions for OpenShift & standard k8s
RUN chown -R 1000:0 ${HOME} \ RUN chown -R 1000:0 ${HOME} \

View file

@ -37,7 +37,8 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
RUN pip3 install meson RUN pip3 install meson
# GDB pre-built in a different image # GDB pre-built in a different image
COPY --from=cdt-infra-all-gdbs:ubuntu-18.04 /shared/common/gdb/gdb-all /shared/common/gdb/gdb-all COPY --from=cdt-infra-all-gdbs:ubuntu-18.04 /shared/common/gdb/gdb-all/bin /shared/common/gdb/gdb-all/bin
COPY --from=cdt-infra-all-gdbs:ubuntu-18.04 /shared/common/gdb/gdb-all/install /shared/common/gdb/gdb-all/install
ENV PATH="/shared/common/gdb/gdb-all/bin:${PATH}" ENV PATH="/shared/common/gdb/gdb-all/bin:${PATH}"
# Get pre-built MacOSX toolchain from other image (this also # Get pre-built MacOSX toolchain from other image (this also

0
docker/scripts/xstartup_icewm.sh Normal file → Executable file
View file

0
docker/scripts/xstartup_metacity.sh Normal file → Executable file
View file

0
docker/scripts/xstartup_mutter.sh Normal file → Executable file
View file

25
docker/toolchains.xml Normal file
View file

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF8"?>
<toolchains>
<toolchain>
<type>jdk</type>
<provides>
<id>JavaSE-21</id>
<version>21</version>
<vendor>default</vendor>
</provides>
<configuration>
<jdkHome>/usr/lib/jvm/jdk-21.0.3+9</jdkHome>
</configuration>
</toolchain>
<toolchain>
<type>jdk</type>
<provides>
<id>JavaSE-17</id>
<version>17</version>
<vendor>default</vendor>
</provides>
<configuration>
<jdkHome>/usr/lib/jvm/jdk-17.0.11+9</jdkHome>
</configuration>
</toolchain>
</toolchains>

View file

@ -1,3 +1,3 @@
#!/usr/bin/env bash #!/usr/bin/env bash
echo "This script, part of CDT's infrastructure, has been moved to https://github.com/eclipse-cdt/cdt-infra/blob/master/docker/scripts/download-build-gdb.sh" echo "This script, part of CDT's infrastructure, has been moved to https://github.com/eclipse-cdt/cdt/blob/main/docker/scripts/download-build-gdb.sh"

View file

@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2
Bundle-Name: %pluginName Bundle-Name: %pluginName
Bundle-Vendor: %providerName Bundle-Vendor: %providerName
Bundle-SymbolicName: org.eclipse.cdt.examples.dsf;singleton:=true Bundle-SymbolicName: org.eclipse.cdt.examples.dsf;singleton:=true
Bundle-Version: 2.4.200.qualifier Bundle-Version: 2.4.300.qualifier
Bundle-Activator: org.eclipse.cdt.examples.dsf.DsfExamplesPlugin Bundle-Activator: org.eclipse.cdt.examples.dsf.DsfExamplesPlugin
Bundle-Localization: plugin Bundle-Localization: plugin
Require-Bundle: org.eclipse.ui, Require-Bundle: org.eclipse.ui,

View file

@ -23,12 +23,12 @@ CDTDIR=${DIR}/../..
## ##
# Format code # Format code
## ##
: ${ECLIPSE:=~/buildtools/eclipse-SDK-4.23/eclipse} : ${ECLIPSE:=~/buildtools/eclipse-SDK-4.31/eclipse}
if test ! -e "$ECLIPSE" ; then if test ! -e "$ECLIPSE" ; then
echo "The Eclipse binary was not found at \"$ECLIPSE\"!" echo "The Eclipse binary was not found at \"$ECLIPSE\"!"
echo "You can download it to and pass it via environment variable:" echo "You can download it to and pass it via environment variable:"
echo " curl -L http://download.eclipse.org/eclipse/downloads/drops4/R-4.23-202203080310/eclipse-SDK-4.23-linux-gtk-x86_64.tar.gz | tar xzC /tmp" echo " curl -L https://download.eclipse.org/eclipse/downloads/drops4/R-4.31-202402290520/eclipse-SDK-4.31-linux-gtk-x86_64.tar.gz | tar xzC /tmp"
echo " ECLIPSE=/tmp/eclipse/eclipse ./releng/scripts/check_code_cleanliness.sh" echo " ECLIPSE=/tmp/eclipse/eclipse ./releng/scripts/check_code_cleanliness.sh"
exit 1 exit 1
fi fi