2020-09-24 16:16:19 +08:00
|
|
|
Name: fastdfs
|
|
|
|
|
Version: 6.06
|
2022-06-23 19:07:58 +08:00
|
|
|
Release: 3
|
2020-09-24 16:16:19 +08:00
|
|
|
Summary: FastDFS server and client
|
|
|
|
|
License: GPL3.0
|
|
|
|
|
Group: Arch/Tech
|
|
|
|
|
URL: https://github.com/happyfish100/fastdfs
|
|
|
|
|
Source: https://github.com/happyfish100/fastdfs/archive/V%{version}.tar.gz
|
|
|
|
|
|
2021-04-02 11:48:17 +08:00
|
|
|
Patch0: 0001-move_scripts_to_data_dir.patch
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
Requires: gcc cmake
|
|
|
|
|
BuildRequires: libfastcommon-devel >= 1.0.43
|
2022-06-23 19:07:58 +08:00
|
|
|
BuildRequires: perl
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
This package provides tracker & storage of fastdfs
|
|
|
|
|
|
|
|
|
|
%package -n fastdfs-server
|
|
|
|
|
Requires: libfastcommon >= 1.0.43
|
|
|
|
|
Summary: fastdfs tracker & storage
|
|
|
|
|
|
|
|
|
|
%package -n fastdfs-tools
|
|
|
|
|
Requires: libfastcommon
|
|
|
|
|
Summary: fastdfs tools
|
|
|
|
|
|
|
|
|
|
%package -n libfdfsclient
|
|
|
|
|
Requires: libfastcommon
|
|
|
|
|
Summary: The client dynamic library of fastdfs
|
|
|
|
|
|
|
|
|
|
%package -n libfdfsclient-devel
|
|
|
|
|
Requires: libfdfsclient
|
|
|
|
|
Summary: The client header of fastdfs
|
|
|
|
|
|
|
|
|
|
%description -n fastdfs-server
|
|
|
|
|
This package provides tracker & storage of fastdfs
|
|
|
|
|
|
|
|
|
|
%description -n libfdfsclient
|
|
|
|
|
This package is client dynamic library of fastdfs
|
|
|
|
|
|
|
|
|
|
%description -n libfdfsclient-devel
|
|
|
|
|
This package is client header of fastdfs client
|
|
|
|
|
|
|
|
|
|
%description -n fastdfs-tools
|
|
|
|
|
This package is tools for fastdfs
|
|
|
|
|
|
|
|
|
|
%prep
|
2021-04-02 11:48:17 +08:00
|
|
|
%autosetup -p1
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
./make.sh
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
rm -rf %{buildroot}
|
|
|
|
|
DESTDIR=$RPM_BUILD_ROOT ./make.sh install
|
|
|
|
|
rm -f %{buildroot}/etc/fdfs/http.conf.sample
|
|
|
|
|
rm -f %{buildroot}/etc/fdfs/mime.types.sample
|
|
|
|
|
|
|
|
|
|
%post -n fastdfs-server
|
|
|
|
|
/sbin/chkconfig --add fdfs_trackerd
|
|
|
|
|
/sbin/chkconfig --add fdfs_storaged
|
|
|
|
|
|
2021-04-02 11:48:17 +08:00
|
|
|
create_symbolic_link() {
|
|
|
|
|
local source_file="%{_datadir}/%{name}/bin/$1"
|
|
|
|
|
local target_file="%{_bindir}/fdfs_$1"
|
|
|
|
|
test -f "${source_file}" && ln -sf "${source_file}" "${target_file}"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
create_symbolic_link "restart.sh"
|
|
|
|
|
create_symbolic_link "stop.sh"
|
|
|
|
|
|
2020-09-24 16:16:19 +08:00
|
|
|
%preun -n fastdfs-server
|
|
|
|
|
/sbin/chkconfig --del fdfs_trackerd
|
|
|
|
|
/sbin/chkconfig --del fdfs_storaged
|
|
|
|
|
|
2021-04-02 11:48:17 +08:00
|
|
|
%postun -n fastdfs-server
|
|
|
|
|
find %{_bindir} -maxdepth 1 -type l \
|
|
|
|
|
-name "fdfs_restart.sh" -delete -o \
|
|
|
|
|
-name "fdfs_stop.sh" -delete
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%clean
|
|
|
|
|
rm -rf %{buildroot}
|
|
|
|
|
|
|
|
|
|
%files -n fastdfs-server
|
|
|
|
|
%defattr(-,root,root,-)
|
2021-04-02 11:48:17 +08:00
|
|
|
%{_bindir}/fdfs_trackerd
|
|
|
|
|
%{_bindir}/fdfs_storaged
|
|
|
|
|
%{_datadir}/%{name}/bin/restart.sh
|
|
|
|
|
%{_datadir}/%{name}/bin/stop.sh
|
|
|
|
|
%{_sysconfdir}/init.d/*
|
|
|
|
|
%{_sysconfdir}/fdfs/tracker.conf.sample
|
|
|
|
|
%{_sysconfdir}/fdfs/storage.conf.sample
|
|
|
|
|
%{_sysconfdir}/fdfs/storage_ids.conf.sample
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%files -n libfdfsclient
|
2021-04-02 11:48:17 +08:00
|
|
|
%{_libdir}/libfdfsclient*
|
|
|
|
|
%{_usr}/lib/libfdfsclient*
|
|
|
|
|
%{_sysconfdir}/fdfs/client.conf.sample
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%files -n libfdfsclient-devel
|
|
|
|
|
%defattr(-,root,root,-)
|
2021-04-02 11:48:17 +08:00
|
|
|
%{_includedir}/fastdfs/*
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%files -n fastdfs-tools
|
2021-04-02 11:48:17 +08:00
|
|
|
%{_bindir}/fdfs_monitor
|
|
|
|
|
%{_bindir}/fdfs_test
|
|
|
|
|
%{_bindir}/fdfs_test1
|
|
|
|
|
%{_bindir}/fdfs_crc32
|
|
|
|
|
%{_bindir}/fdfs_upload_file
|
|
|
|
|
%{_bindir}/fdfs_download_file
|
|
|
|
|
%{_bindir}/fdfs_delete_file
|
|
|
|
|
%{_bindir}/fdfs_file_info
|
|
|
|
|
%{_bindir}/fdfs_appender_test
|
|
|
|
|
%{_bindir}/fdfs_appender_test1
|
|
|
|
|
%{_bindir}/fdfs_append_file
|
|
|
|
|
%{_bindir}/fdfs_upload_appender
|
|
|
|
|
%{_bindir}/fdfs_regenerate_filename
|
2020-09-24 16:16:19 +08:00
|
|
|
|
|
|
|
|
%changelog
|
2022-06-23 19:07:58 +08:00
|
|
|
* Thu Jun 23 2022 lihaoxiang <lihaoxiang9@huawei.com> - 6.06-3
|
|
|
|
|
- Modified fastdfs.spec that add BuildRequires about perl
|
|
|
|
|
|
2021-04-02 11:48:17 +08:00
|
|
|
* Fri Apr 02 2021 herengui <herengui@uniontech.com> - 6.06-2
|
|
|
|
|
- Rearrange the files list
|
|
|
|
|
|
|
|
|
|
* Fri Sep 11 2020 huyan90325 <huyan90325@talkweb.com.cn> - 6.06-1
|
2020-09-24 16:16:19 +08:00
|
|
|
- Fastdfs package init
|