a3b73be
%bcond_with autoreconf
a3b73be
%bcond_with authorcheck
a3b73be
fc66db9
# Unbundling helper macro
6f0b295
# %1 is the path to dir bundling files (from)
6f0b295
# %2 is the path to dir containing original files (with)
6f0b295
%global unbundle_from_with() \
6f0b295
  bundled_dir="%{buildroot}%1" \
6f0b295
  bundled_files="$(find "${bundled_dir}" -maxdepth 1 -type f -printf '%f\\n')" \
6f0b295
  original_dir="%2" \
6f0b295
  for file in ${bundled_files} \
6f0b295
  do \
6f0b295
    if [ -f "${original_dir}/${file}" ] \
6f0b295
    then \
6f0b295
      rm -f "${bundled_dir}/${file}" \
6f0b295
      ln -s "${original_dir}/${file}" "${bundled_dir}/${file}" \
6f0b295
    fi \
6f0b295
  done
6f0b295
fc66db9
# Bundled Fonts
6f0b295
#
6f0b295
# EL7 version (4.1.0) is missing some icons
6f0b295
%global unbundle_fontawesome       0%{?fedora}%{?el6}
6f0b295
# Not available for EL
6f0b295
%global unbundle_raleway           0%{?fedora}
6f0b295
# Not available
6f0b295
%global unbundle_foundation_icons  0
6f0b295
fc66db9
# Bundled javascripts
6f0b295
#
6f0b295
# Not available
6f0b295
%global unbundle_foundation        0
6f0b295
# Not available for EL
6f0b295
%global unbundle_html5shiv         0%{?fedora}
6f0b295
# Not available for EL
6f0b295
%global unbundle_jquery            0%{?fedora}
6f0b295
# Available version is too old
6f0b295
%global unbundle_jquery_migrate    0
6f0b295
# Not available
6f0b295
%global unbundle_jquery_minicolors 0
6f0b295
# Not available for EL6
6f0b295
%global unbundle_jquery_ui         0%{?fedora}%{?el7}
fc66db9
# Only available for Fedora
6f0b295
%global unbundle_jqplot            0%{?fedora}
6f0b295
#
6f0b295
%global unbundle_respond           0%{?fedora}%{?rhel}
6f0b295
6f0b295
# Licenses
6f0b295
# Sympa itself is GPLv2+.
6f0b295
# Possibly bundled fonts are :
6f0b295
# - fontawesome-fonts :      OFL
6f0b295
# - fontawesome-fonts-web:   OFL and MIT
6f0b295
# - impallari-raleway-fonts: OFL
6f0b295
# - foundation-icons-fonts:  MIT
6f0b295
# Possibly bundled javascripts are :
6f0b295
# - js-html5shiv:            MIT or GPLv2
6f0b295
# - js-jquery-jqplot:        MIT or GPLv2
6f0b295
# - js-jquery:               MIT
6f0b295
# - js-respond:              MIT
6f0b295
# - js-jquery-ui:            MIT
6f0b295
# - js-foundation:           MIT
6f0b295
# - js-jquery-migrate:       MIT
6f0b295
# - js-jquery-minicolors:    MIT
6f0b295
%global licenses_bundled     %{nil} 
6f0b295
# OFL and MIT
6f0b295
%if ! %{unbundle_fontawesome}
6f0b295
%global licenses_bundled %{licenses_bundled} and (OFL and MIT)
6f0b295
%endif
6f0b295
# OFL
6f0b295
%if ! %{unbundle_raleway}
6f0b295
%global licenses_bundled %{licenses_bundled} and OFL
6f0b295
%endif
6f0b295
# MIT
6f0b295
%if ! %{unbundle_foundation_icons} || ! %{unbundle_foundation} || ! %{unbundle_jquery} || ! %{unbundle_jquery_migrate} || ! %{unbundle_jquery_minicolors} || ! %{unbundle_jquery_ui} || ! %{unbundle_respond}
6f0b295
%global licenses_bundled %{licenses_bundled} and MIT
6f0b295
%endif
6f0b295
# MIT or GPLv2
6f0b295
%if ! %{unbundle_html5shiv} || ! %{unbundle_jqplot}
6f0b295
%global licenses_bundled %{licenses_bundled} and (MIT or GPLv2)
6f0b295
%endif
6f0b295
fc66db9
fc66db9
%if 0%{?fedora} || 0%{?rhel} >= 7
fc66db9
%global use_systemd 1
fc66db9
%else
fc66db9
%global use_systemd 0
fc66db9
%endif
fc66db9
fc66db9
%global static_content %{_datadir}/sympa/static_content
fc66db9
6f0b295
#global pre_rel b.2
6f0b295
6f0b295
Name:        sympa
6f0b295
Version:     6.2.44
87fc0a3
Release:     %{?pre_rel:0.}3%{?pre_rel:.%pre_rel}%{?dist}
6f0b295
Summary:     Powerful multilingual List Manager
6f0b295
Summary(fr): Gestionnaire de listes électroniques
6f0b295
Summary(ja): 高機能で多言語対応のメーリングリスト管理ソフトウェア
6f0b295
# The License: tag depends on bundled code for a given distro/release
6f0b295
License:     GPLv2+%{licenses_bundled}
6f0b295
URL:         http://www.sympa.org
6f0b295
Source0:     https://github.com/sympa-community/sympa/releases/download/%{version}%{?pre_rel}/%{name}-%{version}%{?pre_rel}.tar.gz
6f0b295
6f0b295
Source100:   sympa-httpd22-fcgid.conf
6f0b295
Source101:   sympa-httpd24-spawn_fcgi.conf
6f0b295
Source102:   sympa-lighttpd.conf
6f0b295
Source103:   sympa-nginx-spawn_fcgi.conf
6f0b295
Source104:   sympa-wwsympa.init
6f0b295
Source105:   sympa-sympasoap.init
6f0b295
Source106:   sympa-rsyslog.conf
6f0b295
Source107:   sympa-logrotate.conf
6f0b295
Source112:   sympa-sysvinit-README.RPM.md
6f0b295
Source113:   sympa-systemd-README.RPM.md
6f0b295
Source114:   aliases.sympa.sendmail
6f0b295
Source115:   aliases.sympa.postfix
6f0b295
Source129:   sympa.service.d-dependencies.conf
6f0b295
Source130:   sympa-sysconfig
6f0b295
6f0b295
# Add path to MHonArc::UTF8 so that sympa_wizard won't miss it
6f0b295
Patch5:      sympa-6.2.36-wizard-mhonarc.patch
6f0b295
# RPM specific customization of site defaults
6f0b295
Patch13:     sympa-6.2.19b.1-confdef.patch
6f0b295
# Disable sympa service by default
6f0b295
Patch14:     sympa-6.2-initdefault.patch
6f0b295
6f0b295
BuildRequires: gcc, make
6f0b295
BuildRequires: gettext
6f0b295
%if %{use_systemd}
6f0b295
BuildRequires: systemd
6f0b295
%endif
6f0b295
6f0b295
# Only for development
a3b73be
%if %{with autoreconf}
6f0b295
BuildRequires: autoconf, automake, gettext-devel
6f0b295
%endif
6f0b295
6f0b295
BuildRequires: perl-generators
6f0b295
# install & check
6f0b295
BuildRequires: perl(Archive::Zip)
6f0b295
BuildRequires: perl(base)
6f0b295
BuildRequires: perl(Carp)
6f0b295
BuildRequires: perl(CGI::Cookie)
6f0b295
BuildRequires: perl(CGI::Fast)
6f0b295
BuildRequires: perl(CGI::Util)
6f0b295
BuildRequires: perl(Class::Singleton)
6f0b295
BuildRequires: perl(Config)
6f0b295
BuildRequires: perl(constant)
6f0b295
BuildRequires: perl(Cwd)
6f0b295
BuildRequires: perl(Data::Password)
6f0b295
BuildRequires: perl(DateTime)
6f0b295
BuildRequires: perl(DateTime::Format::Mail)
6f0b295
BuildRequires: perl(DBD::SQLite)
6f0b295
BuildRequires: perl(DBI)
6f0b295
BuildRequires: perl(Digest::MD5)
6f0b295
BuildRequires: perl(Encode)
6f0b295
BuildRequires: perl(Encode::MIME::Header)
6f0b295
BuildRequires: perl(English)
6f0b295
BuildRequires: perl(FCGI)
6f0b295
BuildRequires: perl(Fcntl)
6f0b295
BuildRequires: perl(feature)
6f0b295
BuildRequires: perl(File::Copy)
6f0b295
BuildRequires: perl(File::Copy::Recursive)
6f0b295
BuildRequires: perl(File::Find)
6f0b295
BuildRequires: perl(File::NFSLock)
6f0b295
BuildRequires: perl(File::Path)
6f0b295
BuildRequires: perl(File::stat)
6f0b295
BuildRequires: perl(File::Temp)
6f0b295
BuildRequires: perl(Getopt::Long)
6f0b295
BuildRequires: perl(HTML::Entities)
6f0b295
BuildRequires: perl(HTML::FormatText)
6f0b295
BuildRequires: perl(HTML::Parser)
6f0b295
BuildRequires: perl(HTML::StripScripts::Parser)
6f0b295
BuildRequires: perl(HTML::TreeBuilder)
6f0b295
BuildRequires: perl(HTTP::Request)
6f0b295
BuildRequires: perl(if)
6f0b295
BuildRequires: perl(IO::File)
6f0b295
BuildRequires: perl(IO::Scalar)
6f0b295
BuildRequires: perl(IO::Socket::SSL)
6f0b295
BuildRequires: perl(lib)
6f0b295
BuildRequires: perl(Locale::Messages)
6f0b295
BuildRequires: perl(LWP::UserAgent)
6f0b295
BuildRequires: perl(Mail::Address)
6f0b295
BuildRequires: perl(MIME::Base64)
6f0b295
BuildRequires: perl(MIME::Charset)
6f0b295
BuildRequires: perl(MIME::EncWords)
6f0b295
BuildRequires: perl(MIME::Entity)
6f0b295
BuildRequires: perl(MIME::Head)
6f0b295
BuildRequires: perl(MIME::Lite::HTML)
6f0b295
BuildRequires: perl(MIME::Parser)
6f0b295
BuildRequires: perl(MIME::Tools)
6f0b295
BuildRequires: perl(Net::CIDR)
6f0b295
BuildRequires: perl(Net::LDAP)
6f0b295
BuildRequires: perl(POSIX)
6f0b295
BuildRequires: perl(Scalar::Util)
6f0b295
BuildRequires: perl(SOAP::Lite)
6f0b295
BuildRequires: perl(SOAP::Transport::HTTP)
6f0b295
BuildRequires: perl(Storable)
6f0b295
BuildRequires: perl(strict)
6f0b295
BuildRequires: perl(Sys::Hostname)
6f0b295
BuildRequires: perl(Sys::Syslog)
6f0b295
BuildRequires: perl(Template)
6f0b295
BuildRequires: perl(Term::ProgressBar)
6f0b295
BuildRequires: perl(Test::Compile)
6f0b295
BuildRequires: perl(Test::Harness)
6f0b295
BuildRequires: perl(Test::More)
6f0b295
BuildRequires: perl(Test::Pod)
6f0b295
BuildRequires: perl(Text::LineFold)
6f0b295
BuildRequires: perl(Time::HiRes)
6f0b295
BuildRequires: perl(Time::Local)
6f0b295
# For Perl prior to 5.16.0.
6f0b295
%if 0%{?rhel} == 6
6f0b295
BuildRequires: perl(Unicode::CaseFold)
6f0b295
%endif
6f0b295
BuildRequires: perl(Unicode::GCString)
6f0b295
BuildRequires: perl(URI)
6f0b295
BuildRequires: perl(URI::Escape)
6f0b295
BuildRequires: perl(warnings)
6f0b295
BuildRequires: perl(XML::LibXML)
6f0b295
6f0b295
# authorcheck
a3b73be
%if %{with authorcheck}
6f0b295
BuildRequires: perl(Test::Fixme)
6f0b295
BuildRequires: perl(Test::Perl::Critic)
6f0b295
BuildRequires: perl(Test::Pod::Coverage)
6f0b295
BuildRequires: perl(Test::Pod::Spelling::CommonMistakes)
6f0b295
%endif
6f0b295
6f0b295
Requires(pre): shadow-utils
6f0b295
6f0b295
%if ! %{use_systemd}
6f0b295
Requires(post):   chkconfig
6f0b295
Requires(preun):  chkconfig
6f0b295
Requires(preun):  initscripts
6f0b295
Requires(postun): initscripts
6f0b295
%endif
6f0b295
6f0b295
Requires:    smtpdaemon
6f0b295
Requires:    mhonarc
6f0b295
Requires:    perl(DBD::mysql)
6f0b295
Requires:    perl(FCGI)
6f0b295
6f0b295
# Missing Requires on EL6 and EL7
6f0b295
%if 0%{?el6}%{?el7}
6f0b295
Requires:    perl(HTML::FormatText)
6f0b295
Requires:    perl(HTML::StripScripts::Parser)
6f0b295
%endif
6f0b295
6f0b295
# Optional CPAN packages
6f0b295
Requires:    perl(AuthCAS)
6f0b295
Requires:    perl(Clone)
6f0b295
Requires:    perl(Crypt::CipherSaber)
6f0b295
Requires:    perl(Crypt::Eksblowfish)
6f0b295
Requires:    perl(Crypt::OpenSSL::X509)
6f0b295
Requires:    perl(Crypt::SMIME)
6f0b295
Requires:    perl(Data::Password)
6f0b295
Requires:    perl(DateTime::TimeZone)
6f0b295
Requires:    perl(DBD::CSV)
6f0b295
Requires:    perl(Encode::Locale)
6f0b295
# Recommended for handling Japanese vendor codepages.
6f0b295
Requires:    perl(Encode::EUCJPASCII)
6f0b295
# Handling several Chinese standards.
6f0b295
Requires:    perl(Encode::HanExtra)
6f0b295
Requires:    perl(IO::Socket::SSL)
6f0b295
Requires:    perl(List::Util::XS)
6f0b295
Requires:    perl(Mail::DKIM::Verifier)
6f0b295
Requires:    perl(Net::DNS)
6f0b295
Requires:    perl(Net::SMTP)
6f0b295
# for Perl prior to 5.16.0.
6f0b295
%if 0%{?rhel} == 6
6f0b295
Requires:    perl(Unicode::CaseFold)
6f0b295
%endif
6f0b295
Requires:    perl(Unicode::Normalize)
6f0b295
6f0b295
# Bundled fonts
6f0b295
%if %{unbundle_fontawesome}
6f0b295
BuildRequires: fontawesome-fonts-web >= 4.3.0
6f0b295
Requires:      fontawesome-fonts-web >= 4.3.0
6f0b295
%else
6f0b295
Provides:      bundled(fontawesome-fonts) = 4.3.0
6f0b295
%endif
6f0b295
%if %{unbundle_raleway}
6f0b295
BuildRequires: impallari-raleway-fonts >= 3.0
6f0b295
Requires:      impallari-raleway-fonts >= 3.0
6f0b295
%else
6f0b295
Provides:      bundled(impallari-raleway-fonts) = 3.0
6f0b295
%endif
6f0b295
# FIXME: foundation icons
6f0b295
#        See https://fedoraproject.org/wiki/Foundation_icons_font
6f0b295
#            http://zurb.com/playground/uploads/upload/upload/288/foundation-icons.zip
6f0b295
%if %{unbundle_foundation_icons}
6f0b295
BuildRequires: foundation-icons-fonts >= 3.0
6f0b295
Requires:      foundation-icons-fonts >= 3.0
6f0b295
%else
6f0b295
Provides:      bundled(foundation-icons-fonts) = 3.0
6f0b295
%endif
6f0b295
6f0b295
# Bundled javascript libs
6f0b295
# foundation
6f0b295
%if %{unbundle_foundation}
6f0b295
BuildRequires: js-foundation6 >= 6.4.2
6f0b295
Requires:      js-foundation6 >= 6.4.2
6f0b295
%else
6f0b295
Provides:      bundled(js-foundation) = 6.4.2
6f0b295
# Bundled in bundled js-foundation
6f0b295
Provides:      bundled(js-what-input) = 4.2.0
6f0b295
%endif
6f0b295
# html5shiv
6f0b295
%if %{unbundle_html5shiv}
6f0b295
BuildRequires: js-html5shiv >= 3.7.2
6f0b295
Requires:      js-html5shiv >= 3.7.2
6f0b295
%else
6f0b295
Provides:      bundled(js-html5shiv) = 3.7.2
6f0b295
%endif
6f0b295
# jquery
6f0b295
%if %{unbundle_jquery}
6f0b295
BuildRequires: js-jquery3 >= 3.2.1
6f0b295
Requires:      js-jquery3 >= 3.2.1
6f0b295
%else
6f0b295
Provides:      bundled(js-jquery) = 3.2.1
6f0b295
%endif
6f0b295
# jquery-migrate
6f0b295
%if %{unbundle_jquery_migrate}
6f0b295
%if 0%{?el7}
6f0b295
BuildRequires: python-XStatic-JQuery-Migrate >= 1.4.1
6f0b295
Requires:      python-XStatic-JQuery-Migrate >= 1.4.1
6f0b295
%else
6f0b295
BuildRequires: xstatic-jquery-migrate-common >= 1.4.1
6f0b295
Requires:      xstatic-jquery-migrate-common >= 1.4.1
6f0b295
%endif
6f0b295
%else
6f0b295
Provides:      bundled(js-jquery-migrate) = 1.4.1
6f0b295
%endif
6f0b295
# jquery-minicolors
6f0b295
%if %{unbundle_jquery_minicolors}
6f0b295
BuildRequires: js-jquery-minicolors >= 2.3.1
6f0b295
Requires:      js-jquery-minicolors >= 2.3.1
6f0b295
%else
6f0b295
Provides:      bundled(js-jquery-minicolors) = 2.3.1
6f0b295
%endif
6f0b295
# jquery-ui
6f0b295
%if %{unbundle_jquery_ui}
6f0b295
%if 0%{?el7}
6f0b295
BuildRequires: python-XStatic-jquery-ui >= 1.12.0
6f0b295
Requires:      python-XStatic-jquery-ui >= 1.12.0
6f0b295
%else
6f0b295
BuildRequires: xstatic-jquery-ui-common >= 1.12.0
6f0b295
Requires:      xstatic-jquery-ui-common >= 1.12.0
6f0b295
%endif
6f0b295
%else
6f0b295
Provides:      bundled(js-jquery-ui) = 1.12.1
6f0b295
%endif
6f0b295
# jqplot
6f0b295
%if %{unbundle_jqplot}
6f0b295
BuildRequires: js-jquery-jqplot >= 1.0.8
6f0b295
Requires:      js-jquery-jqplot >= 1.0.8
6f0b295
%else
6f0b295
Provides:      bundled(js-jquery-jqplot) = 1.0.8
6f0b295
%endif
6f0b295
# respond
6f0b295
%if %{unbundle_respond}
6f0b295
BuildRequires: js-respond >= 1.4.2
6f0b295
Requires:      js-respond >= 1.4.2
6f0b295
%else
6f0b295
Provides:      bundled(js-respond) = 1.4.2
6f0b295
%endif
6f0b295
b91ca1e
# perl-libintl-perl for perl(Locale::Messages) is missing on EL6 i386
b91ca1e
# RHBZ#1731149
b91ca1e
%{?el6:ExcludeArch:  %{ix86}}
6f0b295
6f0b295
6f0b295
%if 0%{?fedora} || 0%{?rhel} >= 7
6f0b295
%{?perl_default_filter}
6f0b295
%global __requires_exclude perl\\(Conf\\)
6f0b295
%global __provides_exclude perl\\(Conf\\)
6f0b295
%endif
6f0b295
6f0b295
%if 0%{?rhel} == 6
6f0b295
%filter_from_provides /perl(Conf)/d
6f0b295
%filter_from_requires /perl(Conf)/d
6f0b295
%filter_setup
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%description
6f0b295
Sympa is scalable and highly customizable mailing list manager. It
6f0b295
can cope with big lists (200,000 subscribers) and comes with a
6f0b295
complete (user and admin) Web interface. It is internationalized,
6f0b295
and supports the us, fr, de, es, it, fi, and chinese locales. A
6f0b295
scripting language allows you to extend the behavior of commands.
6f0b295
Sympa can be linked to an LDAP directory or an RDBMS to create
6f0b295
dynamic mailing lists. Sympa provides S/MIME-based authentication
6f0b295
and encryption.
6f0b295
6f0b295
%description -l ja
6f0b295
Sympa はスケーラブルで高いカスタマイズ性を持つメーリングリスト管理
6f0b295
ソフトウェアです。巨大なリスト (登録者数 200,000) にも適用でき、完
6f0b295
全な (一般ユーザ用および管理者用) ウェブインタフェースをそなえてい
6f0b295
ます。国際化されており、多数の言語に対応します。内蔵のスクリプティ
6f0b295
ング言語でコマンドの動作を拡張できます。Sympa はまた、LDAP ディレ
6f0b295
クトリや RDBMS と連携して動的なメーリングリストを作成できます。ま
6f0b295
た、S/MIME に基づく認証や暗号化もできます。
6f0b295
6f0b295
fc66db9
%package httpd
fc66db9
Summary:  Sympa with Apache HTTP Server
fc66db9
Summary(fr): Sympa avec Serveur HTTP Apache
fc66db9
Summary(ja): SympaのApache HTTP Server対応
fc66db9
Requires: %{name} = %{version}-%{release}
fc66db9
Requires: httpd
fc66db9
%if 0%{?fedora} || 0%{?rhel} >= 7
fc66db9
Requires: spawn-fcgi
fc66db9
%else
fc66db9
Requires: mod_fcgid
fc66db9
%endif
fc66db9
Conflicts: %{name}-lighttpd, %{name}-nginx
fc66db9
6f0b295
%description httpd
6f0b295
Apache HTTP Server support for Sympa.
6f0b295
6f0b295
%description httpd -l ja
6f0b295
Sympa の Apache HTTP Server 対応。
6f0b295
6f0b295
fc66db9
%package lighttpd
fc66db9
Summary:  Sympa with lighttpd
fc66db9
Summary(fr): Sympa avec lighttpd
fc66db9
Summary(ja): Sympaのlighttpd対応
fc66db9
Requires: %{name} = %{version}-%{release}
fc66db9
Requires: lighttpd
fc66db9
Requires: lighttpd-fastcgi
fc66db9
Conflicts: %{name}-httpd, %{name}-nginx
fc66db9
6f0b295
%description lighttpd
6f0b295
lighttpd support for Sympa.
6f0b295
6f0b295
%description lighttpd -l ja
6f0b295
Sympa の lighttpd 対応。
6f0b295
6f0b295
fc66db9
%package nginx
fc66db9
Summary:  Sympa with nginx
fc66db9
Summary(fr): Sympa avec nginx
fc66db9
Summary(ja): Sympaのnginx対応
fc66db9
Requires: %{name} = %{version}-%{release}
fc66db9
Requires: nginx
fc66db9
Requires: spawn-fcgi
fc66db9
Conflicts: %{name}-httpd, %{name}-lighttpd
fc66db9
6f0b295
%description nginx
6f0b295
nginx support for Sympa.
6f0b295
6f0b295
%description nginx -l ja
6f0b295
Sympa の nginx 対応。
6f0b295
6f0b295
fc66db9
%package devel-doc
fc66db9
Summary: Sympa devel doc
fc66db9
Requires: %{name} = %{version}-%{release}
fc66db9
6f0b295
%description devel-doc
6f0b295
Sympa documentation for developers.
6f0b295
6f0b295
6f0b295
%prep
6f0b295
%setup -q -n %{name}-%{version}%{?pre_rel}
6f0b295
%patch5 -p0 -b .mhonarc
6f0b295
%patch13 -p0 -b .confdef
6f0b295
%patch14 -p0 -b .initdefault
6f0b295
6f0b295
6f0b295
%build
6f0b295
# Development
a3b73be
%if %{with autoreconf}
6f0b295
autoreconf --install
6f0b295
%endif
6f0b295
6f0b295
# Give install "-p" preserving mtime to prevent unexpected update of CSS.
6f0b295
%configure \
6f0b295
    --enable-fhs \
