summaryrefslogtreecommitdiff
path: root/file-reorganize.spec
blob: 06cb97413e29756bf9dc59b807e047dd6ddcf774 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
Name:           file-reorganize
Version:        1.0       
Release:        1%{?dist}
Summary:        file reoganize      

License:        MulanPSL2.0
URL:            https://atomgit.com/openeuler123/x_haihua.git
Source0:        %{name}-%{version}.tar.gz

BuildRequires:  wget, dnf-plugins-core, binutils, glibc-devel, gcc-c++, openssl

%define debug_package %{nil}

%description


%prep
%autosetup

# 安装cangjie
plt=`uname -m`
if [[ $plt -eq "x86_64" ]]; then
	cd %{_builddir}
	git clone https://atomgit.com/x_haihua/cangjie_x86_64.git
	source %{_builddir}/cangjie_x86_64/envsetup.sh
else
	echo "waiting..."
fi

%build
cjpm build

%install
# 将需要打包的文件拷贝到buildroot目录中去
mkdir -p %{buildroot}/root/file-reorganize/bin
mkdir -p %{buildroot}/root/file-reorganize/config
cp -r %{_builddir}/%{name}-%{version}/target/release/bin/* %{buildroot}/root/file-reorganize/bin
cp -r %{_builddir}/%{name}-%{version}/config/* %{buildroot}/root/file-reorganize/config

%files
# 指定将要部署的文件有哪些
/root/file-reorganize/bin/*
/root/file-reorganize/config/*


%changelog
* Tue Dec 24 2024 x_haihua <x_haihua@163.com>
-