diff --git a/internal/documentation/docs/pages/Builder.md b/internal/documentation/docs/pages/Builder.md
index 69d1211bd17..5ac7c647c48 100644
--- a/internal/documentation/docs/pages/Builder.md
+++ b/internal/documentation/docs/pages/Builder.md
@@ -35,7 +35,7 @@ All available standard tasks are documented under **API -> @ui5/builder -> tasks
| [executeJsdocSdkTransformation](../api/module-@ui5_builder_tasks_jsdoc_executeJsdocSdkTransformation) | | | *disabled* 1 | |
| [minify](../api/module-@ui5_builder_tasks_minify) | enabled | enabled | enabled | |
| [generateFlexChangesBundle](../api/module-@ui5_builder_tasks_bundlers_generateFlexChangesBundle) | enabled | enabled | enabled | |
-| [generateLibraryManifest](../api/module-@ui5_builder_tasks_generateLibraryManifest) | | | enabled | |
+| [generateLibraryManifest](../api/module-@ui5_builder_tasks_generateLibraryManifest) | | | *disabled* 7 | |
| [enhanceManifest](../api/module-@ui5_builder_tasks_enhanceManifest) | enabled | enabled | enabled | |
| [generateComponentPreload](../api/module-@ui5_builder_tasks_bundlers_generateComponentPreload) | enabled | enabled | *disabled* 2 | |
| [generateLibraryPreload](../api/module-@ui5_builder_tasks_bundlers_generateLibraryPreload) | | | enabled | |
@@ -58,7 +58,8 @@ All available standard tasks are documented under **API -> @ui5/builder -> tasks
3 Enabled in `self-contained` build, which disables `generateComponentPreload` and `generateLibraryPreload`
4 Enabled for projects defining a [bundle configuration](./Configuration.md#custom-bundling)
5 Can be enabled for framework projects via the `includeTask` option. For other projects, this task is skipped
-6 Disabled for the server due to a corresponding middleware producing the same output
+6 Disabled for the server due to a corresponding middleware producing the same output
+7 Enabled for Specification Version 4.0 and lower, and for framework projects. For other projects using Specification Version 5.0 and higher, this task is skipped
### minify
diff --git a/internal/documentation/docs/pages/Configuration.md b/internal/documentation/docs/pages/Configuration.md
index 85e3884794f..425f137374d 100644
--- a/internal/documentation/docs/pages/Configuration.md
+++ b/internal/documentation/docs/pages/Configuration.md
@@ -812,6 +812,10 @@ Version | UI5 CLI Release
### Specification Version 5.0
+**Breaking changes:**
+
+- The `generateLibraryManifest` build task is no longer executed by default for projects of type `library`. Libraries must provide a `manifest.json` directly in their source directory. See [Migrate to v5: generateLibraryManifest Task No Longer Executed](../updates/migrate-v5.md#generatelibrarymanifest-task-no-longer-executed) for details.
+
**Features:**
- Adds support for the new [`component`](./Project.md#component) project type for developing UI5 components — including application, reusable UI, and faceless components — which, unlike `application`-type projects, are served under their own namespace so multiple can coexist in one environment
diff --git a/internal/documentation/docs/updates/migrate-v5.md b/internal/documentation/docs/updates/migrate-v5.md
index b3fbe518ba3..01a4590f584 100644
--- a/internal/documentation/docs/updates/migrate-v5.md
+++ b/internal/documentation/docs/updates/migrate-v5.md
@@ -43,6 +43,23 @@ UI5 CLI 5.x introduces **Specification Version 5.0**, which enables the new Comp
Projects using older **Specification Versions** are expected to be **fully compatible with UI5 CLI v5**.
+## generateLibraryManifest Task No Longer Executed
+
+::: info Specification Version 5.0 only
+This change only applies to library projects that upgrade their `specVersion` to `5.0` in `ui5.yaml`. Projects on **Specification Version 4.0 and lower are not affected**.
+:::
+
+With **Specification Version 5.0**, the [`generateLibraryManifest`](../api/module-@ui5_builder_tasks_generateLibraryManifest) build task is no longer executed. Libraries must provide a `manifest.json` directly in their source directory.
+
+**Action required** when upgrading a library project to Specification Version 5.0:
+
+- Ensure your library has a hand-crafted `manifest.json` in its source directory.
+- If no `manifest.json` is present, the build will no longer generate one automatically.
+
+::: tip
+To see which standard tasks are executed for each project type, check out the [Standard Tasks](../pages/Builder#standard-tasks) table in the UI5 Builder page.
+:::
+
## Build Cache
UI5 CLI v5 introduces **builds with caching** for both the `ui5 build` and `ui5 serve` commands. This fundamental architectural change significantly improves build performance by reusing cached results from previous builds. It also simplifies development with the server by making most custom middleware obsolete.
diff --git a/packages/project/lib/build/definitions/library.js b/packages/project/lib/build/definitions/library.js
index a01df0e856f..2229d0b9815 100644
--- a/packages/project/lib/build/definitions/library.js
+++ b/packages/project/lib/build/definitions/library.js
@@ -95,7 +95,12 @@ export default function({project, taskUtil, getTask}) {
}
});
- tasks.set("generateLibraryManifest", {});
+ // For specVersion 5.0+, only execute for framework libraries
+ if (project.getSpecVersion().lt("5.0") || project.isFrameworkProject()) {
+ tasks.set("generateLibraryManifest", {});
+ } else {
+ tasks.set("generateLibraryManifest", {taskFunction: null});
+ }
tasks.set("enhanceManifest", {});
diff --git a/packages/project/test/lib/build/TaskRunner.js b/packages/project/test/lib/build/TaskRunner.js
index 2dd78996b34..c06859aa01a 100644
--- a/packages/project/test/lib/build/TaskRunner.js
+++ b/packages/project/test/lib/build/TaskRunner.js
@@ -27,7 +27,8 @@ function getMockProject(type) {
getMinificationExcludes: emptyarray,
getSpecVersion: () => {
return {
- gte: () => false
+ gte: () => false,
+ lt: () => true
};
},
getComponentPreloadPaths: () => [
diff --git a/packages/project/test/lib/build/definitions/library.js b/packages/project/test/lib/build/definitions/library.js
index 5f839d10b6e..22eaf7fb8bd 100644
--- a/packages/project/test/lib/build/definitions/library.js
+++ b/packages/project/test/lib/build/definitions/library.js
@@ -17,7 +17,8 @@ function getMockProject() {
getSpecVersion: () => {
return {
toString: () => "2.6",
- gte: () => true
+ gte: () => true,
+ lt: () => true
};
},
getMinificationExcludes: emptyarray,
@@ -187,7 +188,8 @@ test("Standard build with legacy spec version", (t) => {
project.getSpecVersion = () => {
return {
toString: () => "0.1",
- gte: () => false
+ gte: () => false,
+ lt: () => true
};
};
@@ -507,7 +509,8 @@ test("Minification excludes not applied for legacy specVersion", (t) => {
project.getSpecVersion = () => {
return {
toString: () => "2.5",
- gte: () => false
+ gte: () => false,
+ lt: () => true
};
};
project.getMinificationExcludes = () => ["**.html"];
@@ -639,6 +642,42 @@ test("buildThemes: Project is not root", (t) => {
}
}, "Correct buildThemes task definition");
});
+test("generateLibraryManifest: specVersion 5.0, non-framework project", (t) => {
+ const {project, taskUtil, getTask} = t.context;
+
+ project.getSpecVersion = () => {
+ return {
+ toString: () => "5.0",
+ gte: () => true,
+ lt: () => false
+ };
+ };
+ project.isFrameworkProject = () => false;
+
+ const tasks = library({project, taskUtil, getTask});
+
+ t.deepEqual(tasks.get("generateLibraryManifest"), {taskFunction: null},
+ "generateLibraryManifest is skipped for non-framework libraries on specVersion 5.0");
+});
+
+test("generateLibraryManifest: specVersion 5.0, framework project", (t) => {
+ const {project, taskUtil, getTask} = t.context;
+
+ project.getSpecVersion = () => {
+ return {
+ toString: () => "5.0",
+ gte: () => true,
+ lt: () => false
+ };
+ };
+ project.isFrameworkProject = () => true;
+
+ const tasks = library({project, taskUtil, getTask});
+
+ t.deepEqual(tasks.get("generateLibraryManifest"), {},
+ "generateLibraryManifest runs for framework libraries on specVersion 5.0");
+});
+
test("buildThemes: CSS Variables enabled", (t) => {
const {project, taskUtil, getTask} = t.context;
taskUtil.getBuildOption.returns(true);