6f0b295
    --prefix=%{_prefix} \
6f0b295
    --bindir=%{_libexecdir}/sympa \
6f0b295
    --docdir=%{_docdir}/%{name} \
6f0b295
    --libexecdir=%{_libexecdir}/sympa \
6f0b295
    --localstatedir=%{_localstatedir} \
6f0b295
    --sysconfdir=%{_sysconfdir}/sympa \
6f0b295
    --with-cgidir=%{_libexecdir}/sympa \
6f0b295
    --with-confdir=%{_sysconfdir}/sympa \
6f0b295
%if %{use_systemd}
6f0b295
    --without-initdir \
6f0b295
    --with-unitsdir=%{_unitdir} \
6f0b295
    --with-piddir=%{_rundir}/sympa \
6f0b295
%else
6f0b295
    --with-initdir=%{_initrddir} \
6f0b295
    --with-piddir=%{_localstatedir}/run/sympa/ \
6f0b295
%endif
6f0b295
    --with-smrshdir=%{_sysconfdir}/smrsh \
6f0b295
    --with-aliases_file=%{_localstatedir}/lib/sympa/sympa_aliases \
6f0b295
    --with-perl=%{_bindir}/perl \
6f0b295
    --with-staticdir=%{static_content} \
6f0b295
    --with-cssdir=%{_localstatedir}/lib/sympa/css \
