Loading fs_mgr/liblp/Android.bp +22 −16 Original line number Diff line number Diff line Loading @@ -14,6 +14,16 @@ // limitations under the License. // liblp_lib_deps = [ "libbase", "liblog", "libcrypto", "libcrypto_utils", "libsparse", "libext4_utils", "libz", ] cc_library { name: "liblp", host_supported: true, Loading @@ -30,15 +40,7 @@ cc_library { "utility.cpp", "writer.cpp", ], shared_libs: [ "libbase", "liblog", "libcrypto", "libcrypto_utils", "libsparse", "libext4_utils", "libz", ], shared_libs: liblp_lib_deps, target: { windows: { enabled: true, Loading @@ -53,24 +55,28 @@ cc_library { } cc_test { name: "liblp_test", name: "liblp_test_static", defaults: ["fs_mgr_defaults"], cppflags: [ "-Wno-unused-parameter", ], static_libs: [ "libgmock", ], shared_libs: [ "liblp", "libbase", "libfs_mgr", "libsparse", ], "liblp", ] + liblp_lib_deps, stl: "libc++_static", srcs: [ "builder_test.cpp", "io_test.cpp", "test_partition_opener.cpp", "utility_test.cpp", ], target: { android: { static_libs: [ "libcutils", ], }, }, } fs_mgr/liblp/AndroidTest.xml +2 −2 Original line number Diff line number Diff line Loading @@ -21,8 +21,8 @@ </target_preparer> <test class="com.android.tradefed.testtype.VtsMultiDeviceTest"> <option name="test-module-name" value="VtsKernelLiblpTest"/> <option name="binary-test-source" value="_32bit::DATA/nativetest/liblp_test/liblp_test" /> <option name="binary-test-source" value="_64bit::DATA/nativetest64/liblp_test/liblp_test" /> <option name="binary-test-source" value="_32bit::DATA/nativetest/liblp_test_static/liblp_test_static" /> <option name="binary-test-source" value="_64bit::DATA/nativetest64/liblp_test_static/liblp_test_static" /> <option name="binary-test-type" value="gtest"/> <option name="test-timeout" value="1m"/> <option name="precondition-first-api-level" value="29" /> Loading init/property_service.cpp +7 −1 Original line number Diff line number Diff line Loading @@ -642,8 +642,14 @@ static void LoadProperties(char* data, const char* filter, const char* filename, while (isspace(*key)) key++; } load_properties_from_file(fn, key, properties); std::string raw_filename(fn); std::string expanded_filename; if (!expand_props(raw_filename, &expanded_filename)) { LOG(ERROR) << "Could not expand filename '" << raw_filename << "'"; continue; } load_properties_from_file(expanded_filename.c_str(), key, properties); } else { value = strchr(key, '='); if (!value) continue; Loading libprocessgroup/cgroup_map.cpp +2 −3 Original line number Diff line number Diff line Loading @@ -70,8 +70,8 @@ bool CgroupController::HasValue() const { bool CgroupController::IsUsable() const { if (!HasValue()) return false; uint32_t flags = ACgroupController_getFlags(controller_); return (flags & CGROUPRC_CONTROLLER_FLAG_MOUNTED) != 0; static bool enabled = (access(GetProcsFilePath("", 0, 0).c_str(), F_OK) == 0); return enabled; } std::string CgroupController::GetTasksFilePath(const std::string& rel_path) const { Loading Loading @@ -160,7 +160,6 @@ void CgroupMap::Print() const { const ACgroupController* controller = ACgroupFile_getController(i); LOG(INFO) << "\t" << ACgroupController_getName(controller) << " ver " << ACgroupController_getVersion(controller) << " path " << ACgroupController_getFlags(controller) << " flags " << ACgroupController_getPath(controller); } } Loading libprocessgroup/cgrouprc/cgroup_controller.cpp +0 −5 Original line number Diff line number Diff line Loading @@ -27,11 +27,6 @@ uint32_t ACgroupController_getVersion(const ACgroupController* controller) { return controller->version(); } uint32_t ACgroupController_getFlags(const ACgroupController* controller) { CHECK(controller != nullptr); return controller->flags(); } const char* ACgroupController_getName(const ACgroupController* controller) { CHECK(controller != nullptr); return controller->name(); Loading Loading
fs_mgr/liblp/Android.bp +22 −16 Original line number Diff line number Diff line Loading @@ -14,6 +14,16 @@ // limitations under the License. // liblp_lib_deps = [ "libbase", "liblog", "libcrypto", "libcrypto_utils", "libsparse", "libext4_utils", "libz", ] cc_library { name: "liblp", host_supported: true, Loading @@ -30,15 +40,7 @@ cc_library { "utility.cpp", "writer.cpp", ], shared_libs: [ "libbase", "liblog", "libcrypto", "libcrypto_utils", "libsparse", "libext4_utils", "libz", ], shared_libs: liblp_lib_deps, target: { windows: { enabled: true, Loading @@ -53,24 +55,28 @@ cc_library { } cc_test { name: "liblp_test", name: "liblp_test_static", defaults: ["fs_mgr_defaults"], cppflags: [ "-Wno-unused-parameter", ], static_libs: [ "libgmock", ], shared_libs: [ "liblp", "libbase", "libfs_mgr", "libsparse", ], "liblp", ] + liblp_lib_deps, stl: "libc++_static", srcs: [ "builder_test.cpp", "io_test.cpp", "test_partition_opener.cpp", "utility_test.cpp", ], target: { android: { static_libs: [ "libcutils", ], }, }, }
fs_mgr/liblp/AndroidTest.xml +2 −2 Original line number Diff line number Diff line Loading @@ -21,8 +21,8 @@ </target_preparer> <test class="com.android.tradefed.testtype.VtsMultiDeviceTest"> <option name="test-module-name" value="VtsKernelLiblpTest"/> <option name="binary-test-source" value="_32bit::DATA/nativetest/liblp_test/liblp_test" /> <option name="binary-test-source" value="_64bit::DATA/nativetest64/liblp_test/liblp_test" /> <option name="binary-test-source" value="_32bit::DATA/nativetest/liblp_test_static/liblp_test_static" /> <option name="binary-test-source" value="_64bit::DATA/nativetest64/liblp_test_static/liblp_test_static" /> <option name="binary-test-type" value="gtest"/> <option name="test-timeout" value="1m"/> <option name="precondition-first-api-level" value="29" /> Loading
init/property_service.cpp +7 −1 Original line number Diff line number Diff line Loading @@ -642,8 +642,14 @@ static void LoadProperties(char* data, const char* filter, const char* filename, while (isspace(*key)) key++; } load_properties_from_file(fn, key, properties); std::string raw_filename(fn); std::string expanded_filename; if (!expand_props(raw_filename, &expanded_filename)) { LOG(ERROR) << "Could not expand filename '" << raw_filename << "'"; continue; } load_properties_from_file(expanded_filename.c_str(), key, properties); } else { value = strchr(key, '='); if (!value) continue; Loading
libprocessgroup/cgroup_map.cpp +2 −3 Original line number Diff line number Diff line Loading @@ -70,8 +70,8 @@ bool CgroupController::HasValue() const { bool CgroupController::IsUsable() const { if (!HasValue()) return false; uint32_t flags = ACgroupController_getFlags(controller_); return (flags & CGROUPRC_CONTROLLER_FLAG_MOUNTED) != 0; static bool enabled = (access(GetProcsFilePath("", 0, 0).c_str(), F_OK) == 0); return enabled; } std::string CgroupController::GetTasksFilePath(const std::string& rel_path) const { Loading Loading @@ -160,7 +160,6 @@ void CgroupMap::Print() const { const ACgroupController* controller = ACgroupFile_getController(i); LOG(INFO) << "\t" << ACgroupController_getName(controller) << " ver " << ACgroupController_getVersion(controller) << " path " << ACgroupController_getFlags(controller) << " flags " << ACgroupController_getPath(controller); } } Loading
libprocessgroup/cgrouprc/cgroup_controller.cpp +0 −5 Original line number Diff line number Diff line Loading @@ -27,11 +27,6 @@ uint32_t ACgroupController_getVersion(const ACgroupController* controller) { return controller->version(); } uint32_t ACgroupController_getFlags(const ACgroupController* controller) { CHECK(controller != nullptr); return controller->flags(); } const char* ACgroupController_getName(const ACgroupController* controller) { CHECK(controller != nullptr); return controller->name(); Loading