commit 8f9b7b2a5e78cca88dc1de73bc38bbd658b9b60d Author: seki099 Date: Thu Nov 28 10:22:01 2019 +0800 package init diff --git a/cgdcbxd.service b/cgdcbxd.service new file mode 100644 index 0000000..d773423 --- /dev/null +++ b/cgdcbxd.service @@ -0,0 +1,10 @@ +[Unit] +Description=cgdcbxd daemon +After=syslog.target + +[Service] +ExecStart=/usr/sbin/cgdcbxd -n + +[Install] +WantedBy=multi-user.target + diff --git a/cgdcbxd.spec b/cgdcbxd.spec new file mode 100644 index 0000000..fef1beb --- /dev/null +++ b/cgdcbxd.spec @@ -0,0 +1,58 @@ +%global _hardened_build 1 + +Name: cgdcbxd +Version: 1.0.2 +Release: 9 +Summary: The daemon used to manage the priority of DCB network +License: GPLv2 +URL: https://github.com/jrfastab/cgdcbxd +Source: https://github.com/jrfastab/cgdcbxd/archive/v%{version}.tar.gz +Source1: %{name}.service +BuildRequires: libcgroup-devel libmnl-devel libtool systemd +Requires(post): systemd +Requires(preun): systemd +Requires(postun): systemd + +%description +The daemon keeps the hierarchy and priority mappings in sync with DCBX Application events. + +%package help +Summary: Help document for the %{name} package + +%description help +Help document for the %{name} package. + +%prep +%autosetup -n %{name}-%{version} -p1 + +%build +./bootstrap.sh +export CFLAGS=$RPM_OPT_FLAGS LDFLAGS=$RPM_LD_FLAGS +%{configure} +%make_build + +%install +%make_install +install -D -p -m 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_unitdir}/cgdcbxd.service + +%post +%systemd_post %{name}.service + +%preun +%systemd_preun %{name}.service + +%postun +%systemd_postun_with_restart %{name}.service + +%files +%doc COPYING +%{_unitdir}/cgdcbxd.service +%{_sbindir}/* +%exclude %{_sysconfdir} + +%files help +%{_mandir}/man8/* + +%changelog +* Wed Nov 13 2019 swx815716 - 1.0.2-9 +- Package init diff --git a/v1.0.2.tar.gz b/v1.0.2.tar.gz new file mode 100644 index 0000000..47eb0b5 Binary files /dev/null and b/v1.0.2.tar.gz differ