Ajusta plugins para Java 17 e alinha pré-requisitos de JDK.

Permite compilar chat e screencast com JDK 21+ na sala; documentação e check do script citam Java 17 como mínimo.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Gabriel Felipe Souza SantosandCursor committed 2026-10-27 11:15:58 -03:00
1 parent eeb1936f6d
commit 6c1ce9a6ec
7 files changed
+20 -11

No files matched your search

+2 -2
View File
@@ -73,12 +73,12 @@ O núcleo carrega **todos os `*.jar`** em `PITIUPI_HOME/plugins`. Detalhes: [pit
| Ferramenta | Uso |
| --- | --- |
| **JDK** com `javac` | Compilação (OpenJDK **25** recomendado; núcleo Java 17) |
| **JDK** com `javac` | Compilação **Java 17+** (núcleo e plugins usam bytecode 17) |
| **Apache Ant** | Módulos NetBeans |
| **python3** | Script `scripts/pitiupi.sh` (ler o catálogo) |
```bash
sudo apt install openjdk-25-jdk ant
sudo apt install openjdk-21-jdk ant
./scripts/pitiupi.sh check
cd pitiupi && ant test # testes JUnit do núcleo
```
+3 -2
View File
@@ -2,13 +2,14 @@
## Pré-requisitos
- **JDK completo** (`java` e `javac`) — OpenJDK 25 recomendado; o núcleo usa `javac.source/target=17`, plugins Ant usam 25.
- **JDK completo** (`java` e `javac`) — **Java 17 ou superior** (17, 21 ou 25). Núcleo e plugins compilam com `javac.source/target=17`.
- Apache Ant (`pitiupi`, `plugins/chat`, `plugins/screencast`)
Ubuntu / WSL:
```bash
sudo apt install openjdk-25-jdk ant
sudo apt install openjdk-21-jdk ant
# ou: openjdk-17-jdk
which javac ant
```
+2 -2
View File
@@ -3,8 +3,8 @@
| Módulo | Build | Java |
| --- | --- | --- |
| `pitiupi` | Ant | 17 |
| `plugins/chat` | Ant | 25 |
| `plugins/screencast` | Ant | 25 |
| `plugins/chat` | Ant | 17 |
| `plugins/screencast` | Ant | 17 |
```bash
cd pitiupi && ant jar
+2 -2
View File
@@ -47,8 +47,8 @@ javac.modulepath=
javac.processormodulepath=
javac.processorpath=\
${javac.classpath}
javac.source=25
javac.target=25
javac.source=17
javac.target=17
javac.test.classpath=\
${javac.classpath}:\
${build.classes.dir}
+1 -1
View File
@@ -1,3 +1,3 @@
<project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_25" project-jdk-name="openjdk-26" project-jdk-type="JavaSDK" />
<component name="ProjectRootManager" version="2" languageLevel="JDK_17" project-jdk-name="openjdk-26" project-jdk-type="JavaSDK" />
</project>
@@ -45,8 +45,8 @@ javac.modulepath=
javac.processormodulepath=
javac.processorpath=\
${javac.classpath}
javac.source=25
javac.target=25
javac.source=17
javac.target=17
javac.test.classpath=\
${javac.classpath}:\
${build.classes.dir}
+8
View File
@@ -240,6 +240,14 @@ check_tools() {
registry_python validate
printf 'OK plugins.registry.json\n'
fi
if command -v javac >/dev/null 2>&1; then
local javac_major
javac_major="$(javac -version 2>&1 | grep -oE '[0-9]+' | head -1)"
if [[ -n "${javac_major}" && "${javac_major}" -lt 17 ]]; then
printf 'ERRO: javac precisa ser Java 17 ou superior (atual: %s)\n' "$(javac -version 2>&1)" >&2
ok=1
fi
fi
return "${ok}"
}