Compare commits
10 Commits
ede40c3c87
...
be883c9554
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
be883c9554 | ||
|
|
c857245eef | ||
|
|
7fb3813fff | ||
|
|
8fefed5ebc | ||
|
|
a68e1a6cc7 | ||
|
|
ef27d79f2b | ||
|
|
bbde2f06cc | ||
|
|
517886df4c | ||
|
|
5edb2c36a3 | ||
|
|
a959700787 |
36
README.en.md
36
README.en.md
@ -1,36 +0,0 @@
|
||||
# openhpi
|
||||
|
||||
#### Description
|
||||
{**When you're done, you can delete the content in this README and update the file with details for others getting started with your repository**}
|
||||
|
||||
#### Software Architecture
|
||||
Software architecture description
|
||||
|
||||
#### Installation
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### Instructions
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### Contribution
|
||||
|
||||
1. Fork the repository
|
||||
2. Create Feat_xxx branch
|
||||
3. Commit your code
|
||||
4. Create Pull Request
|
||||
|
||||
|
||||
#### Gitee Feature
|
||||
|
||||
1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md
|
||||
2. Gitee blog [blog.gitee.com](https://blog.gitee.com)
|
||||
3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore)
|
||||
4. The most valuable open source project [GVP](https://gitee.com/gvp)
|
||||
5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help)
|
||||
6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
||||
38
README.md
38
README.md
@ -1,39 +1 @@
|
||||
# openhpi
|
||||
|
||||
#### 介绍
|
||||
{**以下是码云平台说明,您可以替换此简介**
|
||||
码云是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN)。专为开发者提供稳定、高效、安全的云端软件开发协作平台
|
||||
无论是个人、团队、或是企业,都能够用码云实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)}
|
||||
|
||||
#### 软件架构
|
||||
软件架构说明
|
||||
|
||||
|
||||
#### 安装教程
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### 使用说明
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### 参与贡献
|
||||
|
||||
1. Fork 本仓库
|
||||
2. 新建 Feat_xxx 分支
|
||||
3. 提交代码
|
||||
4. 新建 Pull Request
|
||||
|
||||
|
||||
#### 码云特技
|
||||
|
||||
1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md
|
||||
2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com)
|
||||
3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目
|
||||
4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目
|
||||
5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
|
||||
6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
||||
|
||||
94
openhpi-3.4.0-systemd.patch
Normal file
94
openhpi-3.4.0-systemd.patch
Normal file
@ -0,0 +1,94 @@
|
||||
From d82555d0f32fc341d8f3e58a08f63894a3eb7ce0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Dan=20Hor=C3=A1k?= <dan@danny.cz>
|
||||
Date: Tue, 6 Mar 2012 11:23:01 +0100
|
||||
Subject: [PATCH] add support for systemd
|
||||
|
||||
New configure parameter is introduced (--with-systemdsystemunitdir) and when set
|
||||
it means that systemd service file will be installed instead of the classis initscript.
|
||||
---
|
||||
configure.ac | 12 ++++++++++++
|
||||
openhpid/Makefile.am | 7 +++++++
|
||||
openhpid/openhpid.service.in | 11 +++++++++++
|
||||
3 files changed, 30 insertions(+)
|
||||
create mode 100644 openhpid/openhpid.service.in
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index e538fb4..80157af 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -709,6 +709,17 @@ AC_ARG_ENABLE([man],
|
||||
AC_SUBST(MAN,"")
|
||||
fi])
|
||||
|
||||
+dnl systemd system unit files location
|
||||
+AC_ARG_WITH([systemdsystemunitdir],
|
||||
+ AS_HELP_STRING([--with-systemdsystemunitdir@<:@=DIR@:>@],[systemd system unit files location]),
|
||||
+ [enable_systemd=yes],
|
||||
+ [enable_systemd=no])
|
||||
+
|
||||
+dnl enable systemd and set unit dir
|
||||
+AM_CONDITIONAL([ENABLE_SYSTEMD], [test "x$enable_systemd" = "xyes"])
|
||||
+unitdir=$with_systemdsystemunitdir
|
||||
+AC_SUBST(unitdir)
|
||||
+
|
||||
AC_CONFIG_FILES([openhpi.spec
|
||||
openhpi.pc
|
||||
rt-env.sh
|
||||
@@ -751,6 +762,7 @@ AC_CONFIG_FILES([openhpi.spec
|
||||
docs/man/Makefile
|
||||
openhpid/Makefile
|
||||
openhpid/openhpid.sh
|
||||
+ openhpid/openhpid.service
|
||||
openhpid/t/Makefile
|
||||
openhpid/t/ohpi/Makefile
|
||||
hpi_shell/Makefile
|
||||
diff --git a/openhpid/Makefile.am b/openhpid/Makefile.am
|
||||
index bccbce5..bfc6e73 100644
|
||||
--- a/openhpid/Makefile.am
|
||||
+++ b/openhpid/Makefile.am
|
||||
@@ -28,6 +28,7 @@ DIST_SUBDIRS = t
|
||||
|
||||
EXTRA_DIST = \
|
||||
openhpid.sh.in \
|
||||
+ openhpid.service.in \
|
||||
Makefile.mingw32 \
|
||||
openhpid-win32.cpp \
|
||||
version.rc
|
||||
@@ -83,11 +84,17 @@ endif
|
||||
|
||||
|
||||
install-data-local:
|
||||
+if ENABLE_SYSTEMD
|
||||
+ $(mkinstalldirs) $(DESTDIR)$(unitdir)
|
||||
+ $(INSTALL) -m 0644 openhpid.service $(DESTDIR)$(unitdir)
|
||||
+else
|
||||
$(mkinstalldirs) $(DESTDIR)$(sysconfdir)/init.d
|
||||
$(INSTALL) -m 0755 openhpid.sh $(DESTDIR)$(sysconfdir)/init.d/openhpid
|
||||
+endif
|
||||
|
||||
uninstall-local:
|
||||
rm -f $(DESTDIR)$(sysconfdir)/init.d/openhpid
|
||||
+ rm -f $(DESTDIR)$(unitdir)/openhpid.service
|
||||
|
||||
clean-local:
|
||||
rm -f *~ core core.*
|
||||
diff --git a/openhpid/openhpid.service.in b/openhpid/openhpid.service.in
|
||||
new file mode 100644
|
||||
index 0000000..69b1348
|
||||
--- /dev/null
|
||||
+++ b/openhpid/openhpid.service.in
|
||||
@@ -0,0 +1,11 @@
|
||||
+[Unit]
|
||||
+Description=Daemon providing access to the SAF Hardware Platform Interface
|
||||
+After=syslog.target
|
||||
+
|
||||
+[Service]
|
||||
+Type=forking
|
||||
+PIDFile=/var/run/openhpid.pid
|
||||
+ExecStart=@sbindir@/openhpid -c @sysconfdir@/openhpi/openhpi.conf
|
||||
+
|
||||
+[Install]
|
||||
+WantedBy=multi-user.target
|
||||
--
|
||||
1.9.3
|
||||
|
||||
10
openhpi-3.6.1-ssl.patch
Normal file
10
openhpi-3.6.1-ssl.patch
Normal file
@ -0,0 +1,10 @@
|
||||
diff -up openhpi-3.6.1/ssl/Makefile.am.than openhpi-3.6.1/ssl/Makefile.am
|
||||
--- openhpi-3.6.1/ssl/Makefile.am.than 2017-02-21 12:21:12.114814698 -0500
|
||||
+++ openhpi-3.6.1/ssl/Makefile.am 2017-02-21 12:22:44.576454262 -0500
|
||||
@@ -19,5 +19,5 @@ lib_LTLIBRARIES = libopenhpi_ssl.la
|
||||
libopenhpi_ssl_la_SOURCES = oh_ssl.c oh_ssl.h
|
||||
|
||||
libopenhpi_ssl_la_LDFLAGS = -version-info @HPI_LIB_VERSION@
|
||||
-libopenhpi_ssl_la_LIBADD = @CRYPTO_LIB@
|
||||
+libopenhpi_ssl_la_LIBADD = -lssl @CRYPTO_LIB@
|
||||
|
||||
BIN
openhpi-3.8.0.tar.gz
Normal file
BIN
openhpi-3.8.0.tar.gz
Normal file
Binary file not shown.
121
openhpi.spec
Normal file
121
openhpi.spec
Normal file
@ -0,0 +1,121 @@
|
||||
Name: openhpi
|
||||
Version: 3.8.0
|
||||
Release: 9
|
||||
Summary: Implementation of the Service Availability Forum's Hardware Platform Interface
|
||||
License: BSD
|
||||
URL: http://www.openhpi.org
|
||||
Source0: https://github.com/open-hpi/%{name}/releases/download/%{version}/%{name}-%{version}.tar.gz
|
||||
Patch0: openhpi-3.4.0-systemd.patch
|
||||
Patch1: openhpi-3.6.1-ssl.patch
|
||||
|
||||
BuildRequires: glib2-devel gcc-c++ libsysfs-devel net-snmp-devel OpenIPMI-devel libtool-ltdl-devel
|
||||
BuildRequires: openssl-devel ncurses-devel libxml2-devel docbook-utils libuuid-devel librabbitmq-devel
|
||||
BuildRequires: json-c-devel libcurl-devel systemd autoconf automake libtool libgcrypt-devel
|
||||
Requires(post): systemd
|
||||
Requires(preun): systemd
|
||||
Requires(postun): systemd
|
||||
Provides: openhpi-libs = %{version}-%{release}
|
||||
Provides: openhpi-libs%{?_isa} = %{version}-%{release}
|
||||
Obsoletes: openhpi-libs < %{version}-%{release}
|
||||
|
||||
%description
|
||||
OpenHPI provides an open source implementation of the Service Availability
|
||||
Forum (SAF) Hardware Platform Interface (HPI). HPI is an abstracted interface
|
||||
for managing computer hardware, typically chassis and rack based servers. HPI
|
||||
includes resource modeling; access to and control over sensor, control,
|
||||
watchdog, and inventory data associated with resources; abstracted System
|
||||
Event Log interfaces; hardware events and alarms; and a managed hotswap
|
||||
interface.
|
||||
|
||||
OpenHPI's architecture contains a modular mechanism intended to make adding
|
||||
new hardware support easier. Several plugins exist in the OpenHPI source tree
|
||||
giving access to various types of hardware. This includes, but is not limited
|
||||
to, IPMI based servers, Blade Center, and machines which export data via sysfs.
|
||||
|
||||
%package devel
|
||||
Summary: Development files for openhpi
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Requires: glib2-devel
|
||||
|
||||
%description devel
|
||||
This package contains libraries and headier files for developing applications
|
||||
that use openhpi.
|
||||
|
||||
%package_help
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version} -p1
|
||||
autoreconf -ivf
|
||||
|
||||
chmod a-x plugins/simulator/*.[ch]
|
||||
chmod a-x clients/hpipower.c
|
||||
|
||||
if [ $UID -eq 0 ]; then
|
||||
find . -name openhpi.conf -exec chown root:root {} \;
|
||||
find . -name openhpi.conf -execdir chown root:root . \;
|
||||
fi
|
||||
|
||||
%build
|
||||
export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
|
||||
%configure --disable-static --with-systemdsystemunitdir=%{_unitdir}
|
||||
|
||||
%disable_rpath
|
||||
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
|
||||
mkdir -p -m1755 $RPM_BUILD_ROOT%{_var}/lib/%{name}
|
||||
%make_install
|
||||
|
||||
%delete_la
|
||||
|
||||
%check
|
||||
make check
|
||||
|
||||
%post
|
||||
%systemd_post openhpid.service
|
||||
|
||||
%preun
|
||||
%systemd_preun openhpid.service
|
||||
|
||||
%postun
|
||||
%systemd_postun_with_restart openhpid.service
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%license %{_docdir}/%{name}/COPYING
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/%{name}.conf
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/%{name}client.conf
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/simulation.data
|
||||
%{_bindir}/*
|
||||
%{_sbindir}/*
|
||||
%{_libdir}/%{name}
|
||||
%{_libdir}/*.so.*
|
||||
%{_unitdir}/openhpid.service
|
||||
%dir %{_sysconfdir}/%{name}
|
||||
%attr(1755,root,root) %{_var}/lib/%{name}
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/*.so
|
||||
%{_includedir}/%{name}/*.h
|
||||
%{_libdir}/pkgconfig/*.pc
|
||||
|
||||
%files help
|
||||
%defattr(-,root,root)
|
||||
%doc %{_docdir}/%{name}/ChangeLog
|
||||
%doc %{_docdir}/%{name}/README*
|
||||
%{_mandir}/man1/*1*
|
||||
%{_mandir}/man7/*7*
|
||||
%{_mandir}/man8/*8*
|
||||
|
||||
%changelog
|
||||
* Fri Dec 24 2021 liyanan <liyanan32@huawei.com> - 3.8.0-9
|
||||
- fix update error and changelog number
|
||||
|
||||
* Tue Sep 15 2020 Ge Wang <wangge20@huawei.com> - 3.8.0-8
|
||||
- Modify Source0 Url
|
||||
|
||||
* Tue Nov 26 2019 openEuler Buildteam <buildteam@openeuler.org> - 3.8.0-7
|
||||
- Package init
|
||||
4
openhpi.yaml
Normal file
4
openhpi.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
version_control: github
|
||||
src_repo: open-hpi/openhpi
|
||||
tag_prefix: "openhpi-"
|
||||
seperator: "."
|
||||
Loading…
x
Reference in New Issue
Block a user