6f0b295
    --with-picturesdir=%{_localstatedir}/lib/sympa/pictures \
6f0b295
    INSTALL_DATA='install -c -p -m 644'
6f0b295
%make_build
6f0b295
6f0b295
# cancel workaround in Makefile getting previous version.
6f0b295
rm -f previous_sympa_version
6f0b295
6f0b295
pushd po/sympa; rm -f stamp-po; make; popd
6f0b295
pushd po/web_help; rm -f stamp-po; make; popd
6f0b295
6f0b295
6f0b295
%install
6f0b295
%make_install
6f0b295
6f0b295
%find_lang %{name}
6f0b295
%find_lang web_help
6f0b295
6f0b295
# Unbundle fonts from static_content/fonts
6f0b295
# font-awesome
6f0b295
%if %{unbundle_fontawesome}
6f0b295
%unbundle_from_with %{static_content}/fonts/font-awesome/fonts %{_datadir}/fonts/fontawesome
6f0b295
%unbundle_from_with %{static_content}/fonts/font-awesome/css %{_datadir}/font-awesome-web/css
6f0b295
%endif
6f0b295
6f0b295
# Raleway
6f0b295
%if %{unbundle_raleway}
6f0b295
rm -f %{buildroot}%{static_content}/fonts/Raleway/OFL.txt
6f0b295
%unbundle_from_with %{static_content}/fonts/Raleway %{_datadir}/fonts/impallari-raleway
6f0b295
%endif
6f0b295
6f0b295
# FIXME: foundation-icons
6f0b295
%if %{unbundle_foundation_icons}
6f0b295
rm -f %{buildroot}%{_datadir}/fonts/foundation-icons/preview.html
6f0b295
%unbundle_from_with %{static_content}/fonts/foundation-icons %{_datadir}/fonts/foundation-icons
6f0b295
%unbundle_from_with %{static_content}/fonts/foundation-icons/svgs %{_datadir}/fonts/foundation-icons/svgs
6f0b295
%endif
6f0b295
6f0b295
# Unbundle javascript libraries from static_content/js
6f0b295
# FIXME : foundation (Foundation for Sites 6, with float grid support)
6f0b295
%if %{unbundle_foundation}
6f0b295
%unbundle_from_with %{static_content}/js/foundation/js %{_datadir}/javascript/foundation/js
6f0b295
%unbundle_from_with %{static_content}/js/foundation/css %{_datadir}/javascript/foundation/css
6f0b295
# what-input.js
6f0b295
%unbundle_from_with %{static_content}/js/foundation/js/vendor %{_datadir}/javascript
6f0b295
%endif
6f0b295
6f0b295
# html5shiv
6f0b295
%if %{unbundle_html5shiv}
6f0b295
%unbundle_from_with %{static_content}/js/html5shiv %{_datadir}/javascript/
6f0b295
%endif
6f0b295
6f0b295
# jquery
6f0b295
%if %{unbundle_jquery}
6f0b295
%unbundle_from_with %{static_content}/js %{_datadir}/javascript/jquery/3
6f0b295
%endif
6f0b295
6f0b295
# FIXME : jquery-migrate
6f0b295
%if %{unbundle_jquery_migrate}
6f0b295
%unbundle_from_with %{static_content}/js %{_datadir}/javascript/jquery_migrate
6f0b295
%endif
6f0b295
6f0b295
# FIXME : jquery-minicolors
6f0b295
%if %{unbundle_jquery_minicolors}
6f0b295
%unbundle_from_with %{static_content}/js/jquery-minicolors %{_datadir}/javascript/jquery-minicolors
6f0b295
%endif
6f0b295
6f0b295
# jquery-ui
6f0b295
%if %{unbundle_jquery_ui}
6f0b295
%unbundle_from_with %{static_content}/js/jquery-ui %{_datadir}/javascript/jquery_ui
6f0b295
# FIXME: Unbundle theme (smoothness ?)
6f0b295
#unbundle_from_with %{static_content}/js/jquery-ui/images %{_datadir}/javascript/jquery_ui/themes/smoothness/images
6f0b295
%endif
6f0b295
6f0b295
# jqplot
6f0b295
%if %{unbundle_jqplot}
6f0b295
%unbundle_from_with %{static_content}/js/jqplot %{_datadir}/javascript/jquery-jqplot
6f0b295
%endif
6f0b295
6f0b295
# respond
6f0b295
%if %{unbundle_respond}
6f0b295
%unbundle_from_with %{static_content}/js/respondjs %{_datadir}/javascript
6f0b295
%endif
6f0b295
6f0b295
# Save version info.
6f0b295
mv %{buildroot}%{_sysconfdir}/sympa/data_structure.version \
6f0b295
    %{buildroot}%{_sysconfdir}/sympa/data_structure.current_version
