Add support for /product-services partition.
This CL is largely and adaptation of
Ie996def20e25dc1afe0c74af2096af844934b2dc
Bug: 80741439
Test: Successfully built product-services.img with one module in it, and
flashed on device. Also successfully built image with
/system/product-services and no dedicated /product-services partition.
Change-Id: I1046dfe19bf874da929c9131b76a1f85422fbb80
Merged-In: I1046dfe19bf874da929c9131b76a1f85422fbb80
diff --git a/init/init.cpp b/init/init.cpp
index 6569871..73194bd 100644
--- a/init/init.cpp
+++ b/init/init.cpp
@@ -119,6 +119,9 @@
if (!parser.ParseConfig("/product/etc/init")) {
late_import_paths.emplace_back("/product/etc/init");
}
+ if (!parser.ParseConfig("/product-services/etc/init")) {
+ late_import_paths.emplace_back("/product-services/etc/init");
+ }
if (!parser.ParseConfig("/odm/etc/init")) {
late_import_paths.emplace_back("/odm/etc/init");
}
diff --git a/init/property_service.cpp b/init/property_service.cpp
index d1c427d..c0d811f 100644
--- a/init/property_service.cpp
+++ b/init/property_service.cpp
@@ -691,6 +691,7 @@
}
}
load_properties_from_file("/product/build.prop", NULL);
+ load_properties_from_file("/product-services/build.prop", NULL);
load_properties_from_file("/odm/default.prop", NULL);
load_properties_from_file("/vendor/default.prop", NULL);