Skip to content

Commit 2c19d8f

Browse files
authored
Merge branch 'eclipse-platform:master' into icon-disabling
2 parents 7c019cf + d4caabf commit 2c19d8f

File tree

350 files changed

+7699
-5698
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

350 files changed

+7699
-5698
lines changed

.github/workflows/junit.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
done
3939
4040
- name: Publish Unit Test Results
41-
uses: EnricoMi/publish-unit-test-result-action@170bf24d20d201b842d7a52403b73ed297e6645b # v2.18.0
41+
uses: EnricoMi/publish-unit-test-result-action@afb2984f4d89672b2f9d9c13ae23d53779671984 # v2.19.0
4242
id: test-results
4343
with:
4444
commit: ${{ github.event.workflow_run.head_sha }}

.github/workflows/maven.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
runs-on: ubuntu-latest
2323
steps:
2424
- name: Upload
25-
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
25+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
2626
with:
2727
name: Event File
2828
path: ${{ github.event_path }}
@@ -54,7 +54,7 @@ jobs:
5454
run: |
5555
git lfs pull --include='/binaries/org.eclipse.swt.win32.win32.x86_64/WebView2Loader.dll'
5656
- name: Set up Java ${{ matrix.java }}
57-
uses: actions/setup-java@3a4f6e1af504cf6a31855fa899c6aa5355ba6c12 # v4.7.0
57+
uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 # v4.7.1
5858
with:
5959
java-version: ${{ matrix.java }}
6060
distribution: 'temurin'
@@ -92,7 +92,7 @@ jobs:
9292
integration-test
9393
- name: Upload Test Results for ${{ matrix.config.name }} / Java-${{ matrix.java }}
9494
if: always()
95-
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
95+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
9696
with:
9797
name: test-results-${{ matrix.config.native }}-java${{ matrix.java }}
9898
if-no-files-found: warn

.github/workflows/pr-checks.yml

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Fast running checks for pull-requests
2+
3+
name: Pull-Request Checks
4+
concurrency:
5+
group: ${{ github.workflow }}-${{ github.ref }}
6+
cancel-in-progress: true
7+
8+
on:
9+
pull_request:
10+
branches: [ master ]
11+
12+
jobs:
13+
check-freeze-period:
14+
uses: eclipse-platform/eclipse.platform.releng.aggregator/.github/workflows/verifyFreezePeriod.yml@master
15+
check-merge-commits:
16+
uses: eclipse-platform/eclipse.platform.releng.aggregator/.github/workflows/checkMergeCommits.yml@master
17+
check-versions:
18+
uses: eclipse-platform/eclipse.platform.releng.aggregator/.github/workflows/checkVersions.yml@master
19+
with:
20+
botName: Eclipse Platform Bot
21+

.github/workflows/verifyFreezePeriod.yml

-12
This file was deleted.
+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Publish Version Check Results
2+
3+
on:
4+
workflow_run:
5+
workflows: [ 'Pull-Request Checks' ]
6+
types: [ completed ]
7+
8+
jobs:
9+
publish-version-check-results:
10+
uses: eclipse-platform/eclipse.platform.releng.aggregator/.github/workflows/publishVersionCheckResults.yml@master
11+
with:
12+
botGithubId: eclipse-platform-bot
13+
secrets:
14+
githubBotPAT: ${{ secrets.PLATFORM_BOT_PAT }}

.mvn/extensions.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
<extension>
55
<groupId>org.eclipse.tycho</groupId>
66
<artifactId>tycho-build</artifactId>
7-
<version>4.0.10</version>
7+
<version>4.0.12</version>
88
</extension>
99
</extensions>

Jenkinsfile

+59-38
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ def runOnNativeBuildAgent(String platform, Closure body) {
4242
}
4343
}
4444