6f0b295
6f0b295
# Copy *httpd config files.
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/httpd/conf.d
6f0b295
%if 0%{?fedora} || 0%{?rhel} >= 7
6f0b295
install -m 0644 %{SOURCE101} %{buildroot}%{_sysconfdir}/httpd/conf.d/sympa.conf
6f0b295
%else
6f0b295
install -m 0644 %{SOURCE100} %{buildroot}%{_sysconfdir}/httpd/conf.d/sympa.conf
6f0b295
%endif
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/lighttpd/conf.d
6f0b295
install -m 0644 %{SOURCE102} %{buildroot}%{_sysconfdir}/lighttpd/conf.d/sympa.conf
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/nginx/conf.d
6f0b295
install -m 0644 %{SOURCE103} %{buildroot}%{_sysconfdir}/nginx/conf.d/sympa.conf
6f0b295
6f0b295
# Copy init scripts or unit files for nginx/spawn-fcgi etc.
6f0b295
%if %{use_systemd}
6f0b295
install -m 0644 src/etc/script/wwsympa.service \
6f0b295
    %{buildroot}%{_unitdir}/wwsympa.service
6f0b295
install -m 0644 src/etc/script/sympasoap.service \
6f0b295
    %{buildroot}%{_unitdir}/sympasoap.service
