change by zjq

This commit is contained in:
zxstty 2023-12-06 16:06:05 +08:00
parent dd19f444da
commit 5c75baf759
9 changed files with 73 additions and 15914 deletions

View File

@ -1,6 +1,6 @@
From feaa1b46fbd01dc2c0bfda5c6ef1e5a8d7f7158e Mon Sep 17 00:00:00 2001
From 8a9758f8478bd67980cbadaf318ea059d472ff53 Mon Sep 17 00:00:00 2001
From: heppen <hepeng68@huawei.com>
Date: Tue, 1 Aug 2023 16:52:49 +0800
Date: Mon, 20 Nov 2023 11:50:29 +0800
Subject: [PATCH] remove useless dependencies
---
@ -11,12 +11,12 @@ Subject: [PATCH] remove useless dependencies
frameworks/native/rdb/src/rdb_store_impl.cpp | 2 +-
frameworks/native/rdb/src/security_policy.cpp | 12 ++++++----
.../native/rdb/src/sqlite_sql_builder.cpp | 4 ++--
interfaces/inner_api/rdb/BUILD.gn | 4 ++--
interfaces/inner_api/rdb/BUILD.gn | 5 ++--
.../rdb/include/abs_shared_result_set.h | 2 +-
.../rdb_data_ability_adapter/BUILD.gn | 12 +++++-----
.../inner_api/rdb_data_share_adapter/BUILD.gn | 16 ++++++-------
test/native/rdb_data_share_adapter/BUILD.gn | 2 +-
12 files changed, 38 insertions(+), 54 deletions(-)
12 files changed, 38 insertions(+), 55 deletions(-)
diff --git a/bundle.json b/bundle.json
index f6b926a..d837179 100644
@ -195,10 +195,18 @@ index 2b0ddd1..d992755 100644
}
diff --git a/interfaces/inner_api/rdb/BUILD.gn b/interfaces/inner_api/rdb/BUILD.gn
index 2c0f223..53dd9c6 100644
index 2c0f223..603e3dc 100644
--- a/interfaces/inner_api/rdb/BUILD.gn
+++ b/interfaces/inner_api/rdb/BUILD.gn
@@ -147,8 +147,8 @@ ohos_shared_library("native_rdb") {
@@ -139,7 +139,6 @@ ohos_shared_library("native_rdb") {
]
public_deps = [
"${relational_store_innerapi_path}/appdatafwk:native_appdatafwk",
- "//base/security/huks/frameworks/huks_standard/main/os_dependency:libhuks_os_dependency_standard_static",
"//foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb:distributeddb",
"//foundation/distributeddatamgr/kv_store/interfaces/innerkits/distributeddata:distributeddata_inner",
]
@@ -147,8 +146,8 @@ ohos_shared_library("native_rdb") {
external_deps = [
"c_utils:utils",
"hilog_native:libhilog",

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,93 +1,98 @@
%define debug_package %{nil}
%global oh_version OpenHarmony-v3.2-Release
%global relational_store_dir %{_builddir}/foundation/distributeddatamgr/
%global distributeddata_dir %{_builddir}/foundation/distributeddatamgr/
%global build_opt /opt/distributed-middleware-build
%global bundle_dir %{build_opt}/openeuler/compiler_gn/foundation/distributeddatamgr/relational_store
%global appdatafwk_dir %{bundle_dir}/interfaces/inner_api/appdatafwk
%global dataability_dir %{bundle_dir}/interfaces/inner_api/dataability
%global share_adapter_dir %{bundle_dir}/interfaces/inner_api/rdb_data_share_adapter
%global rdb_dir %{bundle_dir}/interfaces/inner_api/rdb
Name: distributeddatamgr_relational_store
Version: 1.0.0
Release: 2
Summary: Local Data Management
Release: 3
Summary: Local Relational Data Management from OpenHarmony
License: Apache-2.0
Url: https://gitee.com/openharmony/distributeddatamgr_relational_store
Source0: https://gitee.com/openharmony/distributeddatamgr_relational_store/repository/archive/OpenHarmony-v3.2-Release.tar.gz#/distributeddatamgr_relational_store-OpenHarmony-v3.2-Release.tar.gz
Source1: bundle.json
Source2: BUILD.gn.appdatafwk
Source3: BUILD.gn.dataability
Source4: BUILD.gn.share.adapter
Source5: BUILD.gn.rdb
Patch0: 0001-remove-useless-dependencies.patch
Patch1: 0002-add-huks-component.patch
Patch2: 0003-add-third-part-component.patch
Patch3: 0004-establish-relational-store-dependence-on-boundscheck.patch
Source1: https://gitee.com/openharmony/distributeddatamgr_relational_store/repository/archive/OpenHarmony-v3.2-Release.tar.gz#/distributeddatamgr_relational_store-OpenHarmony-v3.2-Release.tar.gz
Source2: bundle.json
Source3: appdatafwk.BUILD.gn
Source4: dataability.BUILD.gn
Source5: share.adapter.BUILD.gn
Source6: rdb.BUILD.gn
Patch1: 0001-remove-useless-dependencies.patch
Patch2: 0002-establish-relational-store-dependence-on-boundscheck.patch
BuildRequires: libatomic libicu-devel libxml2-devel openssl-devel
BuildRequires: distributed-build distributed-build_lite hilog distributed-utils
BuildRequires: distributeddatamgr_kv_store libicu
BuildRequires: libboundscheck, libicu-devel, libxml2-devel
BuildRequires: distributed-build, hilog, commonlibrary_c_utils
BuildRequires: communication_ipc, communication_dsoftbus
BuildRequires: distributeddatamgr_kv_store
Requires: hilog distributed-utils distributeddatamgr_kv_store
Requires: libboundscheck, libxml2-devel, libicu-devel
Requires: hilog, commonlibrary_c_utils
Requires: systemabilitymgr_safwk, systemabilitymgr_samgr
Requires: communication_ipc, communication_dsoftbus
Requires: distributeddatamgr_kv_store
%description
A relational database (RDB) is a database that manages data based on a relational model. The OpenHarmony relational database provides a complete mechanism for managing local databases based on the SQLite component.
%prep
rm -rf %{_builddir}/*
cd %{_builddir}
cp -rp %{build_opt} %{_builddir}/build
cp -rf %{build_opt} %{_builddir}/build
[ ! -L "%{_builddir}/build.sh" ] && ln -s %{_builddir}/build/build_scripts/build.sh %{_builddir}/build.sh
[ ! -L "%{_builddir}/.gn" ] && ln -s %{_builddir}/build/core/gn/dotfile.gn %{_builddir}/.gn
[ ! -L "%{_builddir}/build.py" ] && ln -s %{_builddir}/build/lite/build.py %{_builddir}/build.py
mv build/openeuler/vendor %{_builddir}/
cp -rf %{_builddir}/build/openeuler/vendor %{_builddir}/
cp -rf %{_builddir}/build/openeuler/compiler_gn/* %{_builddir}
%setup -q -T -a 0 -c -n %{relational_store_dir}
mv %{relational_store_dir}%{name}-%{oh_version} %{relational_store_dir}relational_store
cp -rf %{_builddir}/build/openeuler/compiler_gn/* %{_builddir}/
%setup -q -D -T -a 1 -c -n %{distributeddata_dir}
if [ -d "%{distributeddata_dir}/relational_store" ]; then
rm -rf %{distributeddata_dir}/relational_store
fi
mv %{distributeddata_dir}/%{name}-%{oh_version} %{distributeddata_dir}/relational_store
cd %{_builddir}
%patch0 -p1 -d %{relational_store_dir}relational_store
%patch1 -p1 -d %{_builddir}/base/security
%patch2 -p1 -d %{_builddir}/third_party
%patch3 -p1 -d %{_builddir}/foundation
%patch -P1 -p1 -d %{distributeddata_dir}/relational_store
%patch -P2 -p1 -d %{_builddir}/foundation
%build
cd %{_builddir}
rm -rf %{_builddir}/out
%ifarch x86_64
./build.sh --product-name openeuler --target-cpu x86_64
%{_builddir}/build.sh --product-name openeuler --target-cpu x86_64
%endif
%ifarch aarch64
./build.sh --product-name openeuler --target-cpu arm64
%{_builddir}/build.sh --product-name openeuler --target-cpu arm64
%endif
%install
install -d -m 0755 %{buildroot}%{_includedir}/relational_store
install -d -m 0755 %{buildroot}%{_libdir}
install -d -m 0755 %{buildroot}%{appdatafwk_dir}
install -d -m 0755 %{buildroot}%{dataability_dir}
install -d -m 0755 %{buildroot}%{share_adapter_dir}
install -d -m 0755 %{buildroot}%{rdb_dir}
%define appdatafwk_dir %{bundle_dir}/interfaces/inner_api/appdatafwk
%define dataability_dir %{bundle_dir}/interfaces/inner_api/dataability
%define share_adapter_dir %{bundle_dir}/interfaces/inner_api/rdb_data_share_adapter
%define rdb_dir %{bundle_dir}/interfaces/inner_api/rdb
install -d -m 0755 %{buildroot}/%{_includedir}/relational_store
install -d -m 0755 %{buildroot}/%{_libdir}
install -d -m 0755 %{buildroot}/%{appdatafwk_dir}
install -d -m 0755 %{buildroot}/%{dataability_dir}
install -d -m 0755 %{buildroot}/%{share_adapter_dir}
install -d -m 0755 %{buildroot}/%{rdb_dir}
install -d -m 0755 %{buildroot}/system/lib64
cp %{SOURCE2} %{buildroot}%{bundle_dir}
cp %{SOURCE3} %{buildroot}%{appdatafwk_dir}/BUILD.gn
cp %{SOURCE4} %{buildroot}%{dataability_dir}/BUILD.gn
cp %{SOURCE5} %{buildroot}%{share_adapter_dir}/BUILD.gn
cp %{SOURCE6} %{buildroot}%{rdb_dir}/BUILD.gn
%ifarch aarch64
module_out_path="out/openeuler/linux_clang_arm64/distributeddatamgr/relational_store/"
header_out_path="out/openeuler/innerkits/linux-arm64/relational_store"
%define lib_out_path out/openeuler/linux_clang_arm64/distributeddatamgr/relational_store
%define header_out_path out/openeuler/innerkits/linux-arm64/relational_store
%endif
%ifarch x86_64
module_out_path="out/openeuler/linux_clang_x86_64/distributeddatamgr/relational_store/"
header_out_path="out/openeuler/innerkits/linux-x86_64/relational_store"
%define lib_out_path out/openeuler/linux_clang_x86_64/distributeddatamgr/relational_store
%define header_out_path out/openeuler/innerkits/linux-x86_64/relational_store
%endif
install -m 0755 %{_builddir}/${module_out_path}/*.so %{buildroot}%{_libdir}
install -m 0755 %{_builddir}/${module_out_path}/*.so %{buildroot}/system/lib64/
install -m 0755 %{_builddir}/%{lib_out_path}/*.so %{buildroot}/%{_libdir}
install -m 0755 %{_builddir}/%{lib_out_path}/*.so %{buildroot}/system/lib64/
find %{_builddir}/${header_out_path} -name *.h -print0 | xargs -0 -i cp -rvf {} %{buildroot}%{_includedir}/relational_store/
find %{_builddir}/%{header_out_path} -name *.h -print0 | xargs -0 -i cp -rf {} %{buildroot}/%{_includedir}/relational_store/
pushd %{_builddir}/foundation/distributeddatamgr/relational_store/
for include_file in `find . \( -name js -o -name test -o -name mock \) -prune -o -name "*.h" -type f`
@ -99,12 +104,6 @@ do
done
popd
cp %{SOURCE1} %{buildroot}%{bundle_dir}
cp %{SOURCE2} %{buildroot}%{appdatafwk_dir}/BUILD.gn
cp %{SOURCE3} %{buildroot}%{dataability_dir}/BUILD.gn
cp %{SOURCE4} %{buildroot}%{share_adapter_dir}/BUILD.gn
cp %{SOURCE5} %{buildroot}%{rdb_dir}/BUILD.gn
%files
%{_libdir}/*.so
%{_includedir}/relational_store/*
@ -112,6 +111,9 @@ cp %{SOURCE5} %{buildroot}%{rdb_dir}/BUILD.gn
/system/*
%changelog
* Tue Nov 21 2023 Peng He <hepeng68@huawei.com> - 1.0.0-3
- Update build requires and requires.
* Thu Aug 03 2023 Peng He <hepeng68@huawei.com> - 1.0.0-2
- Add requires and rectify the contents of the RPM package.