45-
/** Returns the download URL of the JDK against whoose C headers (in the 'include/' folder) and native libaries the SWT natives are compiled.*/
46-
def getNativeJdkUrl(String os, String arch){ // To update the used JDK version update the URL template below
45+
/** Returns the download URL of the JDK against whose C headers (in the 'include/' folder) and native libraries the SWT natives are compiled.*/
46+
def getNativeJdkUrl(String os, String arch) { // To update the used JDK version update the URL template below
4747
if('win32'.equals(os) && 'aarch64'.equals(arch)) {
4848
// Temporary workaround until there are official Temurin GA releases for Windows on ARM that can be consumed through JustJ
4949
dir("${WORKSPACE}/repackage-win32.aarch64-jdk") {
@@ -82,7 +82,7 @@ def getSWTVersions() { // must be called from the repository root
8282
return props
8383
}
8484

85-
boolean NATIVES_CHANGED = false
85+
def Set NATIVES_CHANGED = []
8686

8787
pipeline {
8888
options {
@@ -103,7 +103,9 @@ pipeline {
103103
PR_VALIDATION_BUILD = "true"
104104
}
105105
parameters {
106-
booleanParam(name: 'forceNativeBuilds', defaultValue: false, description: 'Forces to run the native builds of swt\'s binaries. Will push the built binaries to the master branch, unless \'skipCommit\' is set. Useful in debugging.')
106+
booleanParam(name: 'forceNativeBuilds-cocoa', defaultValue: false, description: 'Enforce a re-build of SWT\'s native binaries for Mac OS X. Will push the built binaries to the master branch, unless \'skipCommit\' is set.')
107+
booleanParam(name: 'forceNativeBuilds-gtk', defaultValue: false, description: 'Enforce a re-build of SWT\'s native binaries for Linux. Will push the built binaries to the master branch, unless \'skipCommit\' is set.')
108+
booleanParam(name: 'forceNativeBuilds-win32', defaultValue: false, description: 'Enforce a re-build of SWT\'s native binaries for Windows. Will push the built binaries to the master branch, unless \'skipCommit\' is set.')
107109
booleanParam(name: 'skipCommit', defaultValue: false, description: 'Stops committing to swt and swt binaries repo at the end. Useful in debugging.')
108110
}
109111
stages {
@@ -141,9 +143,10 @@ pipeline {
141143
git config --global user.name 'Eclipse Releng Bot'
142144
'''
143145
script {
146+
def allWS = ['cocoa', 'gtk', 'win32']
147+
def libraryFilePattern = [ 'cocoa' : 'libswt-*.jnilib', 'gtk' : 'libswt-*.so', 'win32' : 'swt-*.dll' ]
144148
def swtTag = getLatestGitTag()
145149
echo "Current tag=${swtTag}."
146-
boolean nativesChanged = false
147150
dir('bundles/org.eclipse.swt') {
148151
// Verify preprocessing is completed
149152
sh '''
@@ -154,34 +157,42 @@ pipeline {
154157
'''
155158
def sourceFoldersProps = readProperties(file: 'nativeSourceFolders.properties')
156159
def sources = sourceFoldersProps.collectEntries{ k, src -> [ k, src.split(',').collect{ f -> '\'' + f + '\''}.join(' ') ] }
157-
def diff = sh(script: "git diff HEAD ${swtTag} ${sources.values().join(' ')}", returnStdout: true)
158-
nativesChanged = !diff.strip().isEmpty()
159-
echo "Natives changed since ${swtTag}: ${nativesChanged}"
160+
for(ws in allWS) {
161+
def diff = sh(script: "git diff HEAD ${swtTag} ${sources.src_common} ${sources['src_' + ws]}", returnStdout: true)
162+
if (!diff.strip().isEmpty()) {
163+
NATIVES_CHANGED += ws
164+
}
165+
}
166+
echo "Natives changed since ${swtTag}: ${NATIVES_CHANGED.isEmpty() ? 'None': NATIVES_CHANGED}"
160167
}
161-
if (nativesChanged || params.forceNativeBuilds) {
162-
NATIVES_CHANGED = true
163-
def swtVersions = getSWTVersions()
164-
withEnv(['swt_version='+swtVersions['swt_version'], 'new_version='+swtVersions['new_version'], 'rev='+swtVersions['rev'], 'new_rev='+swtVersions['new_rev'],
165-
'comma_ver='+swtVersions['comma_ver'], "new_comma_ver=${swtVersions['maj_ver']},${swtVersions['min_ver']},${swtVersions['new_rev']},0" ]) {
166-
sh '''
168+
NATIVES_CHANGED += allWS.findAll{ ws -> params[ 'forceNativeBuilds-' + ws] }
169+
if (!NATIVES_CHANGED.isEmpty()) {
170+
def versions = getSWTVersions()
171+
sh """
172+
echo "Incrementing version from ${versions.swt_version} to ${versions.new_version}"
173+
sed -i -e "s/REVISION = ${versions.rev}/REVISION = ${versions.new_rev}/g" \
174+
'bundles/org.eclipse.swt/Eclipse SWT PI/common/org/eclipse/swt/internal/Library.java'
175+
sed -i -e "s/rev=${versions.rev}/rev=${versions.new_rev}/g" \
176+
'bundles/org.eclipse.swt/Eclipse SWT/common/library/make_common.mak'
177+
"""
178+
for(ws in allWS) {
179+
if (NATIVES_CHANGED.contains(ws)) {
180+
sh """
167181
# Delete native binaries to be replaced by subsequent binaries build
168-
rm binaries/org.eclipse.swt.gtk.*/libswt-*.so
169-
rm binaries/org.eclipse.swt.win32.*/swt-*.dll
170-
rm binaries/org.eclipse.swt.cocoa.*/libswt-*.jnilib
171-
172-
echo "Incrementing version from ${swt_version} to ${new_version}; new comma_ver=${new_comma_ver}"
173-
174-
libraryFile='bundles/org.eclipse.swt/Eclipse SWT PI/common/org/eclipse/swt/internal/Library.java'
175-
sed -i -e "s/REVISION = ${rev}/REVISION = ${new_rev}/g" "$libraryFile"
176-
177-
commonMakeFile='bundles/org.eclipse.swt/Eclipse SWT/common/library/make_common.mak'
178-
sed -i -e "s/rev=${rev}/rev=${new_rev}/g" "$commonMakeFile"
179-
sed -i -e "s/comma_ver=${comma_ver}/comma_ver=${new_comma_ver}/g" "$commonMakeFile"
180-
'''
182+
rm binaries/org.eclipse.swt.${ws}.*/${libraryFilePattern[ws]}
183+
"""
184+
} else {
185+
// Just rename existing native library files to new revision instead of rebuilding them
186+
sh """
187+
for f in binaries/org.eclipse.swt.${ws}.*/${libraryFilePattern[ws]}; do
188+
mv "\$f" "\$(echo \$f | sed 's/-${ws}-${versions.swt_version}/-${ws}-${versions.new_version}/g')"
189+
done
190+
"""
191+
}
181192
}
182193
// Collect SWT-native's sources
183194
dir('bundles/org.eclipse.swt') {
184-
for (ws in ['cocoa', 'gtk', 'win32']) {
195+
for (ws in NATIVES_CHANGED) {
185196
sh "java -Dws=${ws} build-scripts/CollectSources.java -nativeSources 'target/natives-build-temp/${ws}'"
186197
dir("target/natives-build-temp/${ws}") {
187198
stash(name:"swt.binaries.sources.${ws}")
@@ -213,29 +224,35 @@ pipeline {
213224
'win32.win32.x86_64'
214225
}
215226
}
227+
when {
228+
expression {
229+
def (ws, os, arch) = env.PLATFORM.split('\\.')
230+
return NATIVES_CHANGED.any{ w -> ws.startsWith(w)} // handle also dedicated gtk4 build
231+
}
232+
}
216233
stages {
217-
stage('Build SWT-natives') {
234+
stage('Initiate native build') {
218235
options {
219236
timeout(time: 120, unit: 'MINUTES') // Some build agents are rare and it might take awhile until they are available.
220237
}
221238
steps {
222239
script {
223240
def (ws, os, arch) = env.PLATFORM.split('\\.')
224-
dir("jdk-download-${os}.${arch}") {
225-
// Fetch the JDK, which provides the C header-files and shared native libaries, against which the natives are build.
241+
dir("jdk-download-${ws}.${arch}") {
242+
// Fetch the JDK, which provides the C header-files and shared native libraries, against which the natives are build.
226243
sh "curl ${getNativeJdkUrl(os, arch)} | tar -xzf - include/ lib/"
227-
stash name:"jdk.resources.${os}.${arch}", includes: "include/,lib/"
244+
stash name:"jdk.resources.${ws}.${arch}", includes: "include/,lib/"
228245
deleteDir()
229246
}
230247
runOnNativeBuildAgent("${PLATFORM}") {
231248
cleanWs() // Workspace is not cleaned up by default, so we do it explicitly
232249
echo "OS: ${os}, ARCH: ${arch}"
233250
unstash "swt.binaries.sources.${ws == 'gtk4' ? 'gtk' : ws }"
234251
dir('jdk.resources') {
235-
unstash "jdk.resources.${os}.${arch}"
252+
unstash "jdk.resources.${ws}.${arch}"
236253
}
237254
withEnv(['MODEL=' + arch, "OUTPUT_DIR=${WORKSPACE}/libs", "SWT_JAVA_HOME=${WORKSPACE}/jdk.resources"]) {
238-
if (isUnix()){
255+
if (isUnix()) {
239256
sh '''#!/bin/bash -x
240257
mkdir libs
241258
if [[ ${PLATFORM} == gtk.linux.* ]]; then
@@ -344,12 +361,16 @@ pipeline {
344361
}
345362
post {
346363
always {
347-
junit 'eclipse.platform.swt/tests/*.test*/target/surefire-reports/*.xml'
348-
archiveArtifacts artifacts: '**/*.log,*/binaries/*/target/*.jar', excludes: '**/*-sources.jar'
364+
junit allowEmptyResults: true, testResults: 'eclipse.platform.swt/tests/*.test*/target/surefire-reports/*.xml'
365+
archiveArtifacts allowEmptyArchive: true, artifacts: '**/*.log,*/binaries/*/target/*.jar', excludes: '**/*-sources.jar'
349366
discoverGitReferenceBuild referenceJob: 'eclipse.platform.swt/master'
350367
// To accept unstable builds (test errors or new warnings introduced by third party changes) as reference using "ignoreQualityGate:true"
351-
recordIssues publishAllIssues: true, ignoreQualityGate:true, tools: [eclipse(name: 'Compiler and API Tools', pattern: '**/target/compilelogs/*.xml'), javaDoc()], qualityGates: [[threshold: 1, type: 'DELTA', unstable: true]]
352-
recordIssues publishAllIssues: true, ignoreQualityGate:true, tool: mavenConsole(), qualityGates: [[threshold: 1, type: 'DELTA_ERROR', unstable: true]]
368+
recordIssues enabledForFailure: true, publishAllIssues: true, ignoreQualityGate: true, tools: [
369+
eclipse(name: 'Compiler', pattern: '**/target/compilelogs/*.xml'),
370+
issues(name: 'API Tools', id: 'apitools', pattern: '**/target/apianalysis/*.xml'),
371+
javaDoc()
372+
], qualityGates: [[threshold: 1, type: 'DELTA', unstable: true]]
373+
recordIssues enabledForFailure: true, publishAllIssues: true, ignoreQualityGate:true, tool: mavenConsole(), qualityGates: [[threshold: 1, type: 'DELTA_ERROR', unstable: true]]
353374
}
354375
}
355376
}

README.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
[![SWT Matrix Build](https://github.com/eclipse-platform/eclipse.platform.swt/actions/workflows/maven.yml/badge.svg)](https://github.com/eclipse-platform/eclipse.platform.swt/actions/workflows/maven.yml) ![SWT Matrix Tests](https://gist.githubusercontent.com/eclipse-releng-bot/78d110a601baa4ef777ccb472f584038/raw/71510599eb84e852f3e135aa7a3ddf33854ca716/badge.svg)
1+
[![SWT Matrix Build](https://github.com/eclipse-platform/eclipse.platform.swt/actions/workflows/maven.yml/badge.svg)](https://github.com/eclipse-platform/eclipse.platform.swt/actions/workflows/maven.yml)
2+
[![Publish Unit Test Results](https://github.com/eclipse-platform/eclipse.platform.swt/actions/workflows/junit.yml/badge.svg)](https://github.com/eclipse-platform/eclipse.platform.swt/actions/workflows/junit.yml)
3+
![SWT Matrix Tests](https://gist.githubusercontent.com/eclipse-releng-bot/78d110a601baa4ef777ccb472f584038/raw/71510599eb84e852f3e135aa7a3ddf33854ca716/badge.svg)
4+
[![License](https://img.shields.io/github/license/eclipse-platform/eclipse.platform)](https://github.com/eclipse-platform/eclipse.platform.swt/blob/master/LICENSE)
25

36
# About
47

@@ -122,7 +125,7 @@ SWT used to track ongoing development and issues in Bugzilla .
122125

123126
## Create a New Bug
124127

125-
You can register bugs and feature requests in the Github Issue Tracker. Remember that contributions are always welcome!
128+
You can register bugs and feature requests in the GitHub Issue Tracker. Remember that contributions are always welcome!
126129
- [View existing SWT issues](https://github.com/eclipse-platform/eclipse.platform.swt/issues)
127130
- [New SWT issue](https://github.com/eclipse-platform/eclipse.platform.swt/issues/new)
128131

binaries/org.eclipse.swt.cocoa.macosx.aarch64/.settings/.api_filters

+15-1
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,14 @@
231231
<message_argument value="VerifyKeyListener"/>
232232
</message_arguments>
233233
</filter>
234+
</resource>
235+
<resource path="Eclipse SWT/common/org/eclipse/swt/graphics/ImageGcDrawer.java" type="org.eclipse.swt.graphics.ImageGcDrawer">
236+
<filter id="404000815">
237+
<message_arguments>
238+
<message_argument value="org.eclipse.swt.graphics.ImageGcDrawer"/>
239+
<message_argument value="getGcStyle()"/>
240+
</message_arguments>
241+
</filter>
234242
</resource>
235243
<resource path="Eclipse SWT Drag and Drop/common/org/eclipse/swt/dnd/DragSourceListener.java" type="org.eclipse.swt.dnd.DragSourceListener">
236244
<filter id="576720909">
@@ -463,12 +471,18 @@
463471
<message_argument value="IE"/>
464472
</message_arguments>
465473
</filter>
474+
<filter id="336658481">
475+
<message_arguments>
476+
<message_argument value="org.eclipse.swt.SWT"/>
477+
<message_argument value="NO_SEARCH"/>
478+
</message_arguments>
479+
</filter>
466480
</resource>
467481
<resource path="META-INF/MANIFEST.MF">
468482
<filter id="926941240">
469483
<message_arguments>
484+
<message_argument value="3.130.0"/>
470485
<message_argument value="3.129.0"/>
471-
<message_argument value="3.128.0"/>
472486
</message_arguments>
473487
</filter>
474488
</resource>

binaries/org.eclipse.swt.cocoa.macosx.aarch64/META-INF/MANIFEST.MF

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Fragment-Host: org.eclipse.swt;bundle-version="[3.128.0,4.0.0)"
33
Bundle-Name: %fragmentName
44
Bundle-Vendor: %providerName
55
Bundle-SymbolicName: org.eclipse.swt.cocoa.macosx.aarch64; singleton:=true
6-
Bundle-Version: 3.129.0.qualifier
6+
Bundle-Version: 3.130.0.qualifier
77
Bundle-ManifestVersion: 2
88
Bundle-Localization: fragment
99
Export-Package:

binaries/org.eclipse.swt.cocoa.macosx.aarch64/libswt-awt-cocoa-4968r13.jnilib

-3
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:482ef61ea92cd898c9a911b814d313e2e81d30608a74c8fea22e7c3caca5f223
3+
size 51952

binaries/org.eclipse.swt.cocoa.macosx.aarch64/libswt-cocoa-4968r13.jnilib

-3
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:ad10c670a164d2910ebc0320d804ee74573d913feca24eba0d18c54227d30291
3+
size 576624

binaries/org.eclipse.swt.cocoa.macosx.aarch64/libswt-pi-cocoa-4968r13.jnilib

-3
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:e47cc5179faccfca9a63e8f5974652f83e4bef28f93b8e72d299fbdcc38f36ca
3+
size 298864

binaries/org.eclipse.swt.cocoa.macosx.x86_64/.settings/.api_filters

+15-1
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,14 @@
231231
<message_argument value="VerifyKeyListener"/>
232232
</message_arguments>
233233
</filter>
234+
</resource>
235+
<resource path="Eclipse SWT/common/org/eclipse/swt/graphics/ImageGcDrawer.java" type="org.eclipse.swt.graphics.ImageGcDrawer">
236+
<filter id="404000815">
237+
<message_arguments>
238+
<message_argument value="org.eclipse.swt.graphics.ImageGcDrawer"/>
239+
<message_argument value="getGcStyle()"/>
240+
</message_arguments>
241+
</filter>
234242
</resource>
235243
<resource path="Eclipse SWT Drag and Drop/common/org/eclipse/swt/dnd/DragSourceListener.java" type="org.eclipse.swt.dnd.DragSourceListener">
236244
<filter id="576720909">
@@ -463,12 +471,18 @@
463471
<message_argument value="IE"/>
464472
</message_arguments>
465473
</filter>
474+
<filter id="336658481">
475+
<message_arguments>
476+
<message_argument value="org.eclipse.swt.SWT"/>
477+
<message_argument value="NO_SEARCH"/>
478+
</message_arguments>
479+
</filter>
466480
</resource>
467481
<resource path="META-INF/MANIFEST.MF">
468482
<filter id="926941240">
469483
<message_arguments>
484+
<message_argument value="3.130.0"/>
470485
<message_argument value="3.129.0"/>
471-
<message_argument value="3.128.0"/>
472486
</message_arguments>
473487
</filter>
474488
</resource>

binaries/org.eclipse.swt.cocoa.macosx.x86_64/META-INF/MANIFEST.MF

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Fragment-Host: org.eclipse.swt;bundle-version="[3.128.0,4.0.0)"
33
Bundle-Name: %fragmentName
44
Bundle-Vendor: %providerName
55
Bundle-SymbolicName: org.eclipse.swt.cocoa.macosx.x86_64; singleton:=true
6-
Bundle-Version: 3.129.0.qualifier
6+
Bundle-Version: 3.130.0.qualifier
77
Bundle-ManifestVersion: 2
88
Bundle-Localization: fragment
99
Export-Package:

0 commit comments

Comments
 (0)