6f0b295
mkdir -p %{buildroot}%{_tmpfilesdir}
6f0b295
install -m 0644 src/etc/script/sympa-tmpfiles.conf \
6f0b295
    %{buildroot}%{_tmpfilesdir}/sympa.conf
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/systemd/system/sympa.service.d
6f0b295
install -m 0644 %{SOURCE129} \
6f0b295
    %{buildroot}%{_sysconfdir}/systemd/system/sympa.service.d/dependencies.conf
6f0b295
%else
6f0b295
install -m 0755 %{SOURCE104} %{buildroot}%{_initrddir}/wwsympa
6f0b295
install -m 0755 %{SOURCE105} %{buildroot}%{_initrddir}/sympasoap
6f0b295
%endif
6f0b295
6f0b295
# Copy system config file.
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/sysconfig
6f0b295
install -m 0644 %{SOURCE130} %{buildroot}%{_sysconfdir}/sysconfig/sympa
6f0b295
6f0b295
# Copy docs.
6f0b295
mv %{buildroot}%{_docdir}/%{name} __doc
6f0b295
cp -p AUTHORS.md CONTRIBUTING.md NEWS.md README.md __doc/
6f0b295
%if %{use_systemd}
6f0b295
cp -p %{SOURCE113} __doc/README.RPM.md
6f0b295
%else
6f0b295
cp -p %{SOURCE112} __doc/README.RPM.md
6f0b295
%endif
6f0b295
mv %{buildroot}%{_sysconfdir}/sympa/README __doc/
6f0b295
%if 0%{?el6}%{?el7}
6f0b295
ln -s %{_datadir}/doc/%{name}-%{version}/README \
6f0b295
    %{buildroot}/%{_sysconfdir}/sympa/README
6f0b295
ln -s %{_datadir}/doc/%{name}-%{version}/README \
6f0b295
    %{buildroot}/%{_datadir}/sympa/default/README
6f0b295
%else
6f0b295
ln -s %{_datadir}/doc/%{name}/README \
6f0b295
    %{buildroot}/%{_sysconfdir}/sympa/README
6f0b295
ln -s %{_datadir}/doc/%{name}/README \
6f0b295
    %{buildroot}/%{_datadir}/sympa/default/README
