Modsecurity module added to Nginx. Archive directory created
This commit is contained in:
103
fedora/SPECS/archive/clsync.spec
Normal file
103
fedora/SPECS/archive/clsync.spec
Normal file
@@ -0,0 +1,103 @@
|
||||
#
|
||||
# author: Enrique Martinez <enmaca@hotmail.com>
|
||||
# license: GPL-3+
|
||||
#
|
||||
Summary: Live sync tool based on inotify
|
||||
Name: clsync
|
||||
Version: 0.4.1
|
||||
Release: 1%{?dist}
|
||||
License: GPL-3+
|
||||
Group: Applications/System
|
||||
URL: https://github.com/xaionaro/clsync
|
||||
Source0: clsync-%{version}.tar.gz
|
||||
Source1: clsync.init
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
BuildRequires: glib2-devel
|
||||
BuildRequires: autoconf
|
||||
|
||||
%description
|
||||
live sync tool based on inotify, written in GNU C
|
||||
Clsync recursively watches for source directory and executes external
|
||||
program to sync the changes. Clsync is adapted to use together with rsync.
|
||||
This utility is much more lightweight than competitors and supports such
|
||||
features as separate queue for big files, regex file filter,
|
||||
multi-threading.
|
||||
|
||||
%package devel
|
||||
Summary: Development Files for clsync
|
||||
Group: Applications/System
|
||||
Requires: clsync = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
live sync tool based on inotify, written in GNU C
|
||||
Clsync recursively watches for source directory and executes external
|
||||
program to sync the changes. Clsync is adapted to use together with rsync.
|
||||
This utility is much more lightweight than competitors and supports such
|
||||
features as separate queue for big files, regex file filter,
|
||||
multi-threading.
|
||||
|
||||
%prep
|
||||
%setup
|
||||
|
||||
%build
|
||||
autoreconf -if
|
||||
%configure
|
||||
make
|
||||
|
||||
%install
|
||||
make install DESTDIR=%{buildroot}
|
||||
install -D -p -m 0750 %{SOURCE1} %{buildroot}/etc/init.d/clsync
|
||||
mkdir -p %{buildroot}/etc/clsync/rules
|
||||
mkdir -p %{buildroot}/var/tmp/clsync/from
|
||||
mkdir -p %{buildroot}/var/tmp/clsync/to
|
||||
mkdir -p %{buildroot}/var/run/clsync
|
||||
|
||||
cat > %{buildroot}/etc/clsync/clsync.conf <<EOF
|
||||
# This configuration is a simple test
|
||||
[default]
|
||||
watch-dir = /var/tmp/clsync/from
|
||||
rules-file = /etc/clsync/rules/default
|
||||
destination-dir = /var/tmp/clsync/to
|
||||
mode = rsyncdirect
|
||||
sync-handler = /usr/bin/rsync
|
||||
background = 1
|
||||
syslog = 1
|
||||
full-initialsync = 1
|
||||
retries = 3
|
||||
EOF
|
||||
|
||||
cat > %{buildroot}/etc/clsync/rules/default <<EOF
|
||||
-d^[Dd]ont[Ss]ync\$
|
||||
+*.*
|
||||
EOF
|
||||
|
||||
%clean
|
||||
rm -rf %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%{_bindir}/*
|
||||
%doc %{_docdir}/*
|
||||
%doc %{_mandir}/man1/clsync.1.gz
|
||||
%dir /var/tmp/clsync/from
|
||||
%dir /var/tmp/clsync/to
|
||||
%dir /var/run/clsync
|
||||
%config(noreplace) /etc/clsync/clsync.conf
|
||||
/etc/clsync/rules/default
|
||||
/etc/init.d/clsync
|
||||
|
||||
|
||||
%files devel
|
||||
%{_includedir}/clsync/clsync.h
|
||||
%{_includedir}/clsync/compilerflags.h
|
||||
%{_includedir}/clsync/configuration.h
|
||||
%{_includedir}/clsync/ctx.h
|
||||
%{_includedir}/clsync/error.h
|
||||
%{_includedir}/clsync/indexes.h
|
||||
%{_includedir}/clsync/malloc.h
|
||||
%{_includedir}/clsync/port-hacks.h
|
||||
|
||||
|
||||
%changelog
|
||||
* Sat Sep 17 2016 Daniel Steiner <elpito@bluewin.ch>
|
||||
- First build for Fedora
|
||||
1126
fedora/SPECS/archive/collectd.spec
Normal file
1126
fedora/SPECS/archive/collectd.spec
Normal file
File diff suppressed because it is too large
Load Diff
318
fedora/SPECS/archive/icinga-web.spec
Normal file
318
fedora/SPECS/archive/icinga-web.spec
Normal file
@@ -0,0 +1,318 @@
|
||||
# $Id$
|
||||
# Authority: The icinga devel team <icinga-devel at lists.icinga.org>
|
||||
# Upstream: The icinga devel team <icinga-devel at lists.icinga.org>
|
||||
# ExcludeDist: el4 el3
|
||||
|
||||
%define revision 1
|
||||
|
||||
%define logdir %{_localstatedir}/log/%{name}
|
||||
%define cachedir %{_localstatedir}/cache/%{name}
|
||||
%define reportingcachedir %{_localstatedir}/cache/%{name}/reporting
|
||||
|
||||
%define phpname php
|
||||
|
||||
# el5 requires newer php53 rather than php (5.1)
|
||||
%if 0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5"
|
||||
%define phpname php53
|
||||
%endif
|
||||
|
||||
%if "%{_vendor}" == "suse"
|
||||
%define apacheconfdir %{_sysconfdir}/apache2/conf.d
|
||||
%define apacheuser wwwrun
|
||||
%define apachegroup www
|
||||
%define extcmdfile %{_localstatedir}/icinga/rw/icinga.cmd
|
||||
%endif
|
||||
%if "%{_vendor}" == "redhat"
|
||||
%define apacheconfdir %{_sysconfdir}/httpd/conf.d
|
||||
%define apacheuser apache
|
||||
%define apachegroup apache
|
||||
%define extcmdfile %{_localstatedir}/spool/icinga/cmd/icinga.cmd
|
||||
%endif
|
||||
|
||||
Summary: Open Source host, service and network monitoring Web UI
|
||||
Name: icinga-web
|
||||
Version: 1.13.0
|
||||
Release: %{revision}%{?dist}
|
||||
License: GPLv3
|
||||
Group: Applications/System
|
||||
URL: http://www.icinga.org
|
||||
BuildArch: noarch
|
||||
|
||||
%if "%{_vendor}" == "suse"
|
||||
AutoReqProv: Off
|
||||
%endif
|
||||
|
||||
Source0: https://github.com/Icinga/icinga-web/releases/download/v%{version}/icinga-web-%{version}.tar.gz
|
||||
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
|
||||
BuildRequires: make
|
||||
BuildRequires: %{phpname} >= 5.2.3
|
||||
BuildRequires: %{phpname}-devel >= 5.2.3
|
||||
BuildRequires: %{phpname}-gd
|
||||
BuildRequires: %{phpname}-ldap
|
||||
BuildRequires: %{phpname}-pdo
|
||||
|
||||
%if "%{_vendor}" == "redhat"
|
||||
BuildRequires: %{phpname}-xml
|
||||
BuildRequires: php-pear
|
||||
%endif
|
||||
%if "%{_vendor}" == "suse"
|
||||
BuildRequires: %{phpname}-json
|
||||
BuildRequires: %{phpname}-sockets
|
||||
BuildRequires: %{phpname}-xsl
|
||||
BuildRequires: %{phpname}-dom
|
||||
BuildRequires: %{phpname}-pear
|
||||
%endif
|
||||
|
||||
Requires: pcre >= 7.6
|
||||
Requires: %{phpname} >= 5.2.3
|
||||
Requires: %{phpname}-gd
|
||||
Requires: %{phpname}-ldap
|
||||
Requires: %{phpname}-pdo
|
||||
%if "%{_vendor}" == "redhat"
|
||||
Requires: %{phpname}-common
|
||||
Requires: %{phpname}-xml
|
||||
Requires: php-pear
|
||||
%endif
|
||||
%if "%{_vendor}" == "suse"
|
||||
Requires: %{phpname}-pear
|
||||
Requires: %{phpname}-xsl
|
||||
Requires: %{phpname}-dom
|
||||
Requires: %{phpname}-tokenizer
|
||||
Requires: %{phpname}-gettext
|
||||
Requires: %{phpname}-ctype
|
||||
Requires: %{phpname}-json
|
||||
Requires: %{phpname}-pear
|
||||
Requires: mod_php_any
|
||||
%endif
|
||||
|
||||
|
||||
%description
|
||||
Icinga Web for Icinga Core, uses Icinga IDOUtils DB as data source.
|
||||
|
||||
%package mysql
|
||||
Summary: Database config for mysql
|
||||
Group: Applications/System
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: %{phpname}-mysql
|
||||
Conflicts: %{name}-pgsql
|
||||
|
||||
%description mysql
|
||||
Database config and requirements for mysql for icinga-web
|
||||
|
||||
%package pgsql
|
||||
Summary: Database config for pgsql
|
||||
Group: Applications/System
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: %{phpname}-pgsql
|
||||
Conflicts: %{name}-mysql
|
||||
|
||||
%description pgsql
|
||||
Database config and requirements for pgsql for icinga-web
|
||||
|
||||
%package module-pnp
|
||||
Summary: PNP Integration module for Icinga Web
|
||||
Group: Applications/System
|
||||
Requires: pnp4nagios
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description module-pnp
|
||||
PNP Integration module for Icinga Web
|
||||
|
||||
%package scheduler
|
||||
Summary: Scheduler for Icinga Web
|
||||
Group: Applications/System
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
%if "%{_vendor}" == "suse"
|
||||
Requires: cron
|
||||
%endif
|
||||
%if "%{_vendor}" == "redhat"
|
||||
%if 0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5"
|
||||
Requires: vixie-cron
|
||||
%else
|
||||
Requires: cronie
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%description scheduler
|
||||
Scheduler for Icinga Web
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-%{version}
|
||||
|
||||
%build
|
||||
%configure \
|
||||
--prefix="%{_datadir}/%{name}" \
|
||||
--datadir="%{_datadir}/%{name}" \
|
||||
--datarootdir="%{_datadir}/%{name}" \
|
||||
--sysconfdir="%{_sysconfdir}/%{name}" \
|
||||
--with-conf-dir='%{_sysconfdir}/%{name}/conf.d' \
|
||||
--with-web-user='%{apacheuser}' \
|
||||
--with-web-group='%{apachegroup}' \
|
||||
--with-api-cmd-file='%{extcmdfile}' \
|
||||
--with-log-dir='%{logdir}' \
|
||||
--with-cache-dir='%{cachedir}' \
|
||||
--with-reporting-tmp-dir='%{reportingcachedir}' \
|
||||
--with-icinga-bin='%{_bindir}/icinga' \
|
||||
--with-icinga-cfg='%{_sysconfdir}/icinga/icinga.cfg' \
|
||||
--with-icinga-objects-dir='%{_sysconfdir}/icinga/objects' \
|
||||
--with-clearcache-path='%{_bindir}' \
|
||||
--with-web-apache-path=%{apacheconfdir}
|
||||
|
||||
%install
|
||||
%{__rm} -rf %{buildroot}
|
||||
%{__mkdir} -p %{buildroot}/%{apacheconfdir}
|
||||
%{__mkdir} -p %{buildroot}/%{_bindir}
|
||||
%{__make} install \
|
||||
install-apache-config \
|
||||
DESTDIR="%{buildroot}" \
|
||||
INSTALL_OPTS="" \
|
||||
COMMAND_OPTS="" \
|
||||
INSTALL_OPTS_WEB="" \
|
||||
INSTALL_OPTS_CACHE="" \
|
||||
INIT_OPTS=""
|
||||
|
||||
# install scheduler
|
||||
%{__mkdir} -p %{buildroot}%{_sysconfdir}/cron.d/
|
||||
sed -e "s#%%USER%%#icinga#;s#%%PATH%%#%{_datadir}/%{name}#" etc/scheduler/icingaCron > %{buildroot}%{_sysconfdir}/cron.d/icingaCron
|
||||
%{__mkdir} -p %{buildroot}%{_localstatedir}/log/icingaCron
|
||||
|
||||
# we only want clearcache.sh prefixed in {_bindir}, generated from configure
|
||||
%{__mv} %{buildroot}%{_bindir}/clearcache.sh %{buildroot}%{_bindir}/%{name}-clearcache
|
||||
|
||||
# wipe the rest of bin/, we don't need prepackage stuff in installed envs
|
||||
%{__rm} -rf %{buildroot}%{_datadir}/%{name}/bin
|
||||
|
||||
# place the pnp templates for -module-pnp
|
||||
%{__cp} contrib/PNP_Integration/templateExtensions/* %{buildroot}%{_datadir}/%{name}/app/modules/Cronks/data/xml/extensions/
|
||||
|
||||
%pre
|
||||
# Add apacheuser in the icingacmd group
|
||||
# If the group exists, add the apacheuser in the icingacmd group.
|
||||
# It is not neccessary that icinga-web is installed on the same system as
|
||||
# icinga and only on systems with icinga installed the icingacmd
|
||||
# group exists. In all other cases the user used for ssh access has
|
||||
# to be added to the icingacmd group on the remote icinga server.
|
||||
getent group icingacmd > /dev/null
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
%if "%{_vendor}" == "suse"
|
||||
%{_sbindir}/usermod -G icingacmd %{apacheuser}
|
||||
%else
|
||||
%{_sbindir}/usermod -a -G icingacmd %{apacheuser}
|
||||
%endif
|
||||
fi
|
||||
|
||||
# uncomment if building from git
|
||||
# %{__rm} -rf %{buildroot}%{_datadir}/icinga-web/.git
|
||||
|
||||
%preun
|
||||
%if "%{_vendor}" == "suse"
|
||||
%restart_on_update apache2
|
||||
%endif
|
||||
|
||||
%post
|
||||
# clean config cache, e.g. after upgrading
|
||||
%{name}-clearcache
|
||||
|
||||
%if "%{_vendor}" == "suse"
|
||||
a2enmod rewrite
|
||||
%restart_on_update apache2
|
||||
%endif
|
||||
|
||||
%postun
|
||||
%if "%{_vendor}" == "suse"
|
||||
%restart_on_update apache2
|
||||
%endif
|
||||
|
||||
%post pgsql
|
||||
### change databases.xml to match pgsql config
|
||||
# check if this is an upgrade
|
||||
if [ $1 -eq 2 ]
|
||||
then
|
||||
%{__cp} %{_sysconfdir}/%{name}/conf.d/databases.xml %{_sysconfdir}/%{name}/conf.d/databases.xml.pgsql
|
||||
%{__perl} -pi -e '
|
||||
s|db_servertype=mysql|db_servertype=pgsql|;
|
||||
s|db_port=3306|db_port=5432|;
|
||||
' %{_sysconfdir}/%{name}/conf.d/databases.xml.pgsql
|
||||
%logmsg "Warning: upgrade, pgsql config written to databases.xml.pgsql"
|
||||
fi
|
||||
# install
|
||||
if [ $1 -eq 1 ]
|
||||
then
|
||||
%{__perl} -pi -e '
|
||||
s|db_servertype=mysql|db_servertype=pgsql|;
|
||||
s|db_port=3306|db_port=5432|;
|
||||
' %{_sysconfdir}/%{name}/conf.d/databases.xml
|
||||
fi
|
||||
|
||||
%post module-pnp
|
||||
# clean cronk template cache
|
||||
%{name}-clearcache
|
||||
|
||||
%postun module-pnp
|
||||
if [ -f %{_sbindir}/%{name}-clearcache ]; then
|
||||
%{name}-clearcache
|
||||
fi
|
||||
|
||||
%clean
|
||||
%{__rm} -rf %{buildroot}
|
||||
|
||||
%files
|
||||
# main dirs
|
||||
%defattr(-,root,root)
|
||||
%if "%{_vendor}" == "redhat"
|
||||
%doc etc/schema doc/README.RHEL doc/AUTHORS doc/CHANGELOG-1.13 doc/LICENSE
|
||||
%endif
|
||||
%if "%{_vendor}" == "suse"
|
||||
%doc etc/schema doc/README.SUSE doc/AUTHORS doc/CHANGELOG-1.13 doc/LICENSE
|
||||
%endif
|
||||
# packaged by subpackages
|
||||
%exclude %{_datadir}/%{name}/app/modules/Cronks/data/xml/extensions
|
||||
%exclude %{_sysconfdir}/%{name}/conf.d/databases.xml
|
||||
%{_datadir}/%{name}/app
|
||||
%{_datadir}/%{name}/doc
|
||||
%{_datadir}/%{name}/etc
|
||||
%{_datadir}/%{name}/lib
|
||||
%{_datadir}/%{name}/pub
|
||||
# configs
|
||||
%defattr(-,root,root)
|
||||
%config(noreplace) %attr(-,root,root) %{apacheconfdir}/icinga-web.conf
|
||||
%dir %{_sysconfdir}/%{name}
|
||||
%dir %{_sysconfdir}/%{name}/conf.d
|
||||
%config(noreplace) %attr(644,-,-) %{_sysconfdir}/%{name}/conf.d/*
|
||||
# logs+cache
|
||||
%attr(2775,%{apacheuser},%{apachegroup}) %dir %{logdir}
|
||||
%attr(-,%{apacheuser},%{apachegroup}) %{cachedir}
|
||||
%attr(-,%{apacheuser},%{apachegroup}) %{cachedir}/config
|
||||
# data directory writable for web server
|
||||
%attr(-,%{apacheuser},%{apachegroup}) %{_datadir}/%{name}/app/data/tmp
|
||||
# binaries
|
||||
%defattr(-,root,root)
|
||||
%{_bindir}/%{name}-clearcache
|
||||
# stylesheet
|
||||
%config(noreplace) %{_datadir}/%{name}/pub/styles/icinga.site.css
|
||||
|
||||
%files mysql
|
||||
%config(noreplace) %attr(644,-,-) %{_sysconfdir}/%{name}/conf.d/databases.xml
|
||||
|
||||
%files pgsql
|
||||
%config(noreplace) %attr(644,-,-) %{_sysconfdir}/%{name}/conf.d/databases.xml
|
||||
|
||||
|
||||
%files module-pnp
|
||||
# templates, experimental treatment as configs (noreplace)
|
||||
%defattr(-,root,root)
|
||||
%doc contrib/PNP_Integration/README contrib/PNP_Integration/INSTALL
|
||||
%doc contrib/PNP_Integration/doc contrib/nginx
|
||||
%dir %{_datadir}/icinga-web/app/modules/Cronks/data/xml/extensions
|
||||
%config(noreplace) %attr(644,-,-) %{_datadir}/%{name}/app/modules/Cronks/data/xml/extensions/*
|
||||
|
||||
%files scheduler
|
||||
%defattr(-,root,root)
|
||||
%{_sysconfdir}/cron.d/icingaCron
|
||||
%attr(-,icinga,icinga) %{_localstatedir}/log/icingaCron
|
||||
|
||||
%changelog
|
||||
603
fedora/SPECS/archive/icinga.spec
Normal file
603
fedora/SPECS/archive/icinga.spec
Normal file
@@ -0,0 +1,603 @@
|
||||
# $Id$
|
||||
# Authority: cmr
|
||||
# Upstream: The icinga devel team <icinga-devel at lists.icinga.org>
|
||||
#
|
||||
# Needs libdbi
|
||||
#
|
||||
# ExclusiveDist: el5 el6
|
||||
|
||||
%define revision 0
|
||||
|
||||
%define logmsg logger -t %{name}/rpm
|
||||
|
||||
%define logdir %{_localstatedir}/log/%{name}
|
||||
%define spooldir %{_localstatedir}/spool/%{name}
|
||||
%define plugindir %{_libdir}/nagios/plugins
|
||||
|
||||
%if "%{_vendor}" == "suse"
|
||||
%define apacheuser wwwrun
|
||||
%define apachegroup www
|
||||
%define apachename apache2
|
||||
%define apacheconfdir %{_sysconfdir}/%{apachename}/conf.d
|
||||
%define extcmdfile %{_localstatedir}/icinga/rw/icinga.cmd
|
||||
%define extcmdfiledir %{_localstatedir}/icinga/rw
|
||||
%define readme README.SUSE
|
||||
%define readmeido README.SUSE.idoutils
|
||||
%endif
|
||||
%if "%{_vendor}" == "redhat"
|
||||
%define apachename httpd
|
||||
%define apacheconfdir %{_sysconfdir}/%{apachename}/conf.d
|
||||
%define apacheuser apache
|
||||
%define apachegroup apache
|
||||
%define extcmdfile %{_localstatedir}/spool/icinga/cmd/icinga.cmd
|
||||
%define extcmdfiledir %{_localstatedir}/spool/icinga/cmd
|
||||
%define readme README.RHEL
|
||||
%define readmeido README.RHEL.idoutils
|
||||
%endif
|
||||
|
||||
# Systemd support for Fedora >= 15
|
||||
%if 0%{?fedora} >= 15
|
||||
%define using_systemd 1
|
||||
%else
|
||||
%define using_sysvinit 1
|
||||
%endif
|
||||
|
||||
# Check to see if we're allowed to use macroized systemd scriptlets, as
|
||||
# introduced in Fedora 18.
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?fedora} >= 18
|
||||
%define systemd_macro_scriptlet 1
|
||||
%else
|
||||
%define systemd_macro_scriptlet 0
|
||||
%endif # Fedora >= 18
|
||||
%endif # using_systemd
|
||||
|
||||
Summary: Open Source host, service and network monitoring program
|
||||
Name: icinga
|
||||
Version: 1.13.3
|
||||
Release: %{revision}%{?dist}
|
||||
License: GPLv2
|
||||
Group: Applications/System
|
||||
URL: http://www.icinga.org/
|
||||
|
||||
Source0: https://github.com/Icinga/icinga-core/releases/download/v%{version}/icinga-%{version}.tar.gz
|
||||
Patch0: icinga-ido2db-systemd.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
|
||||
%if "%{_vendor}" == "redhat"
|
||||
Requires(pre): shadow-utils
|
||||
%endif
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
Requires(post): systemd-units
|
||||
Requires(preun): systemd-units
|
||||
Requires(postun): systemd-units
|
||||
%endif
|
||||
|
||||
BuildRequires: gcc
|
||||
BuildRequires: gd-devel > 1.8
|
||||
BuildRequires: zlib-devel
|
||||
BuildRequires: libpng-devel
|
||||
BuildRequires: libjpeg-devel
|
||||
BuildRequires: libdbi-devel
|
||||
BuildRequires: perl(ExtUtils::Embed)
|
||||
BuildRequires: make
|
||||
### Requires: nagios-plugins
|
||||
BuildRequires: %{apachename}
|
||||
%if "%{_vendor}" == "suse"
|
||||
BuildRequires: libopenssl-devel
|
||||
%endif
|
||||
|
||||
|
||||
|
||||
%description
|
||||
Icinga is an application, system and network monitoring application.
|
||||
It can escalate problems by email, pager or any other medium. It is
|
||||
also useful for incident or SLA reporting.
|
||||
|
||||
Icinga is written in C and is designed as a background process,
|
||||
intermittently running checks on various services that you specify.
|
||||
|
||||
The actual service checks are performed by separate "plugin" programs
|
||||
which return the status of the checks to Icinga.
|
||||
|
||||
Icinga is a fork of the nagios project.
|
||||
|
||||
%package gui
|
||||
Summary: Classic UI for %{name}
|
||||
Group: Applications/System
|
||||
Requires: %{apachename}
|
||||
Requires: %{name}-doc = %{version}-%{release}
|
||||
Requires: %{name}-classicui-config = %{version}-%{release}
|
||||
|
||||
%description gui
|
||||
This package contains the Classic UI for %{name}. Requires %{name}-doc
|
||||
for the documentation module.
|
||||
|
||||
%package gui-config
|
||||
Summary: Classic UI configuration for %{name}
|
||||
Group: Applications/System
|
||||
Requires: %{apachename}
|
||||
Provides: %{name}-classicui-config
|
||||
Conflicts: icinga2-classicui-config
|
||||
|
||||
%description gui-config
|
||||
This packages contains the classic ui configuration for %{name}.
|
||||
|
||||
|
||||
%package devel
|
||||
Summary: Provides include files that Icinga-related applications may compile against
|
||||
Group: Development/Libraries
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
This package provides include files that Icinga-related applications
|
||||
may compile against.
|
||||
|
||||
%package idoutils
|
||||
Summary: transitional package, use idoutils-libdbi-* instead
|
||||
Group: Applications/System
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: %{name}-idoutils-libdbi-mysql = %{version}-%{release}
|
||||
|
||||
%description idoutils
|
||||
Transitional package. Idoutils has been splitted into
|
||||
idoutils-libdbi-mysql and idoutils-libdbi-pgsql. Use one
|
||||
of these. This package pulls in idoutils-libdbi-mysql.
|
||||
This package can be safely uninstalled, it provides no
|
||||
files and nothing depends on it.
|
||||
|
||||
%package idoutils-libdbi-mysql
|
||||
Summary: database broker module for %{name}
|
||||
Group: Applications/System
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
%if 0%{?suse_version} >= 1210
|
||||
# opensuse
|
||||
Requires: libdbi-drivers-dbd-mysql
|
||||
%else
|
||||
Requires: libdbi-dbd-mysql
|
||||
%endif
|
||||
Conflicts: %{name}-idoutils-libdbi-pgsql
|
||||
|
||||
%description idoutils-libdbi-mysql
|
||||
This package contains the idoutils broker module for %{name} which provides
|
||||
database storage via libdbi and mysql.
|
||||
|
||||
%package idoutils-libdbi-pgsql
|
||||
Summary: database broker module for %{name}
|
||||
Group: Applications/System
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
%if 0%{?suse_version} >= 1210
|
||||
# opensuse
|
||||
Requires: libdbi-drivers-dbd-pgsql
|
||||
%else
|
||||
Requires: libdbi-dbd-pgsql
|
||||
%endif
|
||||
Conflicts: %{name}-idoutils-libdbi-mysql
|
||||
|
||||
%description idoutils-libdbi-pgsql
|
||||
This package contains the idoutils broker module for %{name} which provides
|
||||
database storage via libdbi and pgsql.
|
||||
|
||||
|
||||
%package doc
|
||||
Summary: documentation %{name}
|
||||
Group: Documentation
|
||||
|
||||
%description doc
|
||||
Documentation for %{name}
|
||||
|
||||
|
||||
%prep
|
||||
%setup -qn %{name}-%{version}
|
||||
%patch0
|
||||
|
||||
cat << EOF > README.idoutils.transitional
|
||||
Transitional package. Idoutils has been splitted into
|
||||
idoutils-libdbi-mysql and idoutils-libdbi-pgsql. Use one
|
||||
of these. This package pulls in idoutils-libdbi-mysql.
|
||||
This package can be safely uninstalled, it provides no
|
||||
files and nothing depends on it.
|
||||
EOF
|
||||
|
||||
%build
|
||||
%configure \
|
||||
--prefix=%{_datadir}/%{name} \
|
||||
--exec-prefix=%{_localstatedir}/lib/%{name} \
|
||||
--datadir="%{_datadir}/%{name}" \
|
||||
--datarootdir="%{_datadir}/%{name}" \
|
||||
--libexecdir="%{plugindir}" \
|
||||
--localstatedir="%{_localstatedir}/%{name}" \
|
||||
--libdir="%{_libdir}/%{name}" \
|
||||
--sbindir="%{_libdir}/%{name}/cgi" \
|
||||
--sysconfdir="%{_sysconfdir}/%{name}" \
|
||||
--with-gd-lib="%{_libdir}" \
|
||||
--with-gd-inc="%{_includedir}" \
|
||||
--with-htmurl="/icinga" \
|
||||
--with-cgiurl="/%{name}/cgi-bin" \
|
||||
--with-mainurl="/%{name}/cgi-bin/status.cgi?host=all&type=detail&servicestatustypes=29" \
|
||||
--with-init-dir="%{_initrddir}" \
|
||||
--with-lockfile="%{_localstatedir}/run/%{name}.pid" \
|
||||
--with-mail="/bin/mail" \
|
||||
--with-icinga-user="icinga" \
|
||||
--with-icinga-group="icinga" \
|
||||
--enable-event-broker \
|
||||
--enable-embedded-perl \
|
||||
--enable-idoutils \
|
||||
--with-httpd-conf=%{apacheconfdir} \
|
||||
--with-log-dir=%{logdir} \
|
||||
--enable-cgi-log \
|
||||
--with-cgi-log-dir=%{logdir}/gui \
|
||||
--with-plugin-dir="%{plugindir}" \
|
||||
--with-eventhandler-dir="%{_libdir}/%{name}/eventhandlers" \
|
||||
--with-p1-file-dir="%{_libdir}/%{name}" \
|
||||
--with-checkresult-dir="%{spooldir}/checkresults" \
|
||||
--with-ext-cmd-file-dir="%{extcmdfiledir}" \
|
||||
--with-http-auth-file="%{_sysconfdir}/%{name}/passwd" \
|
||||
--with-icinga-chkfile="%{spooldir}/icinga.chk" \
|
||||
--with-ido2db-lockfile="%{_localstatedir}/run/ido2db.pid" \
|
||||
--with-ido-sockfile="%{spooldir}/ido.sock" \
|
||||
--with-idomod-tmpfile="%{spooldir}/idomod.tmp" \
|
||||
--with-state-dir="%{spooldir}"
|
||||
|
||||
%{__make} %{?_smp_mflags} all
|
||||
|
||||
%install
|
||||
%{__rm} -rf %{buildroot}
|
||||
%{__mkdir} -p %{buildroot}/%{apacheconfdir}
|
||||
|
||||
# Our make install invocation will differ depending on whether or not we're
|
||||
# using systemd.
|
||||
# without: make ... install-init ...
|
||||
# with: make ... install-systemd ...
|
||||
%if 0%{?using_systemd}
|
||||
%define init_install systemd
|
||||
%else
|
||||
%define init_install init
|
||||
%endif
|
||||
|
||||
%{__make} install-unstripped \
|
||||
install-%{init_install} \
|
||||
install-commandmode \
|
||||
install-config \
|
||||
install-webconf \
|
||||
install-idoutils \
|
||||
install-eventhandlers \
|
||||
install-downtimes \
|
||||
DESTDIR="%{buildroot}" \
|
||||
INSTALL_OPTS="" \
|
||||
INSTALL_OPTS_WEB="" \
|
||||
COMMAND_OPTS="" \
|
||||
INIT_OPTS=""
|
||||
|
||||
### strip binary
|
||||
%{__strip} %{buildroot}%{_bindir}/{icinga,icingastats,log2ido,ido2db}
|
||||
%{__strip} %{buildroot}%{_libdir}/icinga/cgi/*.cgi
|
||||
|
||||
### move idoutils sample configs to final name
|
||||
mv %{buildroot}%{_sysconfdir}/icinga/ido2db.cfg-sample %{buildroot}%{_sysconfdir}/icinga/ido2db.cfg
|
||||
mv %{buildroot}%{_sysconfdir}/icinga/idomod.cfg-sample %{buildroot}%{_sysconfdir}/icinga/idomod.cfg
|
||||
mv %{buildroot}%{_sysconfdir}/icinga/modules/idoutils.cfg-sample %{buildroot}%{_sysconfdir}/icinga/modules/idoutils.cfg
|
||||
|
||||
### remove icinga-api
|
||||
%{__rm} -rf %{buildroot}%{_datadir}/icinga/icinga-api
|
||||
|
||||
# install logrotate rule
|
||||
install -D -m 0644 icinga.logrotate %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
|
||||
|
||||
# install sample htpasswd file
|
||||
install -D -m 0644 icinga.htpasswd %{buildroot}%{_sysconfdir}/%{name}/passwd
|
||||
|
||||
# install headers for development package
|
||||
install -d -m0755 "%{buildroot}%{_includedir}/%{name}/"
|
||||
install -m0644 include/*.h "%{buildroot}%{_includedir}/%{name}"
|
||||
|
||||
# create perfdata dir by default
|
||||
install -d -m0755 "%{buildroot}%{_localstatedir}/spool/%{name}/perfdata"
|
||||
|
||||
%pre
|
||||
# Add icinga user
|
||||
%{_sbindir}/groupadd -r icinga 2> /dev/null || :
|
||||
%{_sbindir}/groupadd -r icingacmd 2> /dev/null || :
|
||||
%{_sbindir}/useradd -c "icinga" -s /sbin/nologin -r -d %{_localstatedir}/spool/%{name} -G icingacmd -g icinga icinga 2> /dev/null || :
|
||||
|
||||
|
||||
%post
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?systemd_macro_scriptlet}
|
||||
%systemd_post icinga.service
|
||||
%else
|
||||
# manual systemd scriptlet
|
||||
if [ $1 -eq 1 ] ; then
|
||||
# Initial installation
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
%else
|
||||
# No systemd, just plain old sysvinit
|
||||
/sbin/chkconfig --add icinga
|
||||
%endif
|
||||
|
||||
# restart httpd for auth change
|
||||
/sbin/service %{apachename} condrestart > /dev/null 2>&1 || :
|
||||
|
||||
# start icinga
|
||||
/sbin/service icinga start &>/dev/null || :
|
||||
|
||||
%preun
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?systemd_macro_scriptlet}
|
||||
%systemd_preun icinga.service
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
# manual systemd scriptlet
|
||||
# Package removal, not upgrade
|
||||
/bin/systemctl --no-reload disable icinga.service > /dev/null 2>&1 || :
|
||||
/bin/systemctl stop icinga.service > /dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
# No systemd, just plain old sysvinit
|
||||
/sbin/service icinga stop &>/dev/null || :
|
||||
/sbin/chkconfig --del icinga
|
||||
fi
|
||||
%endif
|
||||
|
||||
%postun
|
||||
/sbin/service %{apachename} condrestart > /dev/null 2>&1 || :
|
||||
|
||||
%pre gui
|
||||
# Add apacheuser in the icingacmd group
|
||||
# If the group exists, add the apacheuser in the icingacmd group.
|
||||
# It is not neccessary that icinga-cgi is installed on the same system as
|
||||
# icinga 1.x and only on systems with icinga installed the icingacmd
|
||||
# group exists.
|
||||
getent group icingacmd > /dev/null
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
%if "%{_vendor}" == "suse"
|
||||
%{_sbindir}/usermod -G icingacmd %{apacheuser}
|
||||
%else
|
||||
%{_sbindir}/usermod -a -G icingacmd %{apacheuser}
|
||||
%endif
|
||||
fi
|
||||
|
||||
%post idoutils-libdbi-mysql
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?systemd_macro_scriptlet}
|
||||
%systemd_post ido2db.service
|
||||
%else
|
||||
# manual systemd scriptlet
|
||||
if [ $1 -eq 1 ] ; then
|
||||
# Initial installation
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
%else
|
||||
# No systemd, just plain old sysvinit
|
||||
/sbin/chkconfig --add ido2db
|
||||
%endif
|
||||
|
||||
%logmsg "idoutils-libdbi-mysql installed. don't forget to install/upgrade db schema, check %{readmeido}"
|
||||
|
||||
%preun idoutils-libdbi-mysql
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?systemd_macro_scriptlet}
|
||||
%systemd_preun ido2db.service
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
# manual systemd scriptlet
|
||||
# Package removal, not upgrade
|
||||
/bin/systemctl --no-reload disable ido2db.service > /dev/null 2>&1 || :
|
||||
/bin/systemctl stop ido2db.service > /dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
# No systemd, just plain old sysvinit
|
||||
/sbin/service ido2db stop &>/dev/null || :
|
||||
/sbin/chkconfig --del ido2db
|
||||
fi
|
||||
%endif
|
||||
|
||||
%post idoutils-libdbi-pgsql
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?systemd_macro_scriptlet}
|
||||
%systemd_post ido2db.service
|
||||
%else
|
||||
# manual systemd scriptlet
|
||||
if [ $1 -eq 1 ] ; then
|
||||
# Initial installation
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
%else
|
||||
# No systemd, just plain old sysvinit
|
||||
/sbin/chkconfig --add ido2db
|
||||
%endif
|
||||
|
||||
### change ido2db.cfg to match pgsql config
|
||||
# check if this is an upgrade
|
||||
if [ $1 -eq 2 ]
|
||||
then
|
||||
%{__cp} %{_sysconfdir}/icinga/ido2db.cfg %{_sysconfdir}/icinga/ido2db.cfg.pgsql
|
||||
%{__perl} -pi -e '
|
||||
s|db_servertype=mysql|db_servertype=pgsql|;
|
||||
s|db_port=3306|db_port=5432|;
|
||||
' %{_sysconfdir}/icinga/ido2db.cfg.pgsql
|
||||
%logmsg "Warning: upgrade, pgsql config written to ido2db.cfg.pgsql"
|
||||
fi
|
||||
# install
|
||||
if [ $1 -eq 1 ]
|
||||
then
|
||||
%{__perl} -pi -e '
|
||||
s|db_servertype=mysql|db_servertype=pgsql|;
|
||||
s|db_port=3306|db_port=5432|;
|
||||
' %{_sysconfdir}/icinga/ido2db.cfg
|
||||
fi
|
||||
|
||||
%logmsg "idoutils-libdbi-pgsql installed. don't forget to install/upgrade db schema, check %{readmeido}"
|
||||
|
||||
|
||||
%preun idoutils-libdbi-pgsql
|
||||
|
||||
%if 0%{?using_systemd}
|
||||
%if 0%{?systemd_macro_scriptlet}
|
||||
%systemd_preun ido2db.service
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
# manual systemd scriptlet
|
||||
# Package removal, not upgrade
|
||||
/bin/systemctl --no-reload disable ido2db.service > /dev/null 2>&1 || :
|
||||
/bin/systemctl stop ido2db.service > /dev/null 2>&1 || :
|
||||
fi
|
||||
%endif
|
||||
%else
|
||||
if [ $1 -eq 0 ]; then
|
||||
# No systemd, just plain old sysvinit
|
||||
/sbin/service ido2db stop &>/dev/null || :
|
||||
/sbin/chkconfig --del ido2db
|
||||
fi
|
||||
%endif
|
||||
|
||||
|
||||
%clean
|
||||
%{__rm} -rf %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.md LICENSE Changelog UPGRADING %{readme}
|
||||
%if 0%{?using_systemd}
|
||||
%attr(755,-,-) %{_unitdir}/icinga.service
|
||||
%attr(644,-,-) %{_sysconfdir}/sysconfig/icinga
|
||||
%else
|
||||
%attr(755,-,-) %{_initrddir}/icinga
|
||||
%endif
|
||||
%dir %{_sysconfdir}/%{name}
|
||||
%dir %{_sysconfdir}/%{name}/modules
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/icinga.cfg
|
||||
%dir %{_sysconfdir}/%{name}/objects
|
||||
%dir %{_sysconfdir}/%{name}/conf.d
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/commands.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/contacts.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/notifications.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/localhost.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/printer.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/switch.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/templates.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/timeperiods.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/windows.cfg
|
||||
%config(noreplace) %attr(640,icinga,icinga) %{_sysconfdir}/%{name}/resource.cfg
|
||||
%config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
|
||||
%attr(755,-,-) %{_bindir}/icinga
|
||||
%attr(755,-,-) %{_bindir}/icingastats
|
||||
%attr(755,-,-) %{_libdir}/icinga/p1.pl
|
||||
%{_libdir}/%{name}/eventhandlers
|
||||
%{plugindir}/downtimes
|
||||
%defattr(-,icinga,icinga,-)
|
||||
%dir %{logdir}
|
||||
%dir %{logdir}/archives
|
||||
%dir %{_localstatedir}/spool/%{name}
|
||||
%dir %{_localstatedir}/spool/%{name}/perfdata
|
||||
%dir %{_localstatedir}/spool/%{name}/checkresults
|
||||
%attr(2755,icinga,icingacmd) %{extcmdfiledir}
|
||||
|
||||
%files doc
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.md LICENSE Changelog UPGRADING %{readme}
|
||||
%{_datadir}/%{name}/docs
|
||||
|
||||
%files gui
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.md LICENSE Changelog UPGRADING %{readme}
|
||||
%{_libdir}/%{name}/cgi/avail.cgi
|
||||
%{_libdir}/%{name}/cgi/cmd.cgi
|
||||
%{_libdir}/%{name}/cgi/config.cgi
|
||||
%{_libdir}/%{name}/cgi/extinfo.cgi
|
||||
%{_libdir}/%{name}/cgi/histogram.cgi
|
||||
%{_libdir}/%{name}/cgi/history.cgi
|
||||
%{_libdir}/%{name}/cgi/notifications.cgi
|
||||
%{_libdir}/%{name}/cgi/outages.cgi
|
||||
%{_libdir}/%{name}/cgi/showlog.cgi
|
||||
%{_libdir}/%{name}/cgi/status.cgi
|
||||
%{_libdir}/%{name}/cgi/statusmap.cgi
|
||||
%{_libdir}/%{name}/cgi/summary.cgi
|
||||
%{_libdir}/%{name}/cgi/tac.cgi
|
||||
%{_libdir}/%{name}/cgi/trends.cgi
|
||||
%dir %{_datadir}/%{name}
|
||||
%{_datadir}/%{name}/images
|
||||
%{_datadir}/%{name}/index.html
|
||||
%{_datadir}/%{name}/js
|
||||
%{_datadir}/%{name}/main.html
|
||||
%{_datadir}/%{name}/media
|
||||
%{_datadir}/%{name}/menu.html
|
||||
%{_datadir}/%{name}/robots.txt
|
||||
%{_datadir}/%{name}/ssi
|
||||
%{_datadir}/%{name}/stylesheets
|
||||
%{_datadir}/%{name}/jquery-ui
|
||||
%{_datadir}/%{name}/jquery-ui-addon
|
||||
%attr(2775,icinga,icingacmd) %dir %{logdir}/gui
|
||||
%attr(664,icinga,icingacmd) %{logdir}/gui/index.htm
|
||||
%attr(664,icinga,icingacmd) %{logdir}/gui/.htaccess
|
||||
|
||||
%files gui-config
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.md LICENSE Changelog UPGRADING %{readme}
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/cgi.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/cgiauth.cfg
|
||||
%config(noreplace) %{apacheconfdir}/icinga.conf
|
||||
%config(noreplace) %attr(0640,root,%{apachegroup}) %{_sysconfdir}/%{name}/passwd
|
||||
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%{_includedir}/%{name}/
|
||||
|
||||
%files idoutils
|
||||
%defattr(-,root,root)
|
||||
%doc README.idoutils.transitional
|
||||
|
||||
%files idoutils-libdbi-mysql
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.md LICENSE Changelog UPGRADING module/idoutils/db %{readme} %{readmeido}
|
||||
%if 0%{?using_systemd}
|
||||
%attr(644,-,-) %{_unitdir}/ido2db.service
|
||||
%else
|
||||
%attr(755,-,-) %{_initrddir}/ido2db
|
||||
%endif
|
||||
%attr(660,root,root) %config(noreplace) %{_sysconfdir}/%{name}/ido2db.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/idomod.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/modules/idoutils.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/ido2db_check_proc.cfg
|
||||
%{_bindir}/ido2db
|
||||
%{_bindir}/log2ido
|
||||
%{_libdir}/%{name}/idomod.so
|
||||
|
||||
%files idoutils-libdbi-pgsql
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.md LICENSE Changelog UPGRADING module/idoutils/db %{readme} %{readmeido}
|
||||
%if 0%{?using_systemd}
|
||||
%attr(644,-,-) %{_unitdir}/ido2db.service
|
||||
%else
|
||||
%attr(755,-,-) %{_initrddir}/ido2db
|
||||
%endif
|
||||
%attr(660,root,root) %config(noreplace) %{_sysconfdir}/%{name}/ido2db.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/idomod.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/modules/idoutils.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/modules/flapjack.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/modules/livestatus.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/modules/mod_gearman.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/modules/pnp4nagios.cfg
|
||||
%config(noreplace) %{_sysconfdir}/%{name}/objects/ido2db_check_proc.cfg
|
||||
%{_bindir}/ido2db
|
||||
%{_bindir}/log2ido
|
||||
%{_libdir}/%{name}/idomod.so
|
||||
|
||||
|
||||
%changelog
|
||||
76
fedora/SPECS/archive/nconf.spec
Normal file
76
fedora/SPECS/archive/nconf.spec
Normal file
@@ -0,0 +1,76 @@
|
||||
Name: nconf
|
||||
Version: 1.3.1
|
||||
Release: 1%{?dist}
|
||||
Summary: Nagios/Icinga configuration webinterface
|
||||
|
||||
License: GPL
|
||||
URL: http://www.nconf.org
|
||||
Source0: nconf-%{version}.tgz
|
||||
Source1: nconf.conf
|
||||
Source2: mysql.php
|
||||
BuildArch: noarch
|
||||
|
||||
|
||||
Requires: icinga
|
||||
|
||||
%define idir %{_datadir}/%{name}
|
||||
|
||||
%description
|
||||
NConf is a web-based tool which allows users to manage the complete configuration of their Nagios setup.
|
||||
Is is specifically aimed at large environments, but can naturally also be used for small Nagios installations.
|
||||
One of the main benefits is that NConf allows users to define templates and presets,
|
||||
which can be applied when adding hosts. A host-preset contains all services to be added to a host,
|
||||
with all commands linked and all default values already set. It also contains the host-alive-check
|
||||
to be applied to the new host. All a user must do after adding a host is to tweak certain parameters, if necessary.
|
||||
|
||||
A host is always linked to a collector. When the config is generated,
|
||||
all hosts linked to the same collector will be written to a file,
|
||||
including all their services and additional dependencies.
|
||||
Hosts not assigned to the same collector will be written to a different config file.
|
||||
This way, each collector will recieve its own set of config files.
|
||||
It will only monitor hosts assigned to it, all other information is disregarded.
|
||||
This increases performance. Information about all hosts is summarized in the monitor config.
|
||||
Performance is not an issue here, since the monitor server does not do any active checking.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-%{version}
|
||||
|
||||
|
||||
%build
|
||||
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
%{__install} -d %{buildroot}%{idir}
|
||||
%{__install} -d %{buildroot}%{_sysconfdir}/httpd/conf.d
|
||||
cp -r */ %{buildroot}%{idir}
|
||||
cp -r *.php %{buildroot}%{idir}
|
||||
cp %{S:1} %{buildroot}%{_sysconfdir}//httpd/conf.d/%{name}.conf
|
||||
cp %{S:2} %{buildroot}%{idir}/config
|
||||
rm %{buildroot}%{idir}/*/.gitignore
|
||||
|
||||
|
||||
%files
|
||||
%defattr(0644,root,root,0755)
|
||||
%doc README CHANGELOG LICENSE
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf
|
||||
%config(noreplace) %{idir}/config/mysql.php
|
||||
%{idir}/*.php
|
||||
%{idir}/INSTALL
|
||||
%{idir}/UPDATE
|
||||
%{idir}/ADD-ONS
|
||||
%{idir}/bin
|
||||
%{idir}/config.orig
|
||||
%{idir}/design_templates
|
||||
%{idir}/img
|
||||
%{idir}/include
|
||||
%dir %attr(0755,apache,apache) %{idir}/config
|
||||
%dir %attr(0755,apache,apache) %{idir}/output
|
||||
%dir %attr(0755,apache,apache) %{idir}/static_cfg
|
||||
%dir %attr(0755,apache,apache) %{idir}/temp
|
||||
|
||||
|
||||
|
||||
%changelog
|
||||
* Sat Dec 7 2013 <elpito@bluewin.ch>
|
||||
- New package.
|
||||
354
fedora/SPECS/archive/owncloud-files.spec
Normal file
354
fedora/SPECS/archive/owncloud-files.spec
Normal file
@@ -0,0 +1,354 @@
|
||||
#
|
||||
# spec file for package owncloud-files
|
||||
#
|
||||
# Copyright (c) 2012-2016 ownCloud, Inc.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes, issues or comments via http://github.com/owncloud/
|
||||
#
|
||||
|
||||
# name used as apache alias and topdir for php code.
|
||||
%define owncloud owncloud
|
||||
|
||||
# CAUTION: keep in sync with debian.rules
|
||||
%define apache_serverroot /var/www/html
|
||||
%define apache_confdir /etc/httpd/conf.d
|
||||
%define oc_user apache
|
||||
%define oc_group apache
|
||||
|
||||
# CAUTION: keep in sync with debian.rules
|
||||
%define oc_dir %{apache_serverroot}/%{owncloud}
|
||||
%define oc_config_dir %{oc_dir}/config
|
||||
%define oc_data_dir %{oc_dir}/data
|
||||
%define oc_data_pdir %{oc_dir}
|
||||
|
||||
Name: owncloud-files
|
||||
|
||||
# Downloaded from http://download.owncloud.com/internal/8.2.1/owncloud-complete-8.2.1.tar.bz2
|
||||
# Downloaded from http://download.owncloud.com/internal/8.2.2RC1/owncloud-complete-8.2.2RC1.tar.bz2
|
||||
|
||||
## define prerelease % nil, if this is *not* a prerelease.
|
||||
%define prerelease %nil
|
||||
%define base_version 9.0.0
|
||||
|
||||
%if 0%{?centos_version} == 600 || 0%{?fedora_version} || "%{prerelease}" == ""
|
||||
# For beta and rc versions we use the ~ notation, as documented in
|
||||
# http://en.opensuse.org/openSUSE:Package_naming_guidelines
|
||||
Version: %{base_version}
|
||||
%if "%{prerelease}" == ""
|
||||
Release: 1.1
|
||||
%else
|
||||
Release: 0.1.1.%{prerelease}
|
||||
%endif
|
||||
%else
|
||||
Version: %{base_version}~%{prerelease}
|
||||
Release: 1.1
|
||||
%endif
|
||||
|
||||
# http://owncloud:owncloud42@download.owncloud.com/internal/8.2.2/owncloud-complete-8.2.2.tar.bz2
|
||||
Source0: http://download.owncloud.org/community/owncloud-9.0.0.tar.bz2
|
||||
Source1: apache_conf_default
|
||||
Source2: README
|
||||
Source4: README.packaging
|
||||
Source5: disable-updatechecker.config.php
|
||||
Url: http://www.owncloud.org
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildArch: noarch
|
||||
Summary: The ownCloud Server - Private file sync and share server
|
||||
License: AGPL-3.0 and MIT
|
||||
Group: Productivity/Networking/Web/Utilities
|
||||
|
||||
%if 0%{?suse_version}
|
||||
BuildRequires: fdupes
|
||||
Recommends: owncloud-deps
|
||||
%endif
|
||||
|
||||
%if "%{?_repository}" == "openSUSE_Tumbleweed"
|
||||
# disable rpmlint for Tumbleweed while it is broken.
|
||||
# It has random errors like these:
|
||||
# IOError: [Errno 2] No such file or directory: '/tmp/rpmlint.owncloud-ee-base-8.2.2-1.1.noarch.rpm.zFc3ft/usr/share/owncloud/apps/files_external/tests/env/stop-smb-silvershell.sh'
|
||||
|
||||
BuildRequires: -rpmlint -rpmlint-mini
|
||||
%endif
|
||||
|
||||
Obsoletes: owncloud < 8.99.99
|
||||
Obsoletes: owncloud-server < 8.99.99
|
||||
Obsoletes: owncloud-config-apache < 8.99.99
|
||||
Obsoletes: owncloud < 8.99.99
|
||||
|
||||
%description
|
||||
ownCloud Server provides you a private file sync and share
|
||||
cloud. Host this server to easily sync business or private documents
|
||||
across all your devices, and share those documents with other users of
|
||||
your ownCloud server on their devices.
|
||||
|
||||
This package installs as follows:
|
||||
oc_dir: %{oc_dir}
|
||||
oc_data_dir: %{oc_data_dir}
|
||||
oc_config_dir: %{oc_config_dir}
|
||||
|
||||
ownCloud - Your Cloud, Your Data, Your Way! www.owncloud.org
|
||||
|
||||
#####################################################
|
||||
|
||||
%prep
|
||||
%setup -q -n owncloud
|
||||
cp %{SOURCE1} .
|
||||
cp %{SOURCE2} .
|
||||
cp %{SOURCE4} .
|
||||
#%%patch0 -p0
|
||||
|
||||
## remove .bower.json .bowerrc .gitattributes .gitmodules
|
||||
# find . -name .bower\* -print -o -name .git\* -print | xargs -r rm -rf
|
||||
|
||||
%build
|
||||
|
||||
%install
|
||||
# no server side java code contained, alarm is false
|
||||
export NO_BRP_CHECK_BYTECODE_VERSION=true
|
||||
idir=$RPM_BUILD_ROOT/%{oc_dir}
|
||||
mkdir -p $RPM_BUILD_ROOT/%{oc_dir}
|
||||
mkdir -p $RPM_BUILD_ROOT/%{oc_dir}/etc
|
||||
mkdir -p $RPM_BUILD_ROOT/%{oc_data_dir}
|
||||
mkdir -p $RPM_BUILD_ROOT/%{oc_config_dir}
|
||||
mkdir -p $RPM_BUILD_ROOT/%{oc_dir}/core/skeleton
|
||||
|
||||
cp -aRf .htaccess .user.ini * $idir
|
||||
rm -f $idir/debian.*{install,rules,control}
|
||||
rm -f $idir/README{,.SELinux,.packaging}
|
||||
sed -e 's@/var/www/owncloud@%{oc_dir}/owncloud@' < $idir/apache_conf_default > owncloud-config-apache.conf.default
|
||||
rm -f $idir/apache_conf_default
|
||||
|
||||
## https://github.com/owncloud/core/issues/22257
|
||||
# disable-updatechecker.config.php
|
||||
cp %{SOURCE5} $idir/config/
|
||||
|
||||
## can we do proper groups user during install? No, we are in a build enironment, non-root user.
|
||||
# find $idir/apps $idir/data $idir/config -print0 | xargs -0 chown % {oc_user}:% {oc_group}
|
||||
# find $idir/apps $idir/data $idir/config -type d -print0 | xargs -0 chmod 0775
|
||||
# find $idir/apps $idir/data $idir/config -type f -print0 | xargs -0 chmod 0664
|
||||
|
||||
|
||||
%if 0%{?suse_version}
|
||||
# link duplicate doc files
|
||||
%fdupes -s $RPM_BUILD_ROOT/%{oc_dir}
|
||||
%endif
|
||||
|
||||
%clean
|
||||
rm -rf "$RPM_BUILD_ROOT"
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc README README.packaging owncloud-config-apache.conf.default
|
||||
|
||||
# is there any security to be gained here? Easier to chown everthing to % {oc_user}
|
||||
%defattr(0644,root,%{oc_group},0755)
|
||||
%attr(0755,%{oc_user},%{oc_group}) %{oc_dir}/occ
|
||||
%attr(0775,%{oc_user},%{oc_group}) %{oc_dir}/apps
|
||||
%attr(0775,%{oc_user},%{oc_group}) %{oc_data_dir}
|
||||
%attr(0775,%{oc_user},%{oc_group}) %{oc_config_dir}
|
||||
# BUMMER: exclude excludes globally, not just below. It cannot be used to avoid duplicate warnings?
|
||||
# FIXME: only cure against the duplicate warnings is a -f file-list
|
||||
%{oc_dir}
|
||||
|
||||
%changelog
|
||||
* Tue Mar 8 2016 jw@owncloud.com
|
||||
- update to 9.0.0
|
||||
* Mon Mar 7 2016 jw@owncloud.com
|
||||
- update to 9.0.0~RC3
|
||||
* Sat Mar 5 2016 jw@owncloud.com
|
||||
- update to 9.0.0~RC2
|
||||
* Thu Mar 3 2016 jw@owncloud.com
|
||||
- retain dotfiles https://github.com/owncloud/core/issues/22803
|
||||
* Thu Mar 3 2016 jw@owncloud.com
|
||||
- fix https://github.com/owncloud/core/issues/22804
|
||||
* Wed Mar 2 2016 jw@owncloud.com
|
||||
- update to 9.0.0~RC1
|
||||
* Wed Feb 24 2016 jw@owncloud.com
|
||||
- fixed default file ownership in RPM to be apache.
|
||||
CentOS_7 just failed with unwritable config folder again.
|
||||
* Wed Feb 24 2016 jw@owncloud.com
|
||||
- obsoletes in spec changed to < 8.99.99
|
||||
* Fri Feb 19 2016 jw@owncloud.com
|
||||
- survive integrity checks. see ee:9.0:testing for details
|
||||
* Fri Feb 19 2016 jw@owncloud.com
|
||||
- update to 9.0.0 beta2
|
||||
* Tue Feb 16 2016 jw@owncloud.com
|
||||
- apps, data, config directories had no x-bits
|
||||
* Fri Feb 12 2016 jw@owncloud.com
|
||||
- added disable-updatechecker.config.php -- this is the correct solution for
|
||||
https://github.com/owncloud/core/issues/22257
|
||||
* Fri Feb 12 2016 jw@owncloud.com
|
||||
- help https://github.com/owncloud/core/issues/22257
|
||||
* Thu Feb 11 2016 jw@owncloud.com
|
||||
- survive bad broken rpmlint on openSUSE_Tumbleweed
|
||||
* Thu Feb 11 2016 jw@owncloud.com
|
||||
- initial 9.0 setup: owncloud-enterprise-files
|
||||
- must not include .gitkeep or .gitignore files.
|
||||
* Thu Feb 4 2016 jw@owncloud.com
|
||||
- made file system layout compatible with tar/zip installations,
|
||||
preparing for owncloud-deps sub-package.
|
||||
* Tue Dec 22 2015 jw@owncloud.com
|
||||
- Updated to 8.2.2
|
||||
* Wed Dec 16 2015 jw@owncloud.com
|
||||
- Updated to 8.2.2~RC1
|
||||
* Fri Dec 4 2015 jw@owncloud.com
|
||||
- typo in etc/owncloud-config-apache.conf.default fixed.
|
||||
Thanks JP.
|
||||
* Thu Dec 3 2015 jw@owncloud.com
|
||||
- New package: owncloud-ee-base without dependencies.
|
||||
- Replaces, Conflicts, Obsoletes all other owncloud-* packages << 8.2.2
|
||||
- improved apache_config_default
|
||||
- dropped htaccess re-added.
|
||||
* Tue Nov 17 2015 jenkins@owncloud.com
|
||||
- Update to version 8.2.1
|
||||
* Tue Nov 17 2015 jenkins@owncloud.com
|
||||
- Update to version 8.2.1~RC4
|
||||
* Fri Nov 13 2015 jw@owncloud.com
|
||||
- Update to version 8.2.1~RC3
|
||||
- added app-password_policy subpackage
|
||||
* Wed Nov 11 2015 jenkins@owncloud.com
|
||||
- Update to version 8.2.1~RC2
|
||||
* Wed Nov 4 2015 jw@owncloud.com
|
||||
- Update to version 8.2.1~RC1
|
||||
* Fri Sep 18 2015 jw@owncloud.com
|
||||
- Update to version 8.2~beta1
|
||||
* Mon Sep 14 2015 jw@owncloud.com
|
||||
- Require owncloud-server, instead of a virtual owncloud-enterprise-server.
|
||||
* Fri Sep 11 2015 jw@owncloud.com
|
||||
- Update to version 8.1.3
|
||||
* Fri Sep 4 2015 jw@owncloud.com
|
||||
- Updated ownCloudServerAdminManual.pdf
|
||||
* Wed Sep 2 2015 jw@owncloud.com
|
||||
- Update to version 8.1.2
|
||||
* Sun Aug 30 2015 jw@owncloud.com
|
||||
- Update to version 8.1.2~RC1
|
||||
* Fri Aug 14 2015 jw@owncloud.com
|
||||
- softwarecollections rh-scl have renamed their packages: rh-php56-php
|
||||
* Sat Aug 8 2015 jw@owncloud.com
|
||||
- Update to version 8.1.1
|
||||
* Sat Aug 8 2015 jw@owncloud.com
|
||||
- RPM: Do not hard require mysql locally. That is not realistic for enterprise.
|
||||
DEB does not have that requirement anyway.
|
||||
- Using %%{ocphp} to select the correct php version.
|
||||
- fixed https://github.com/owncloud/core/issues/16132
|
||||
- Updated ownCloudServerAdminManual.pdf
|
||||
* Mon Aug 3 2015 jw@owncloud.com
|
||||
- Update to version 8.1.1~RC1
|
||||
* Fri Jul 24 2015 jw@owncloud.com
|
||||
- Update to version 8.1.1~beta1
|
||||
* Mon Jul 13 2015 jw@owncloud.com
|
||||
- Updated ownCloudServerAdminManual.pdf
|
||||
* Fri Jul 3 2015 jw@owncloud.com
|
||||
- Update to version 8.1.0
|
||||
* Wed Jul 1 2015 jw@owncloud.com
|
||||
- Version number patched back to 3 digits 8.1.0~RC2
|
||||
* Wed Jul 1 2015 jw@ownCloud.com
|
||||
- Update to version 8.1~RC2
|
||||
* Tue Jun 2 2015 jw@owncloud.com
|
||||
- fixed https://github.com/owncloud/core/issues/16132
|
||||
* Tue May 19 2015 jw@owncloud.com
|
||||
- Updated to 8.1.0~Beta2
|
||||
* Mon May 11 2015 jw@owncloud.com
|
||||
- https://github.com/owncloud/core/issues/16204
|
||||
Fix install on CentOS_6@SCL-PHP54
|
||||
* Fri May 8 2015 jw@owncloud.com
|
||||
- Updated to 8.1.0~Beta1
|
||||
* Thu Apr 23 2015 jw@owncloud.com
|
||||
- Updated to 8.1.0~Alpha2
|
||||
- Added app: files_drop
|
||||
- Removed app: search_elastic
|
||||
* Thu Apr 16 2015 jw@owncloud.com
|
||||
- Updated to 8.1.0~Alpha1
|
||||
- Added app: search_elastic
|
||||
* Thu Apr 16 2015 jw@owncloud.com
|
||||
- Update to 8.0.3 RC2
|
||||
* Sat Mar 28 2015 jw@owncloud.com
|
||||
- Release "8.0.3" April 6. 2015
|
||||
- Fix several Constrain Violation Exceptions
|
||||
- Fix misleading Maintenance mode message
|
||||
- Timezone fixes for countries with .05 and 0.75 offsets
|
||||
- Fix usage of default share folder location
|
||||
- Improved MSSQL compatibility
|
||||
- Reenable trashbin after failed rename
|
||||
- Fix disabling of APCu
|
||||
- Do not show update notification on mobile
|
||||
- Fix "Only variables should be passed by reference" error log spam
|
||||
- Add timeout to curl
|
||||
- Makes repair errors and warnings visible for the user when
|
||||
- Upgrading on the command line or in the web UI
|
||||
- Cron shall not operate in case we are in maintenance mode
|
||||
- Disable the cache updater when doing the encryption migration
|
||||
- Fix "Error while updating app" error
|
||||
- Internal Server Error after attempting to do "occ files:scan"
|
||||
* Mon Mar 16 2015 jw@owncloud.com
|
||||
- update to 8.0.2
|
||||
- https://github.com/owncloud/enterprise/issues/560
|
||||
* Preinstall check for duplicate installations done.
|
||||
* Migration instructions in README.symlink done.
|
||||
* adopted the DEB upgrade detection algorithm for RPM.
|
||||
- https://github.com/owncloud/enterprise/issues/573
|
||||
* fixed also for debian: virtual Provides did not work with versioned Depends.
|
||||
* Thu Mar 5 2015 jw@owncloud.com
|
||||
- removed ownCloudUserManual.pdf here to avoid a file conflict with owncloud-server
|
||||
* Thu Mar 5 2015 jw@owncloud.com
|
||||
- updated to 8.0.1 Mar 4, 22:41h
|
||||
* Wed Mar 4 2015 jw@owncloud.com
|
||||
- Updated to todays rebuild of 8.0.1 tar ball.
|
||||
Added latest Server and User PDFs.
|
||||
* Wed Mar 4 2015 jw@owncloud.com
|
||||
* Fixing https://github.com/owncloud/enterprise/issues/552
|
||||
better. Do not Require clamav for CentOS and friends.
|
||||
Recommend for openSUSE. Describe the dependency of files_antivirus in the README.
|
||||
* Tue Mar 3 2015 jw@owncloud.com
|
||||
- fixed https://github.com/owncloud/enterprise/issues/552
|
||||
clamav was the last one missing
|
||||
- fixed https://github.com/owncloud/enterprise/issues/549
|
||||
multiple missing dependencies added. We are now more on the side that build or
|
||||
install fails instead of manual post processing.
|
||||
* Mon Mar 2 2015 jw@owncloud.com
|
||||
- updated firewall app.
|
||||
* Mon Mar 2 2015 jw@owncloud.com
|
||||
- Match permissions on owncloud, data, themes, config, apps folders
|
||||
(they exist in both, owncloud and owncloud-enterprise* packages.)
|
||||
CentOS-7 is extremely picky: User, group, and modes must match exactly.
|
||||
* Mon Mar 2 2015 jw@owncloud.com
|
||||
- update to 8.0.1
|
||||
ownCloud app files_drop no longer included.
|
||||
ownCloud app search_elastic dropped.
|
||||
* Wed Feb 18 2015 jw@owncloud.com
|
||||
- enterprise version need not be exaclty the same as server version
|
||||
* Tue Feb 17 2015 jw@owncloud.com
|
||||
- updated to 8.0.0 RC2
|
||||
* Sat Feb 7 2015 jw@owncloud.com
|
||||
- Require owncloud-server-core instead of owncloud-server
|
||||
* Mon Feb 2 2015 jw@owncloud.com
|
||||
- updated to 8.0.0 RC1
|
||||
* Fri Jan 30 2015 jw@owncloud.com
|
||||
- make apps directory writable by oc_user
|
||||
* Thu Jan 29 2015 jw@owncloud.com
|
||||
- added all the RHEL_6_PHP5* build targets.
|
||||
* Thu Jan 29 2015 jw@owncloud.com
|
||||
- owncloud-enterprise-theme must not be build dependency, but must be
|
||||
a runtime dependency for owncloud-enterprise. Exception to the rule!
|
||||
- generated deb metafiles for all subpackages with
|
||||
obs_check_deb_spec.sh
|
||||
* Thu Jan 29 2015 jw@owncloud.com
|
||||
- first completed specfile.
|
||||
- fixed garbage filter .bower and .git .
|
||||
- opensuse needs dir entries in %%files for top and top/apps,
|
||||
all others dont.
|
||||
* Wed Jan 28 2015 jw@owncloud.com
|
||||
- adapted isv:ownCloud:community:8.0/owncloud/owncloud.spec
|
||||
to become owncloud-enterprise.spec here.
|
||||
- removed all unnecessary packages, that are now subpackages here.
|
||||
* Thu Jan 8 2015 jw@owncloud.com
|
||||
- initial draught for ownCloud 8
|
||||
305
fedora/SPECS/archive/owncloud.spec
Normal file
305
fedora/SPECS/archive/owncloud.spec
Normal file
@@ -0,0 +1,305 @@
|
||||
#
|
||||
# spec file for package owncloud
|
||||
#
|
||||
# Copyright (c) 2012-2016 ownCloud, Inc.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes, issues or comments via http://github.com/owncloud/
|
||||
#
|
||||
|
||||
Name: owncloud
|
||||
|
||||
## define prerelease % nil, if this is *not* a prerelease.
|
||||
%define prerelease %nil
|
||||
%define base_version 9.0.0
|
||||
## don't enable support_php7 for now, it takes precendence over scl_php54
|
||||
%define support_php7 0
|
||||
|
||||
%if 0%{?centos_version} == 600 || 0%{?fedora_version} || "%{prerelease}" == ""
|
||||
# For beta and rc versions we use the ~ notation, as documented in
|
||||
# http://en.opensuse.org/openSUSE:Package_naming_guidelines
|
||||
%define oc_version %{base_version}
|
||||
%if "%{prerelease}" == ""
|
||||
%define oc_release 0
|
||||
%else
|
||||
%define oc_release 0.<CI_CNT>.<B_CNT>.%{prerelease}
|
||||
%endif
|
||||
%else
|
||||
%define oc_version %{base_version}~%{prerelease}
|
||||
%define oc_release 0
|
||||
%endif
|
||||
|
||||
Version: %{oc_version}
|
||||
Release: 1.1
|
||||
|
||||
Url: http://www.owncloud.org
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildArch: noarch
|
||||
Summary: The server - private file sync and share server
|
||||
License: AGPL-3.0 and MIT
|
||||
Group: Productivity/Networking/Web/Utilities
|
||||
# No Source0: needed when there are no prep setup build sections.
|
||||
|
||||
Requires: owncloud-files
|
||||
Requires: owncloud-deps
|
||||
|
||||
%description
|
||||
ownCloud Server provides you a private file sync and share
|
||||
cloud. Host this server to easily sync business or private documents
|
||||
across all your devices, and share those documents with other users of
|
||||
your ownCloud server on their devices.
|
||||
|
||||
ownCloud - Your Cloud, Your Data, Your Way! www.owncloud.org
|
||||
|
||||
#####################################################
|
||||
|
||||
%if 0%{?rhel} == 600 || 0%{?rhel_version} == 600 || 0%{?centos_version} == 600
|
||||
%define statedir /var/run
|
||||
%else
|
||||
%define statedir /run
|
||||
%endif
|
||||
|
||||
# CAUTION: keep in sync with debian.rules
|
||||
### apache variables
|
||||
%if 0%{?suse_version}
|
||||
%define nginx_confdir /etc/nginx/conf.d
|
||||
%define apache_serverroot /srv/www/htdocs
|
||||
%define apache_confdir /etc/apache2/conf.d
|
||||
%define oc_user wwwrun
|
||||
%define oc_group www
|
||||
%else
|
||||
%if 0%{?fedora_version} || 0%{?rhel} || 0%{?rhel_version} || 0%{?centos_version}
|
||||
%define nginx_confdir /etc/nginx/conf.d
|
||||
%define apache_serverroot /var/www/html
|
||||
%define apache_confdir /etc/httpd/conf.d
|
||||
%define oc_user apache
|
||||
%define oc_group apache
|
||||
%define __jar_repack 0
|
||||
%else
|
||||
%define nginx_confdir /etc/nginx/conf.d
|
||||
%define apache_serverroot /var/www
|
||||
%define apache_confdir /etc/httpd/conf.d
|
||||
%define oc_user www
|
||||
%define oc_group www
|
||||
%endif
|
||||
%endif
|
||||
## only for backwards compatibility with our 7.0 package layout.
|
||||
%define oc_apache_web_dir %{apache_serverroot}/owncloud
|
||||
|
||||
# CAUTION: keep in sync with debian.rules
|
||||
## traditional layout
|
||||
%define oc_dir %{oc_apache_web_dir}
|
||||
%define oc_config_dir %{oc_apache_web_dir}/config
|
||||
%define oc_data_dir %{oc_apache_web_dir}/data
|
||||
%define oc_data_pdir %{oc_apache_web_dir}
|
||||
%define oc_doc_dir /usr/share/doc/owncloud
|
||||
|
||||
%define ocphp php
|
||||
%define ocphp_bin /usr/bin
|
||||
%define ocphp_deps_name owncloud-deps-php5
|
||||
%define ochttpd httpd
|
||||
|
||||
%if "%_repository" == "CentOS_6_SCL_PHP54" || "%_repository" == "RHEL_6_SCL_PHP54"
|
||||
%define ocphp php54-php
|
||||
%define ocphp_bin /opt/rh/php54/root/usr/bin
|
||||
%define ocphp_deps_name owncloud-deps-scl-php54
|
||||
%define ochttpd httpd
|
||||
%endif
|
||||
|
||||
%if "%_repository" == "CentOS_6_SCL_PHP55" || "%_repository" == "RHEL_6_SCL_PHP55"
|
||||
%define ocphp php55-php
|
||||
%define ocphp_bin /opt/rh/php55/root/usr/bin
|
||||
%define ocphp_deps_name owncloud-deps-scl-php55
|
||||
%define ochttpd httpd24-httpd
|
||||
%endif
|
||||
|
||||
%if "%_repository" == "CentOS_6_SCL_PHP56" || "%_repository" == "RHEL_6_SCL_PHP56"
|
||||
%define ocphp rh-php56-php
|
||||
%define ocphp_bin /opt/rh/php56/root/usr/bin
|
||||
%define ocphp_deps_name owncloud-deps-scl-php56
|
||||
%define ochttpd httpd24-httpd
|
||||
%endif
|
||||
|
||||
#####################################################
|
||||
|
||||
%package -n %{ocphp_deps_name}
|
||||
Provides: owncloud-deps
|
||||
|
||||
Requires: curl
|
||||
# apps/user_ldap
|
||||
Requires: %{ocphp}-ldap
|
||||
|
||||
%if 0%{?fedora_version} || 0%{?rhel} || 0%{?rhel_version} || 0%{?centos_version}
|
||||
Requires: %{ochttpd}
|
||||
Requires: sqlite
|
||||
Requires: %{ocphp} >= 5.4.0
|
||||
Requires: %{ocphp}-json %{ocphp}-mbstring %{ocphp}-process %{ocphp}-xml %{ocphp}-zip
|
||||
# core#13357, core#13944
|
||||
Requires: %{ocphp}-posix %{ocphp}-gd
|
||||
# https://github.com/owncloud/core/issues/11576
|
||||
# at CentOS6, we need policycoreutils-python for semanage.
|
||||
Requires: policycoreutils-python
|
||||
# at centOS7 to avoid a blank page. Class 'PDO' not found at \/var\/www\/html\/owncloud\/3rdparty\/doctrine
|
||||
Requires: %{ocphp}-pdo
|
||||
%endif
|
||||
|
||||
%if 0%{?suse_version}
|
||||
Requires: php-fileinfo
|
||||
Requires: php5 >= 5.4.0 php5-mbstring php5-zip php5-json php5-posix php5-curl php5-gd php5-ctype php5-xmlreader php5-xmlwriter php5-zlib php5-pear php5-iconv php5-pdo
|
||||
Requires: apache2 apache2-mod_php5
|
||||
%endif
|
||||
|
||||
Summary: Dependencies for php5
|
||||
%description -n %{ocphp_deps_name}
|
||||
%{summary}.
|
||||
|
||||
|
||||
#####################################################
|
||||
|
||||
%package -n owncloud-deps-php7
|
||||
Provides: owncloud-deps
|
||||
Requires: php7
|
||||
Summary: Dependencies for php7
|
||||
%description -n owncloud-deps-php7
|
||||
%{summary}.
|
||||
|
||||
#####################################################
|
||||
|
||||
%prep
|
||||
# setup -q -n owncloud
|
||||
|
||||
%build
|
||||
echo build
|
||||
|
||||
%install
|
||||
echo install
|
||||
|
||||
%clean
|
||||
rm -rf "$RPM_BUILD_ROOT"
|
||||
|
||||
%pre -n %{ocphp_deps_name}
|
||||
# avoid fatal php errors, while we are changing files
|
||||
# https://github.com/owncloud/core/issues/10953
|
||||
#
|
||||
# https://github.com/owncloud/core/issues/12125
|
||||
# We put the existing owncloud in maintenance mode,
|
||||
# apply our changes, reload (not restart!) apache, then
|
||||
# exit maintenance mode.
|
||||
|
||||
## server upgrade
|
||||
if [ $1 -eq 1 ]; then
|
||||
echo "%{name} pre-install: First install starting"
|
||||
else
|
||||
echo "%{name} pre-install: installing upgrade ..."
|
||||
fi
|
||||
# https://github.com/owncloud/core/issues/12125
|
||||
if [ -x %{ocphp_bin}/php -a -s %{oc_dir}/config/config.php ]; then
|
||||
echo "%{name} pre-install: occ maintenance:mode --on"
|
||||
su %{oc_user} -s /bin/sh -c "cd %{oc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ maintenance:mode --on" || true
|
||||
echo yes > %{statedir}/occ_maintenance_mode_during_owncloud_install
|
||||
fi
|
||||
|
||||
|
||||
|
||||
%post -n %{ocphp_deps_name}
|
||||
if [ -f /etc/sysconfig/apache2 ]; then
|
||||
%if 0%{?suse_version}
|
||||
## FIXME: use a2enmod instead??
|
||||
# a2enmod php5
|
||||
# a2enmod rewrite
|
||||
## make sure php5 is not in APACHE_MODULES, so that we don't create dups.
|
||||
perl -pani -e 's@^(APACHE_MODULES=".*)\bphp5\b@$1@' /etc/sysconfig/apache2
|
||||
# add php5 to APACHE_MODULES
|
||||
perl -pani -e 's@^(APACHE_MODULES=")@${1}php5 @' /etc/sysconfig/apache2
|
||||
%endif
|
||||
:
|
||||
fi
|
||||
|
||||
# install our apache config
|
||||
if [ -f "%{oc_doc_dir}*/owncloud-config-apache.conf.default" ]; then
|
||||
echo "install owncloud.conf into apache, if missing"
|
||||
if [ -d %{apache_confdir} -a ! -f %{apache_confdir}/owncloud.conf ]; then
|
||||
cp %{oc_doc_dir}*/owncloud-config-apache.conf.default %{apache_confdir}/owncloud.conf
|
||||
chown root:root %{apache_confdir}/owncloud.conf
|
||||
chmod 644 %{apache_confdir}/owncloud.conf
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ ! -s %{statedir}/need_apache_reload_after_owncloud_install ]; then
|
||||
%if 0%{?suse_version}
|
||||
(service apache2 status | grep running > %{statedir}/need_apache_reload_after_owncloud_install) || true
|
||||
%endif
|
||||
%if 0%{?fedora_version} || 0%{?rhel} || 0%{?rhel_version} || 0%{?centos_version}
|
||||
(service %{ochttpd} status | grep running > %{statedir}/need_apache_reload_after_owncloud_install) || true
|
||||
%endif
|
||||
fi
|
||||
|
||||
if [ -s %{statedir}/need_apache_reload_after_owncloud_install ]; then
|
||||
echo "%{name} post-install: apache: Reloading"
|
||||
%if 0%{?suse_version}
|
||||
service apache2 reload || true
|
||||
%endif
|
||||
%if 0%{?fedora_version} || 0%{?rhel} || 0%{?rhel_version} || 0%{?centos_version}
|
||||
service %{ochttpd} status && service %{ochttpd} reload || service %{ochttpd} start || true
|
||||
%endif
|
||||
fi
|
||||
rm -f %{statedir}/need_apache_reload_after_owncloud_install
|
||||
|
||||
# must ignore errors with e.g. '|| true' or we die in openSUSEs horrible post build checks.
|
||||
# https://github.com/owncloud/core/issues/12125 needed occ calls.
|
||||
# https://github.com/owncloud/core/issues/17583 correct occ usage.
|
||||
if [ -s %{statedir}/occ_maintenance_mode_during_owncloud_install ]; then
|
||||
# https://github.com/owncloud/core/pull/19508
|
||||
# https://github.com/owncloud/core/pull/19661
|
||||
echo "Leaving server in maintenance mode. Please run occ upgrade manually."
|
||||
echo ""
|
||||
echo "See https://doc.owncloud.org/server/9.0/admin_manual/maintenance/upgrade.html"
|
||||
echo ""
|
||||
fi
|
||||
rm -f %{statedir}/occ_maintenance_mode_during_owncloud_install
|
||||
|
||||
if [ $1 -eq 1 ]; then
|
||||
echo "Asserting file permission during first install"
|
||||
# CAUTION: if owncloud-files was installed before httpd, everything belongs to root:root.
|
||||
# Mimic here again, what the files section there would have done:
|
||||
chown -R %{oc_user}:%{oc_group} %{oc_config_dir} %{oc_data_dir} %{oc_dir}/apps
|
||||
fi
|
||||
|
||||
# no binary packages are generated without a files section.
|
||||
%files
|
||||
%files -n %{ocphp_deps_name}
|
||||
%if 0%{?support_php7}
|
||||
%files -n owncloud-deps-php7
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Tue Mar 8 2016 jw@owncloud.com
|
||||
- Upgrade to 9.0.0
|
||||
* Sat Mar 5 2016 jw@owncloud.com
|
||||
- Upgrade to 9.0.0~RC2
|
||||
(No code change in the owncloud wrapper package, see owncloud-files)
|
||||
* Wed Mar 2 2016 jw@owncloud.com
|
||||
- Upgrade to 9.0.0~RC1
|
||||
(No code change in the owncloud wrapper package, see owncloud-files)
|
||||
* Wed Feb 24 2016 jw@owncloud.com
|
||||
- Asserting file permission during first install of deps package
|
||||
* Fri Feb 19 2016 jw@owncloud.com
|
||||
- survive integrity checks. see ee:9.0:testing for details
|
||||
* Thu Feb 18 2016 jw@owncloud.com
|
||||
- really name SCL specific repos SCL.
|
||||
* Tue Feb 16 2016 jw@owncloud.com
|
||||
- updated pre / post scripts to specfile
|
||||
(debian scripts still missing)
|
||||
* Fri Feb 12 2016 jw@owncloud.com
|
||||
- owncloud-deps-php5 now has all the Requires, we had in owncloud-8.2.x
|
||||
* Thu Feb 11 2016 jw@owncloud.com
|
||||
- initial 9.0 setup: owncloud-files
|
||||
- owncloud and owncloud-deps
|
||||
478
fedora/SPECS/archive/subversion.spec
Normal file
478
fedora/SPECS/archive/subversion.spec
Normal file
@@ -0,0 +1,478 @@
|
||||
# set to zero to avoid running test suite
|
||||
%define make_check 0
|
||||
|
||||
%define with_java 1
|
||||
%define with_kwallet 1
|
||||
|
||||
# set JDK path to build javahl; default for JPackage
|
||||
%define jdk_path /usr/lib/jvm/java
|
||||
|
||||
%define perl_vendorarch %(eval "`%{__perl} -V:installvendorarch`"; echo $installvendorarch)
|
||||
|
||||
%if 0%{?fedora} < 18
|
||||
%define dbdevel db4-devel
|
||||
%else
|
||||
%define dbdevel libdb-devel
|
||||
%endif
|
||||
|
||||
%global sqlite_minver 3.7.12
|
||||
|
||||
%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
||||
|
||||
%{!?_httpd_apxs: %{expand: %%global _httpd_apxs %%{_sbindir}/apxs}}
|
||||
%{!?_httpd_mmn: %{expand: %%global _httpd_mmn %%(cat %{_includedir}/httpd/.mmn 2>/dev/null || echo missing-httpd-devel)}}
|
||||
%{!?_httpd_confdir: %{expand: %%global _httpd_confdir %%{_sysconfdir}/httpd/conf.d}}
|
||||
# /etc/httpd/conf.d with httpd < 2.4 and defined as /etc/httpd/conf.modules.d with httpd >= 2.4
|
||||
%{!?_httpd_modconfdir: %{expand: %%global _httpd_modconfdir %%{_sysconfdir}/httpd/conf.d}}
|
||||
|
||||
Summary: A Modern Concurrent Version Control System
|
||||
Name: subversion
|
||||
Version: 1.8.8
|
||||
Release: 1%{?dist}
|
||||
License: ASL 2.0
|
||||
Group: Development/Tools
|
||||
URL: http://subversion.apache.org/
|
||||
Source0: http://www.apache.org/dist/subversion/subversion-%{version}.tar.bz2
|
||||
Source1: subversion.conf
|
||||
Source3: filter-requires.sh
|
||||
Source4: http://www.xsteve.at/prg/emacs/psvn.el
|
||||
Source5: psvn-init.el
|
||||
Source6: svnserve.service
|
||||
Source7: svnserve.tmpfiles
|
||||
Source8: svnserve.sysconf
|
||||
Patch1: subversion-1.8.0-rpath.patch
|
||||
Patch2: subversion-1.8.0-pie.patch
|
||||
Patch3: subversion-1.8.0-kwallet.patch
|
||||
Patch4: subversion-1.8.0-rubybind.patch
|
||||
Patch5: subversion-1.8.0-aarch64.patch
|
||||
BuildRequires: autoconf, libtool, python, python-devel, texinfo, which
|
||||
BuildRequires: %{dbdevel} >= 4.1.25, swig >= 1.3.24, gettext
|
||||
BuildRequires: apr-devel >= 1.3.0, apr-util-devel >= 1.3.0
|
||||
BuildRequires: libserf-devel >= 1.2.1, cyrus-sasl-devel
|
||||
BuildRequires: sqlite-devel >= %{sqlite_minver}, file-devel, systemd-units
|
||||
# Any apr-util crypto backend needed
|
||||
BuildRequires: apr-util-openssl
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
Provides: svn = %{version}-%{release}
|
||||
Requires: subversion-libs%{?_isa} = %{version}-%{release}
|
||||
Requires(post): systemd-sysv, /sbin/chkconfig
|
||||
|
||||
%define __perl_requires %{SOURCE3}
|
||||
|
||||
# Put Python bindings in site-packages
|
||||
%define swigdirs swig_pydir=%{python_sitearch}/libsvn swig_pydir_extra=%{python_sitearch}/svn
|
||||
|
||||
%description
|
||||
Subversion is a concurrent version control system which enables one
|
||||
or more users to collaborate in developing and maintaining a
|
||||
hierarchy of files and directories while keeping a history of all
|
||||
changes. Subversion only stores the differences between versions,
|
||||
instead of every complete file. Subversion is intended to be a
|
||||
compelling replacement for CVS.
|
||||
|
||||
%package libs
|
||||
Group: Development/Tools
|
||||
Summary: Libraries for Subversion Version Control system
|
||||
# APR 1.3.x interfaces are required
|
||||
Conflicts: apr%{?_isa} < 1.3.0
|
||||
|
||||
%description libs
|
||||
The subversion-libs package includes the essential shared libraries
|
||||
used by the Subversion version control tools.
|
||||
|
||||
%package python
|
||||
Group: Development/Libraries
|
||||
Summary: Python bindings for Subversion Version Control system
|
||||
|
||||
%description python
|
||||
The subversion-python package includes the Python bindings to the
|
||||
Subversion libraries.
|
||||
|
||||
%package devel
|
||||
Group: Development/Tools
|
||||
Summary: Development package for the Subversion libraries
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
Requires: apr-devel%{?_isa}, apr-util-devel%{?_isa}
|
||||
|
||||
%description devel
|
||||
The subversion-devel package includes the libraries and include files
|
||||
for developers interacting with the subversion package.
|
||||
|
||||
%package gnome
|
||||
Group: Development/Tools
|
||||
Summary: GNOME Keyring support for Subversion
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
BuildRequires: libgnome-keyring-devel, dbus-devel
|
||||
|
||||
%description gnome
|
||||
The subversion-gnome package adds support for storing Subversion
|
||||
passwords in the GNOME Keyring.
|
||||
|
||||
%if %{with_kwallet}
|
||||
%package kde
|
||||
Group: Development/Tools
|
||||
Summary: KDE Wallet support for Subversion
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
BuildRequires: kdelibs-devel >= 4.0.0
|
||||
|
||||
%description kde
|
||||
The subversion-kde package adds support for storing Subversion
|
||||
passwords in the KDE Wallet.
|
||||
%endif
|
||||
|
||||
%package -n mod_dav_svn
|
||||
Group: System Environment/Daemons
|
||||
Summary: Apache httpd module for Subversion server
|
||||
Requires: subversion-libs%{?_isa} = %{version}-%{release}
|
||||
BuildRequires: httpd-devel >= 2.0.45
|
||||
|
||||
%description -n mod_dav_svn
|
||||
The mod_dav_svn package allows access to a Subversion repository
|
||||
using HTTP, via the Apache httpd server.
|
||||
|
||||
%package perl
|
||||
Group: Development/Libraries
|
||||
Summary: Perl bindings to the Subversion libraries
|
||||
BuildRequires: perl-devel >= 2:5.8.0, perl(ExtUtils::MakeMaker)
|
||||
BuildRequires: perl(Test::More), perl(ExtUtils::Embed)
|
||||
Requires: %(eval `perl -V:version`; echo "perl(:MODULE_COMPAT_$version)")
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description perl
|
||||
This package includes the Perl bindings to the Subversion libraries.
|
||||
|
||||
%if %{with_java}
|
||||
%package javahl
|
||||
Group: Development/Libraries
|
||||
Summary: JNI bindings to the Subversion libraries
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
BuildRequires: java-devel-openjdk
|
||||
# JAR repacking requires both zip and unzip in the buildroot
|
||||
BuildRequires: zip, unzip
|
||||
# For the tests
|
||||
BuildRequires: junit
|
||||
|
||||
%description javahl
|
||||
This package includes the JNI bindings to the Subversion libraries.
|
||||
%endif
|
||||
|
||||
%package ruby
|
||||
Group: Development/Libraries
|
||||
Summary: Ruby bindings to the Subversion libraries
|
||||
BuildRequires: ruby-devel >= 1.9.1, ruby >= 1.9.1
|
||||
BuildRequires: rubygem(minitest)
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
Conflicts: ruby-libs%{?_isa} < 1.8.2
|
||||
|
||||
%description ruby
|
||||
This package includes the Ruby bindings to the Subversion libraries.
|
||||
|
||||
%package tools
|
||||
Group: Development/Tools
|
||||
Summary: Supplementary tools for Subversion
|
||||
Requires: subversion%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description tools
|
||||
This package includes supplementary tools for use with Subversion.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch1 -p1 -b .rpath
|
||||
%patch2 -p1 -b .pie
|
||||
%patch3 -p1 -b .kwallet
|
||||
%patch4 -p1 -b .rubybind
|
||||
%patch5 -p1 -b .aarch64
|
||||
|
||||
%build
|
||||
# Regenerate the buildsystem, so that:
|
||||
# 1) patches applied to configure.in take effect
|
||||
# 2) the swig bindings are regenerated using the system swig
|
||||
# (2) is not ideal since typically upstream test with a different
|
||||
# swig version
|
||||
# This PATH order makes the fugly test for libtoolize work...
|
||||
PATH=/usr/bin:$PATH ./autogen.sh --release
|
||||
|
||||
# fix shebang lines, #111498
|
||||
perl -pi -e 's|/usr/bin/env perl -w|/usr/bin/perl -w|' tools/hook-scripts/*.pl.in
|
||||
|
||||
# override weird -shrext from ruby
|
||||
export svn_cv_ruby_link="%{__cc} -shared"
|
||||
export svn_cv_ruby_sitedir_libsuffix=""
|
||||
export svn_cv_ruby_sitedir_archsuffix=""
|
||||
|
||||
%ifarch sparc64
|
||||
sed -i 's/-fpie/-fPIE/' Makefile.in
|
||||
%endif
|
||||
|
||||
export CFLAGS="$RPM_OPT_FLAGS"
|
||||
export APACHE_LDFLAGS="-Wl,-z,relro,-z,now"
|
||||
export CC=gcc CXX=g++ JAVA_HOME=%{jdk_path}
|
||||
%configure --with-apr=%{_prefix} --with-apr-util=%{_prefix} \
|
||||
--with-swig --with-serf=%{_prefix} \
|
||||
--with-ruby-sitedir=%{ruby_vendorarchdir} \
|
||||
--with-ruby-test-verbose=verbose \
|
||||
--with-apxs=%{_httpd_apxs} --disable-mod-activation \
|
||||
--with-apache-libexecdir=%{_httpd_moddir} \
|
||||
--disable-static --with-sasl=%{_prefix} \
|
||||
--with-libmagic=%{_prefix} \
|
||||
--with-gnome-keyring \
|
||||
%if %{with_java}
|
||||
--enable-javahl \
|
||||
--with-junit=%{_prefix}/share/java/junit.jar \
|
||||
%endif
|
||||
%if %{with_kwallet}
|
||||
--with-kwallet \
|
||||
%endif
|
||||
--with-berkeley-db || (cat config.log; exit 1)
|
||||
make %{?_smp_mflags} all tools
|
||||
make swig-py swig-py-lib %{swigdirs}
|
||||
make swig-pl swig-pl-lib swig-rb swig-rb-lib
|
||||
%if %{with_java}
|
||||
# javahl-javah does not parallel-make with javahl
|
||||
#make javahl-java javahl-javah
|
||||
make javahl
|
||||
%endif
|
||||
|
||||
%install
|
||||
rm -rf ${RPM_BUILD_ROOT}
|
||||
make install install-swig-py install-swig-pl-lib install-swig-rb \
|
||||
DESTDIR=$RPM_BUILD_ROOT %{swigdirs}
|
||||
%if %{with_java}
|
||||
make install-javahl-java install-javahl-lib javahl_javadir=%{_javadir} DESTDIR=$RPM_BUILD_ROOT
|
||||
%endif
|
||||
|
||||
make pure_vendor_install -C subversion/bindings/swig/perl/native \
|
||||
PERL_INSTALL_ROOT=$RPM_BUILD_ROOT
|
||||
install -m 755 -d ${RPM_BUILD_ROOT}%{_sysconfdir}/subversion
|
||||
|
||||
mkdir -p ${RPM_BUILD_ROOT}{%{_httpd_modconfdir},%{_httpd_confdir}}
|
||||
|
||||
%if "%{_httpd_modconfdir}" == "%{_httpd_confdir}"
|
||||
# httpd <= 2.2.x
|
||||
install -p -m 644 %{SOURCE1} ${RPM_BUILD_ROOT}%{_httpd_confdir}
|
||||
%else
|
||||
sed -n /^LoadModule/p %{SOURCE1} > 10-subversion.conf
|
||||
sed /^LoadModule/d %{SOURCE1} > example.conf
|
||||
touch -r %{SOURCE1} 10-subversion.conf example.conf
|
||||
install -p -m 644 10-subversion.conf ${RPM_BUILD_ROOT}%{_httpd_modconfdir}
|
||||
%endif
|
||||
|
||||
# Remove unpackaged files
|
||||
rm -rf ${RPM_BUILD_ROOT}%{_includedir}/subversion-*/*.txt \
|
||||
${RPM_BUILD_ROOT}%{python_sitearch}/*/*.{a,la}
|
||||
|
||||
# The SVN build system is broken w.r.t. DSO support; it treats
|
||||
# normal libraries as DSOs and puts them in $libdir, whereas they
|
||||
# should go in some subdir somewhere, and be linked using -module,
|
||||
# etc. So, forcibly nuke the .so's for libsvn_auth_{gnome,kde},
|
||||
# since nothing should ever link against them directly.
|
||||
rm -f ${RPM_BUILD_ROOT}%{_libdir}/libsvn_auth_*.so
|
||||
|
||||
# remove stuff produced with Perl modules
|
||||
find $RPM_BUILD_ROOT -type f \
|
||||
-a \( -name .packlist -o \( -name '*.bs' -a -empty \) \) \
|
||||
-print0 | xargs -0 rm -f
|
||||
|
||||
# make Perl modules writable so they get stripped
|
||||
find $RPM_BUILD_ROOT%{_libdir}/perl5 -type f -perm 555 -print0 |
|
||||
xargs -0 chmod 755
|
||||
|
||||
# unnecessary libraries for swig bindings
|
||||
rm -f ${RPM_BUILD_ROOT}%{_libdir}/libsvn_swig_*.{so,la,a}
|
||||
|
||||
# Remove unnecessary ruby libraries
|
||||
rm -f ${RPM_BUILD_ROOT}%{ruby_vendorarchdir}/svn/ext/*.*a
|
||||
|
||||
# Trim what goes in docdir
|
||||
rm -rf tools/*/*.in
|
||||
|
||||
# Install psvn for emacs and xemacs
|
||||
for f in emacs/site-lisp xemacs/site-packages/lisp; do
|
||||
install -m 755 -d ${RPM_BUILD_ROOT}%{_datadir}/$f
|
||||
install -m 644 $RPM_SOURCE_DIR/psvn.el ${RPM_BUILD_ROOT}%{_datadir}/$f
|
||||
done
|
||||
|
||||
install -m 644 $RPM_SOURCE_DIR/psvn-init.el \
|
||||
${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp
|
||||
|
||||
# Rename authz_svn INSTALL doc for docdir
|
||||
ln -f subversion/mod_authz_svn/INSTALL mod_authz_svn-INSTALL
|
||||
|
||||
# Trim exported dependencies to APR libraries only:
|
||||
sed -i "/^dependency_libs/{
|
||||
s, -l[^ ']*, ,g;
|
||||
s, -L[^ ']*, ,g;
|
||||
s,%{_libdir}/lib[^a][^p][^r][^ ']*.la, ,g;
|
||||
}" $RPM_BUILD_ROOT%{_libdir}/*.la
|
||||
|
||||
# Install bash completion
|
||||
install -Dpm 644 tools/client-side/bash_completion \
|
||||
$RPM_BUILD_ROOT%{_datadir}/bash-completion/completions/svn
|
||||
for comp in svnadmin svndumpfilter svnlook svnsync svnversion; do
|
||||
ln -s svn \
|
||||
$RPM_BUILD_ROOT%{_datadir}/bash-completion/completions/${comp}
|
||||
done
|
||||
|
||||
# Install svnserve bits
|
||||
mkdir -p %{buildroot}%{_unitdir} \
|
||||
%{buildroot}/run/svnserve \
|
||||
%{buildroot}%{_prefix}/lib/tmpfiles.d \
|
||||
%{buildroot}%{_sysconfdir}/sysconfig
|
||||
|
||||
install -p -m 644 $RPM_SOURCE_DIR/svnserve.service \
|
||||
%{buildroot}%{_unitdir}/svnserve.service
|
||||
install -p -m 644 $RPM_SOURCE_DIR/svnserve.tmpfiles \
|
||||
%{buildroot}%{_prefix}/lib/tmpfiles.d/svnserve.conf
|
||||
install -p -m 644 $RPM_SOURCE_DIR/svnserve.sysconf \
|
||||
%{buildroot}%{_sysconfdir}/sysconfig/svnserve
|
||||
|
||||
# Install tools ex diff*
|
||||
make install-tools DESTDIR=$RPM_BUILD_ROOT toolsdir=%{_bindir}
|
||||
rm -f $RPM_BUILD_ROOT%{_bindir}/diff*
|
||||
|
||||
for f in svn-populate-node-origins-index svn-rep-sharing-stats svnauthz-validate svnmucc svnraisetreeconflict; do
|
||||
echo %{_bindir}/$f
|
||||
done | tee tools.files | sed 's/^/%%exclude /' > exclude.tools.files
|
||||
|
||||
%find_lang %{name}
|
||||
|
||||
cat %{name}.lang exclude.tools.files >> %{name}.files
|
||||
|
||||
%if %{make_check}
|
||||
%check
|
||||
export LANG=C LC_ALL=C
|
||||
export LD_LIBRARY_PATH=$RPM_BUILD_ROOT%{_libdir}
|
||||
export MALLOC_PERTURB_=171 MALLOC_CHECK_=3
|
||||
export LIBC_FATAL_STDERR_=1
|
||||
if ! make check check-swig-pl check-swig-py check-swig-rb CLEANUP=yes; then
|
||||
: Test suite failure.
|
||||
cat fails.log
|
||||
exit 1
|
||||
fi
|
||||
# check-swig-rb omitted: it runs svnserve
|
||||
%if %{with_java}
|
||||
make check-javahl
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%clean
|
||||
rm -rf ${RPM_BUILD_ROOT}
|
||||
|
||||
%post
|
||||
%systemd_post svnserve.service
|
||||
|
||||
%preun
|
||||
%systemd_preun svnserve.service
|
||||
|
||||
%postun
|
||||
%systemd_postun_with_restart svnserve.service
|
||||
|
||||
%triggerun -- subversion < 1.7.3-2
|
||||
/usr/bin/systemd-sysv-convert --save svnserve >/dev/null 2>&1 ||:
|
||||
/sbin/chkconfig --del svnserve >/dev/null 2>&1 || :
|
||||
/bin/systemctl try-restart svnserve.service >/dev/null 2>&1 || :
|
||||
|
||||
%post libs -p /sbin/ldconfig
|
||||
|
||||
%postun libs -p /sbin/ldconfig
|
||||
|
||||
%post perl -p /sbin/ldconfig
|
||||
|
||||
%postun perl -p /sbin/ldconfig
|
||||
|
||||
%post ruby -p /sbin/ldconfig
|
||||
|
||||
%postun ruby -p /sbin/ldconfig
|
||||
|
||||
%if %{with_java}
|
||||
%post javahl -p /sbin/ldconfig
|
||||
|
||||
%postun javahl -p /sbin/ldconfig
|
||||
%endif
|
||||
|
||||
%files -f %{name}.files
|
||||
%defattr(-,root,root)
|
||||
%doc BUGS COMMITTERS LICENSE NOTICE INSTALL README CHANGES
|
||||
%doc tools/hook-scripts tools/backup tools/bdb tools/examples tools/xslt
|
||||
%doc mod_authz_svn-INSTALL
|
||||
%{_bindir}/*
|
||||
%{_mandir}/man*/*
|
||||
%{_datadir}/emacs/site-lisp/*.el
|
||||
%{_datadir}/xemacs/site-packages/lisp/*.el
|
||||
%{_datadir}/bash-completion/completions/*
|
||||
%config(noreplace) %{_sysconfdir}/sysconfig/svnserve
|
||||
%dir %{_sysconfdir}/subversion
|
||||
%exclude %{_mandir}/man*/*::*
|
||||
%{_unitdir}/*.service
|
||||
%dir /run/svnserve
|
||||
%{_prefix}/lib/tmpfiles.d/svnserve.conf
|
||||
|
||||
%files tools -f tools.files
|
||||
%defattr(-,root,root)
|
||||
|
||||
%files libs
|
||||
%defattr(-,root,root)
|
||||
%doc LICENSE NOTICE
|
||||
%{_libdir}/libsvn_*.so.*
|
||||
%exclude %{_libdir}/libsvn_swig_perl*
|
||||
%exclude %{_libdir}/libsvn_swig_ruby*
|
||||
%if %{with_kwallet}
|
||||
%exclude %{_libdir}/libsvn_auth_kwallet*
|
||||
%endif
|
||||
%exclude %{_libdir}/libsvn_auth_gnome*
|
||||
|
||||
%files python
|
||||
%defattr(-,root,root)
|
||||
%{python_sitearch}/svn
|
||||
%{python_sitearch}/libsvn
|
||||
|
||||
%files gnome
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/libsvn_auth_gnome_keyring-*.so.*
|
||||
|
||||
%if %{with_kwallet}
|
||||
%files kde
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/libsvn_auth_kwallet-*.so.*
|
||||
%endif
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%{_includedir}/subversion-1
|
||||
%{_libdir}/libsvn*.*a
|
||||
%{_libdir}/libsvn*.so
|
||||
%exclude %{_libdir}/libsvn_swig_perl*
|
||||
%if %{with_java}
|
||||
%exclude %{_libdir}/libsvnjavahl-1.*
|
||||
%endif
|
||||
|
||||
%files -n mod_dav_svn
|
||||
%defattr(-,root,root)
|
||||
%config(noreplace) %{_httpd_modconfdir}/*.conf
|
||||
%{_libdir}/httpd/modules/mod_*.so
|
||||
%if "%{_httpd_modconfdir}" != "%{_httpd_confdir}"
|
||||
%doc example.conf
|
||||
%endif
|
||||
|
||||
%files perl
|
||||
%defattr(-,root,root,-)
|
||||
%{perl_vendorarch}/auto/SVN
|
||||
%{perl_vendorarch}/SVN
|
||||
%{_libdir}/libsvn_swig_perl*
|
||||
%{_mandir}/man*/*::*
|
||||
|
||||
%files ruby
|
||||
%defattr(-,root,root,-)
|
||||
%{_libdir}/libsvn_swig_ruby*
|
||||
%{ruby_vendorarchdir}/svn
|
||||
|
||||
%if %{with_java}
|
||||
%files javahl
|
||||
%defattr(-,root,root,-)
|
||||
%{_libdir}/libsvnjavahl-1.*
|
||||
%{_javadir}/svn-javahl.jar
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Fri Feb 21 2014 Daniel Steiner <elpito@bluewin.ch>
|
||||
- First package got from original fedora source (1.8.8).
|
||||
Reference in New Issue
Block a user