6f0b295
%endif
6f0b295
mv %{buildroot}%{_sysconfdir}/sympa/sympa.conf-dist __doc/
6f0b295
6f0b295
# Copy robot aliases.
6f0b295
install -m 0644 %{SOURCE114} %{SOURCE115} %{buildroot}%{_sysconfdir}/sympa/
6f0b295
touch %{buildroot}%{_sysconfdir}/sympa/aliases.sympa.sendmail.db
6f0b295
touch %{buildroot}%{_sysconfdir}/sympa/aliases.sympa.postfix.db
6f0b295
6f0b295
# Copy rsyslog config
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/rsyslog.d
6f0b295
install -m 0644 %{SOURCE106} %{buildroot}%{_sysconfdir}/rsyslog.d/sympa.conf
6f0b295
6f0b295
# Create logrotate item
6f0b295
mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d
6f0b295
install -m 0644 %{SOURCE107} %{buildroot}%{_sysconfdir}/logrotate.d/sympa
6f0b295
6f0b295
# Remove incomplete intranet scenario
6f0b295
rm -rf %{buildroot}%{_datadir}/sympa/default/create_list_templates/intranet_list \
6f0b295
       %{buildroot}%{_datadir}/sympa/default/scenari/*intranet*
6f0b295
6f0b295
# Create configuration override structure
6f0b295
for conffile in \
6f0b295
    auth.conf charset.conf crawlers_detection.conf create_list.conf \
6f0b295
    edit_list.conf nrcpt_by_domain.conf topics.conf \
6f0b295
    mime.types sympa.wsdl ;
6f0b295
    do cp -a %{buildroot}%{_datadir}/%{name}/default/$conffile \
6f0b295
        %{buildroot}%{_sysconfdir}/%{name}/;
6f0b295
done
6f0b295
6f0b295
# Create directory for S/MIME user certificates
6f0b295
mkdir -p %{buildroot}%{_localstatedir}/lib/sympa/X509-user-certs
6f0b295
fc66db9
6f0b295
%check
6f0b295
make check
a3b73be
%if %{with authorcheck}
6f0b295
make authorcheck || true
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%pre
6f0b295
# Create "sympa" group if it does not exist
6f0b295
getent group sympa >/dev/null || /usr/sbin/groupadd -r sympa
6f0b295
6f0b295
# Create "sympa" user if it does not exist
6f0b295
getent passwd sympa >/dev/null || \
6f0b295
  /usr/sbin/useradd -r -g sympa \
6f0b295
      -d %{_localstatedir}/lib/sympa \
6f0b295
      -c "System User for Sympa" \
6f0b295
      -s "/sbin/nologin" \
6f0b295
      sympa
6f0b295
6f0b295
# Fix CSS and pictures paths
6f0b295
if [ $1 -gt 1 ]; then
6f0b295
    if [ -d %{_localstatedir}/lib/%{name}/static_content/css ]; then
6f0b295
        mv -fu %{_localstatedir}/lib/%{name}/static_content/css/* \
6f0b295
            %{_localstatedir}/lib/%{name}/css/ \
6f0b295
            && rm -rf %{_localstatedir}/lib/%{name}/static_content/css/
6f0b295
    fi
6f0b295
    if [ -d %{_localstatedir}/lib/%{name}/static_content/pictures ]; then
6f0b295
        mv -fu %{_localstatedir}/lib/%{name}/static_content/pictures/* \
6f0b295
            %{_localstatedir}/lib/%{name}/pictures/ \
6f0b295
            && rm -rf %{_localstatedir}/lib/%{name}/static_content/pictures/
6f0b295
    fi
6f0b295
    if [ ! -d %{_localstatedir}/lib/%{name}/static_content/css \
6f0b295
        -a ! -d %{_localstatedir}/lib/%{name}/static_content/pictures \
6f0b295
        -a -d %{_localstatedir}/lib/%{name}/static_content ]; then
6f0b295
        rm -r %{_localstatedir}/lib/%{name}/static_content/
6f0b295
    fi
6f0b295
fi
6f0b295
exit 0
6f0b295
6f0b295
6f0b295
%post
6f0b295
# register service
6f0b295
%if %{use_systemd}
6f0b295
%systemd_post sympa.service
6f0b295
%else
6f0b295
/sbin/chkconfig --add sympa
6f0b295
%endif
6f0b295
6f0b295
# create cookie
6f0b295
function create_cookie {
6f0b295
    cook=`mktemp`
6f0b295
    perl -ne 'chomp $_; print $1 if /^cookie\s+(\S.*)/' \
6f0b295
        %{_sysconfdir}/sympa/sympa.conf > $cook
6f0b295
    if [ '!' -s $cook ]; then
6f0b295
        if [ -e %{_sysconfdir}/sympa/cookies.history ]; then
6f0b295
            cp -p %{_sysconfdir}/sympa/cookies.history $cook
6f0b295
        else
6f0b295
            dd if=/dev/urandom bs=2048 count=1 2>/dev/null | md5sum | \
6f0b295
            cut -d" " -f1 > $cook
6f0b295
        fi
6f0b295
        perl -i -pe '/^#cookie\s/ and $_ = "cookie ".`cat '$cook'`."\n"' \
6f0b295
            %{_sysconfdir}/sympa/sympa.conf
6f0b295
    fi
6f0b295
    rm -f $cook
6f0b295
}
6f0b295
6f0b295
# create config at first time.
6f0b295
function create_config {
6f0b295
    ## create site configurations
6f0b295
    if [ '!' -e %{_sysconfdir}/sympa/data_structure.version ]; then
6f0b295
        cp -p %{_sysconfdir}/sympa/data_structure.current_version \
6f0b295
            %{_sysconfdir}/sympa/data_structure.version
6f0b295
    fi
6f0b295
    ## create sympa_aliases
6f0b295
    if [ '!' -e %{_localstatedir}/lib/sympa/sympa_aliases ]; then
6f0b295
        touch %{_localstatedir}/lib/sympa/sympa_aliases
6f0b295
        chown sympa:sympa %{_localstatedir}/lib/sympa/sympa_aliases
6f0b295
        chmod 644 %{_localstatedir}/lib/sympa/sympa_aliases
6f0b295
        touch %{_localstatedir}/lib/sympa/sympa_aliases.db
6f0b295
        chown sympa:root %{_localstatedir}/lib/sympa/sympa_aliases.db
6f0b295
        chmod 664 %{_localstatedir}/lib/sympa/sympa_aliases.db
6f0b295
    fi
6f0b295
}
6f0b295
6f0b295
function upgrade_data_structure {
6f0b295
    # Stop sympa if it is running
6f0b295
%if %{use_systemd}
6f0b295
    if systemctl is-active sympa > /dev/null 2>&1; then
6f0b295
        /usr/bin/systemctl stop sympa > /dev/null 2>&1
6f0b295
        ACTIVE="yes"
6f0b295
    fi
6f0b295
%else
6f0b295
    if [ -e %{_localstatedir}/lock/subsys/sympa ]; then
6f0b295
        /sbin/service sympa stop > /dev/null 2>&1
6f0b295
        ACTIVE="yes"
6f0b295
    fi
6f0b295
%endif
6f0b295
    # Upgrade
6f0b295
    rm -f %{_sysconfdir}/sympa/sympa.conf.bin > /dev/null 2>&1
6f0b295
    if %{_sbindir}/sympa.pl --upgrade > /dev/null 2>&1; then
6f0b295
        # Start sympa if it was running previously
6f0b295
        if [ "$ACTIVE" == "yes" ]; then
6f0b295
%if %{use_systemd}
6f0b295
            /usr/bin/systemctl start sympa > /dev/null 2>&1
6f0b295
%else
6f0b295
            /sbin/service sympa start > /dev/null 2>&1
6f0b295
%endif
6f0b295
        fi
6f0b295
    else
6f0b295
        echo ============================================================
6f0b295
        echo Notice: Failed upgrading data structure.  See logfile.
6f0b295
        echo Sympa is stopped.
6f0b295
        echo ============================================================
6f0b295
    fi
6f0b295
}
6f0b295
6f0b295
# Install
6f0b295
if [ $1 -eq 1 ]; then
6f0b295
    create_cookie
6f0b295
    create_config
6f0b295
    echo ============================================================
6f0b295
    echo Sympa had been installed successfully.  If you installed
6f0b295
    echo Sympa at first time, please read:
6f0b295
    echo %{_docdir}/%{name}-%{version}/README.RPM.md
6f0b295
    echo ============================================================
6f0b295
fi
6f0b295
6f0b295
# Update
6f0b295
if [ $1 -gt 1 ]; then
6f0b295
    upgrade_data_structure
6f0b295
fi
6f0b295
6f0b295
6f0b295
%if 0%{?fedora} || 0%{?rhel} >= 7
6f0b295
%post httpd
6f0b295
# register service
6f0b295
%systemd_post wwsympa.service
6f0b295
%systemd_post sympasoap.service
6f0b295
%endif
6f0b295
fc66db9
6f0b295
%post nginx
6f0b295
# register service
6f0b295
%if %{use_systemd}
6f0b295
%systemd_post wwsympa.service
6f0b295
%systemd_post sympasoap.service
6f0b295
%else
6f0b295
/sbin/chkconfig --add wwsympa
6f0b295
/sbin/chkconfig --add sympasoap
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%preun
6f0b295
%if %{use_systemd}
6f0b295
%systemd_preun sympa.service
6f0b295
%else
6f0b295
if [ $1 -eq 0 ] ; then
6f0b295
    /sbin/service sympa stop >/dev/null 2>&1
6f0b295
    /sbin/chkconfig --del sympa
6f0b295
fi
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%if 0%{?fedora} || 0%{?rhel} >= 7
6f0b295
%preun httpd
6f0b295
%systemd_preun wwsympa.service
6f0b295
%systemd_preun sympasoap.service
6f0b295
%endif
6f0b295
fc66db9
6f0b295
%preun nginx
6f0b295
%if %{use_systemd}
6f0b295
%systemd_preun wwsympa.service
6f0b295
%systemd_preun sympasoap.service
6f0b295
%else
6f0b295
if [ $1 -eq 0 ] ; then
6f0b295
    /sbin/service wwsympa stop >/dev/null 2>&1
6f0b295
    /sbin/service sympasoap stop >/dev/null 2>&1
6f0b295
    /sbin/chkconfig --del wwsympa
6f0b295
    /sbin/chkconfig --del sympasoap
6f0b295
fi
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%postun
6f0b295
%if %{use_systemd}
6f0b295
%systemd_postun_with_restart sympa.service
6f0b295
%else
6f0b295
if [ "$1" -ge "1" ] ; then
6f0b295
    /sbin/service sympa condrestart >/dev/null 2>&1 || :
6f0b295
fi
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%if 0%{?fedora} || 0%{?rhel} >= 7
6f0b295
%postun httpd
6f0b295
%systemd_postun_with_restart wwsympa.service
6f0b295
%systemd_postun_with_restart sympasoap.service
6f0b295
%endif
6f0b295
fc66db9
6f0b295
%postun nginx
6f0b295
%if %{use_systemd}
6f0b295
%systemd_postun_with_restart wwsympa.service
6f0b295
%systemd_postun_with_restart sympasoap.service
6f0b295
%else
6f0b295
if [ "$1" -ge "1" ] ; then
6f0b295
    /sbin/service wwsympa condrestart >/dev/null 2>&1 || :
6f0b295
    /sbin/service sympasoap condrestart >/dev/null 2>&1 || :
6f0b295
fi
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%files -f %{name}.lang -f web_help.lang
6f0b295
%doc __doc/*
6f0b295
%license COPYING
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/
6f0b295
%{_sysconfdir}/sympa/README
6f0b295
%config(noreplace) %attr(0640,sympa,sympa) %{_sysconfdir}/sympa/sympa.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/auth.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/charset.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/crawlers_detection.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/create_list.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/edit_list.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/nrcpt_by_domain.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/topics.conf
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/mime.types
6f0b295
%config(noreplace,missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/sympa.wsdl
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/create_list_templates
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/tasks
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/scenari
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/mail_tt2
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/web_tt2
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/custom_actions
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/custom_conditions
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/data_sources
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/families
6f0b295
%dir %attr(-,sympa,sympa) %{_sysconfdir}/sympa/search_filters
6f0b295
%config(missingok) %attr(-,sympa,sympa) %{_sysconfdir}/sympa/data_structure.current_version
6f0b295
%config(noreplace) %{_sysconfdir}/sympa/aliases.sympa.sendmail
6f0b295
%config(noreplace) %{_sysconfdir}/sympa/aliases.sympa.sendmail.db
6f0b295
%config(noreplace) %{_sysconfdir}/sympa/aliases.sympa.postfix
6f0b295
%config(noreplace) %{_sysconfdir}/sympa/aliases.sympa.postfix.db
6f0b295
%{_sysconfdir}/smrsh/*
6f0b295
%config(noreplace) %{_sysconfdir}/rsyslog.d/*
6f0b295
%config(noreplace) %{_sysconfdir}/logrotate.d/sympa
6f0b295
%{_sbindir}/*
6f0b295
%dir %{_libexecdir}/sympa/
6f0b295
%attr(4755,sympa,sympa) %{_libexecdir}/sympa/bouncequeue
6f0b295
%attr(4755,sympa,sympa) %{_libexecdir}/sympa/familyqueue
6f0b295
%attr(4755,sympa,sympa) %{_libexecdir}/sympa/queue
6f0b295
%attr(4750,root,sympa) %{_libexecdir}/sympa/sympa_newaliases-wrapper
6f0b295
%{_libexecdir}/sympa/sympa_soap_server.fcgi
6f0b295
%attr(6755,sympa,sympa) %{_libexecdir}/sympa/sympa_soap_server-wrapper.fcgi
6f0b295
%{_libexecdir}/sympa/wwsympa.fcgi
6f0b295
%attr(6755,sympa,sympa) %{_libexecdir}/sympa/wwsympa-wrapper.fcgi
6f0b295
%dir %{_localstatedir}/lib/sympa/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/lib/sympa/arc/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/lib/sympa/bounce/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/lib/sympa/list_data/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/lib/sympa/css/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/lib/sympa/pictures/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/lib/sympa/X509-user-certs/
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/spool/sympa/
6f0b295
%{_datadir}/sympa/
6f0b295
%{_mandir}/man1/*
6f0b295
%{_mandir}/man5/*
6f0b295
%{_mandir}/man8/*
6f0b295
%if %{use_systemd}
6f0b295
%{_unitdir}/sympa.service
6f0b295
%{_unitdir}/sympa-outgoing.service
6f0b295
%{_unitdir}/sympa-archive.service
6f0b295
%{_unitdir}/sympa-bounce.service
6f0b295
%{_unitdir}/sympa-task.service
6f0b295
%{_tmpfilesdir}/sympa.conf
6f0b295
%ghost %attr(-,sympa,sympa) %{_rundir}/sympa/
6f0b295
%dir %{_sysconfdir}/systemd/system/sympa.service.d/
6f0b295
%config(noreplace) %{_sysconfdir}/systemd/system/sympa.service.d/*
6f0b295
%else
6f0b295
%{_initrddir}/sympa
6f0b295
%attr(-,sympa,sympa) %{_localstatedir}/run/sympa/
6f0b295
%endif
6f0b295
%config(noreplace) %{_sysconfdir}/sysconfig/sympa
6f0b295
6f0b295
6f0b295
%files httpd
6f0b295
%config(noreplace) %{_sysconfdir}/httpd/conf.d/sympa.conf
6f0b295
%if 0%{?fedora} || 0%{?rhel} >= 7
6f0b295
%if %{use_systemd}
6f0b295
%{_unitdir}/wwsympa.service
6f0b295
%{_unitdir}/sympasoap.service
6f0b295
%else
6f0b295
%{_initrddir}/wwsympa
6f0b295
%{_initrddir}/sympasoap
6f0b295
%endif
6f0b295
%endif
6f0b295
6f0b295
6f0b295
%files lighttpd
6f0b295
%config(noreplace) %{_sysconfdir}/lighttpd/conf.d/sympa.conf
6f0b295
6f0b295
6f0b295
%files nginx
6f0b295
%config(noreplace) %{_sysconfdir}/nginx/conf.d/sympa.conf
6f0b295
%if %{use_systemd}
6f0b295
%{_unitdir}/wwsympa.service
6f0b295
%{_unitdir}/sympasoap.service
6f0b295
%else
6f0b295
%{_initrddir}/wwsympa
6f0b295
%{_initrddir}/sympasoap
6f0b295
%endif
6f0b295
fc66db9
6f0b295
%files devel-doc
6f0b295
%{_mandir}/man3/*
6f0b295
6f0b295
6f0b295
%changelog
87fc0a3
* Thu Jul 18 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.44-3
87fc0a3
- Don't build for ix86 on EL6.
87fc0a3
- Re-order some parts of spec for better readability.
87fc0a3
- Use bcond_with macro instead of custom macros.
87fc0a3
6f0b295
* Mon Jul 15 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.44-2
6f0b295
- Don't package OChangeLog and ONEWS. Saves 5MB.
6f0b295
- Move developers documentation to devel-doc sub-package.
6f0b295
- Compute an accurate License: tag.
6f0b295
6f0b295
* Wed Jun 26 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.44-1
6f0b295
- Update to 6.2.44.
6f0b295
6f0b295
* Mon Jun 10 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.43-0.2.b.2
6f0b295
- Update to 6.2.43 beta 2.
6f0b295
6f0b295
* Thu May 23 2019 IKEDA Soji <ikeda@conversion.co.jp> 6.2.43-0.1.b.1
6f0b295
- Update to 6.2.43 beta 1.
6f0b295
- Move sympa.conf-dist to doc.
6f0b295
6f0b295
* Thu Mar 21 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.42-1
6f0b295
- Update to 6.2.42.
6f0b295
6f0b295
* Sun Mar 10 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.41-0.2.b.2
6f0b295
- Update to 6.2.41 beta 2.
6f0b295
6f0b295
* Sun Feb 03 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.41-0.1.b.1
6f0b295
- Update to 6.2.41 beta 1.
6f0b295
6f0b295
* Mon Jan 28 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.40-2
6f0b295
- Unbundle jqplot on F29+.
6f0b295
- Use versioned Requires and BuildRequires for unbundled fonts and libs.
6f0b295
6f0b295
* Sat Jan 19 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.40-1
6f0b295
- Update to 6.2.40.
6f0b295
6f0b295
* Fri Jan 11 2019 Xavier Bachelot <xavier@bachelot.org> 6.2.38-2
6f0b295
- Fix fontawesome, jquery-ui and jquery-migrate unbundling on EL7.
6f0b295
- Fix wwsympa/sympasoap not being restarted on update.
6f0b295
6f0b295
* Fri Dec 21 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.38-1
6f0b295
- Update to 6.2.38.
6f0b295
6f0b295
* Sat Dec 08 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.37-0.3.b.3
6f0b295
- Update to 6.2.37 beta 3.
6f0b295
6f0b295
* Sat Nov 03 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.37-0.2.b.2
6f0b295
- Update to 6.2.37 beta 2.
6f0b295
6f0b295
* Sun Oct 07 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.37-0.1.b.1
6f0b295
- Update to 6.2.37 beta 1.
6f0b295
6f0b295
* Sun Sep 23 2018 IKEDA Soji <ikeda@conversion.co.jp> 6.2.36-1
6f0b295
- Update to 6.2.36.
6f0b295
6f0b295
* Sun Aug 26 2018 IKEDA Soji <ikeda@conversion.co.jp> 6.2.35-0.1.b.1
6f0b295
- Update to 6.2.35b.1.
6f0b295
- For sympa-httpd with Fedora & EL7: Use mod_proxy_fcgi instead of mod_fcgid.
6f0b295
6f0b295
* Sun Aug 26 2018 IKEDA Soji <ikeda@conversion.co.jp> 6.2.34-2
6f0b295
- Issue #36: Init scripts for wwsympa/sympasoap were broken.
6f0b295
6f0b295
* Thu Jul 05 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.34-1
6f0b295
- Update to 6.2.34.
6f0b295
6f0b295
* Fri Jun 29 2018 IKEDA Soji <ikeda@conversion.co.jp> 6.2.33-0.2.b.2
6f0b295
- Update to 6.2.33 beta 2.
6f0b295
  Upstream #170 WWSympa: Switch to Foundation 6
6f0b295
  Upstream #220 static_content directory structure
6f0b295
  Upstream #336 Starting a test framework
6f0b295
6f0b295
* Wed Apr 25 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.32-2
6f0b295
- Add missing Requires on EL6 and EL7.
6f0b295
6f0b295
* Thu Apr 19 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.32-1
6f0b295
- Update to 6.2.32 (Security release).
6f0b295
  See https://sympa-community.github.io/security/2018-001.html
6f0b295
6f0b295
* Mon Mar 26 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.30-1
6f0b295
- Update to 6.2.30.
6f0b295
6f0b295
* Thu Mar 22 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.28-1
6f0b295
- Update to 6.2.28.
6f0b295
6f0b295
* Tue Mar 20 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.26-1
6f0b295
- Update to 6.2.26.
6f0b295
- Fix scriptlet.
6f0b295
6f0b295
* Tue Mar 13 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.25-0.3.b.3
6f0b295
- Update to 6.2.25 beta 3.
6f0b295
- Add Requires on optional Crypt::Eksblowfish.
6f0b295
6f0b295
* Mon Mar 05 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.25-0.2.b.2
6f0b295
- Update to 6.2.25 beta 2.
6f0b295
- Move static_content to an FHS compliant location.
6f0b295
6f0b295
* Tue Feb 13 2018 Xavier Bachelot <xavier@bachelot.org> 6.2.25-0.1.b.1
6f0b295
- Update to 6.2.25 beta 1.
6f0b295
- Remove useless and bogus directories creation for conf override.
6f0b295
- Own the now properly created css and pictures directories.
6f0b295
  Subsequently the above directory doesn't need to be writable anymore.
6f0b295
- Unbundle Raleway font.
6f0b295
- Simplify sysvinit/systemd in configure.
6f0b295
6f0b295
* Tue Dec 26 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.24-2
6f0b295
- Ensure newaliases works out of the box.
6f0b295
6f0b295
* Thu Dec 21 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.24-1
6f0b295
- Update to 6.2.24.
6f0b295
6f0b295
* Thu Dec 14 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.23-0.4.b.3
6f0b295
- Update to 6.2.23 beta 3.
6f0b295
6f0b295
* Tue Dec 12 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.23-0.4.b.2
6f0b295
- Unbundle jquery (Fedora only).
6f0b295
6f0b295
* Thu Nov 30 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.23-0.3.b.2
6f0b295
- Update to 6.2.23 beta 2.
6f0b295
6f0b295
* Wed Nov 22 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.23-0.2.b.1
6f0b295
- Specify all build dependencies. Fixes test suite failure on F25/F26.
6f0b295
6f0b295
* Mon Nov 20 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.23-0.1.b.1
6f0b295
- Update to 6.2.23 beta 1.
6f0b295
- Drop upstream patches.
6f0b295
- Add missing BuildRequires:.
6f0b295
- Remove duplicate Requires:.
6f0b295
- Fix License: to acknowledge for bundled javascript libraries.
6f0b295
- Track more bundled javascript libraries.
6f0b295
6f0b295
* Wed Nov 08 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.22-4
6f0b295
- Run autoreconf for jquery patch.
6f0b295
6f0b295
* Wed Oct 25 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.22-3
6f0b295
- Fix scriplet bug in upgrade_data_structure.
6f0b295
- Unbundle font-awesome.
6f0b295
6f0b295
* Fri Oct 20 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.22-2
6f0b295
- Add patches from upstream sympa-6.2 branch.
6f0b295
6f0b295
* Tue Oct 03 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.22-1
6f0b295
- Update to 6.2.22.
6f0b295
6f0b295
* Thu Sep 14 2017 Xavier Bachelot <xavier@bachelot.org> 6.2.19-0.2.b.2
6f0b295
- Rework spec to better comply with Fedora packaging guidelines.
6f0b295
6f0b295
* Sat Aug 19 2017 IKEDA Soji <ikeda@conversion.co.jp> 6.2.19b.1-1
6f0b295
- Added --bindir to install sympa_smtpc under libexecdir.
6f0b295
6f0b295
* Sun Jun 25 2017 IKEDA Soji <ikeda@conversion.co.jp> 6.2.18-1
6f0b295
- Updated.
6f0b295
6f0b295
* Thu Jun 15 2017 IKEDA Soji <ikeda@conversion.co.jp> 6.2.17b.2-1
6f0b295
- Updated README.RPM.md.
6f0b295
6f0b295
* Sun Aug 07 2016 IKEDA Soji <ikeda@conversion.co.jp> 6.2.17-1
6f0b295
- Typos in el6-README.RPM.
6f0b295
- Added a build dependency perl(Test::Harness).
6f0b295
- Added a dependency perl(Unicode::Normalize).
6f0b295
- Added a definition parameter %%{do_autoreconf}.
6f0b295
6f0b295
* Sat Jun 18 2016 IKEDA Soji <ikeda@conversion.co.jp> 6.2.16-1
6f0b295
- Adopted adjustment to Fedora by Xavier Bachelot <xavier@bachelot.org>.
6f0b295
- Avoiding use of buildroot macro in build section.
6f0b295
- Simplified configure option.
6f0b295
- Added patch14 to disable service by default.
6f0b295
- Added unit customization file source129.
6f0b295
6f0b295
* Thu Feb 26 2015 IKEDA Soji <ikeda@conversion.co.jp> 6.2-1
6f0b295
- New minor release sympa-6.2.