%define samba_version 4.1.6
%define doc_version 4.0.7
%define api_version 4.0
%define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}

%global with_libsmbclient 1
%global with_libwbclient  1
%global with_pam_smbpass  1
%global with_talloc       0
%global with_tevent       0
%global with_tdb          0
%global with_ntdb         1
%global with_ldb          0
%global with_usrmove      0
%global with_mitkrb5      0
%global with_dc           1

%define samba_release 1

%define samba_source source3

%global __perl_requires %{SOURCE999}
%global __perllib_requires %{SOURCE999}
%global __perllib_provides %{SOURCE999}

Summary: The Samba Suite of programs
Summary(ja): Samba スイート
Name: samba
Version: %{samba_version}
Release: %{samba_release}%{?_dist_release}
License: GPLv3+
Group: System Environment/Daemons
URL: http://www.samba.org/

%define samba_includedir   %{_includedir}/samba-%{api_version}

Source: http://www.samba.org/samba/ftp/samba-%{version}.tar.gz

# Vine specific replacement-files
Source1: samba.log
Source2: samba-ja-docs-%{doc_version}.tar.gz
Source5: pam_winbind.conf

Source100:     nmb.init
Source101:     smb.init
Source102:     winbind.init
Source200:     samba4.init
Source201:     named.conf.dlz

Source999: perl-requires.sh

Requires: /sbin/chkconfig /bin/mktemp /usr/bin/killall
Requires: fileutils sed /etc/init.d
Requires: logrotate
Requires: libaio
Requires: %{name}-common = %{samba_version}-%{release}
Requires: %{name}-libs   = %{samba_version}-%{release}
Requires(pre): %{name}-common = %{samba_version}-%{release}

Conflicts: samba < %{version}
Provides: samba = %{version}

BuildRoot: %{_tmppath}/%{name}-%{samba_version}-%{release}-root
Requires(post): /sbin/chkconfig, /sbin/service
Requires(preun): /sbin/chkconfig, /sbin/service

BuildRequires: avahi-devel
BuildRequires: ctdb-devel
BuildRequires: cups-devel
BuildRequires: cyrus-sasl-devel
BuildRequires: docbook-style-xsl
BuildRequires: docbook-utils
BuildRequires: e2fsprogs-devel
BuildRequires: coreutils
BuildRequires: gdb
BuildRequires: gettext
BuildRequires: gnutls-devel
BuildRequires: keyutils-libs-devel
BuildRequires: krb5-devel
BuildRequires: krb5-workstation
BuildRequires: libacl-devel
BuildRequires: libattr-devel
BuildRequires: libblkid-devel
BuildRequires: libbsd-devel
BuildRequires: libidn-devel
BuildRequires: libldb-devel
BuildRequires: libpcap-devel
BuildRequires: libxml2-devel
BuildRequires: libxslt
BuildRequires: net-tools
BuildRequires: openldap-devel
BuildRequires: pam-devel
BuildRequires: perl(ExtUtils::MakeMaker)
BuildRequires: perl(Parse::Yapp)
BuildRequires: pkgconfig
BuildRequires: popt-devel
BuildRequires: pyldb-devel
BuildRequires: pytalloc-devel
BuildRequires: python-devel
BuildRequires: python-tdb
BuildRequires: python-tevent
BuildRequires: readline-devel
BuildRequires: sqlite-devel
BuildRequires: zlib-devel

#BuildRequires: libuuid-devel

BuildConflicts: compat32-zlib-devel.32bit
BuildConflicts: compat32-libuuid.32bit
BuildConflicts: compat32-libuuid-devel.32bit

# Working around perl dependency problem from docs
#define __perl_requires %{SOURCE999}


Vendor: Project Vine
Distribution: Vine Linux
Packager: tomop


%description
Samba is the standard Windows interoperability suite of programs
for Linux and Unix.

%description -l ja
SambaはLinux・UNIX用の、Windowsとの標準的な相互運用性ソフトウェア群です。

## --------------------------------------------------------------------
%package client
Summary: Samba client programs
Summary(ja): Samba クライアントプログラム
Group: Applications/System
Requires: samba-common = %{samba_version}-%{release}
Obsoletes: smbfs
Conflicts: %{name}-client < %{samba_version}
Provides: samba-client = %{samba_version}

%description client
The samba-client package provides some SMB/CIFS clients to complement
the built-in SMB/CIFS filesystem in Linux. These clients allow access
of SMB/CIFS shares and printing to SMB/CIFS printers.

%description client -l ja
samba-client は Linux カーネルがサポートしている SMB ファイルシステム
機能を操作する SMB クライアントを提供します。
これらは SMB 共有のアクセスと SMB プリンタへの印刷を実現します。

## --------------------------------------------------------------------
%package libs
Summary: Samba libraries
Group: Applications/System
%if %with_libwbclient
Requires: libwbclient
%endif

%description libs
The samba4-libs package contains the libraries needed by programs that
link against the SMB, RPC and other protocols provided by the Samba suite.

## --------------------------------------------------------------------
%package python
Summary: Samba Python libraries
Group: Applications/System
Requires: %{name}-libs = %{samba_version}

%description python
The samba4-python package contains the Python libraries needed by programs
that use SMB, RPC and other Samba provided protocols in Python programs.

## --------------------------------------------------------------------
%package devel
Summary: Developer tools for Samba libraries
Group: Development/Libraries
Requires: %{name}-libs = %{samba_version}-%{release}

Conflicts: samba-devel < %{samba_version}
Provides: samba-devel = %{samba_version}

%description devel
The samba4-devel package contains the header files for the libraries
needed to develop programs that link against the SMB, RPC and other
libraries in the Samba suite.

## --------------------------------------------------------------------
%package pidl
Summary: Perl IDL compiler
Group: Development/Tools
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

%description pidl
The samba4-pidl package contains the Perl IDL compiler used by Samba
and Wireshark to parse IDL and similar protocols

## --------------------------------------------------------------------
%package common
Summary: Files used by both Samba servers and clients
Summary(ja): Samba サーバーとクライアントの両方に使用されるファイル
Group: Applications/System
Conflicts: samba-common < %{samba_version}
Provides: samba-common = %{samba_version}-%{release}
Requires: %{name}-libs = %{samba_version}-%{release}
Requires: pam
Requires(pre): /usr/sbin/groupadd
Requires(post): /sbin/chkconfig, /sbin/service, coreutils, acl
Requires(preun): /sbin/chkconfig, /sbin/service
Obsoletes: samba-swat < 4.1.0

%description common
Samba-common provides files necessary for both the server and client
packages of Samba.

%description common -l ja
samba-common は Samba のサーバーとクライアントの両方のパッケージで
使用される共通のファイルを提供します。

## --------------------------------------------------------------------
%package test
Summary: Testing tools for Samba servers and clients
Group: Applications/System

%description test
samba4-test provides testing tools for both the server and client
packages of Samba.

## --------------------------------------------------------------------
%package winbind
Summary: Samba winbind
Group: Applications/System
Conflicts: samba-winbind < %{samba_version}
Provides: samba-winbind = %{samba_version}
Requires: samba-common = %{samba_version}-%{release}
Requires(pre): /usr/sbin/groupadd
Requires(post): /sbin/chkconfig, /sbin/service, coreutils
Requires(preun): /sbin/chkconfig, /sbin/service

%description winbind
The samba-winbind package provides the winbind daemon, a NSS library, a PAM
module and some client tools. Winbind enables Linux to be a full member in
Windows domains and to use Windows user and group accounts on Linux.


## --------------------------------------------------------------------
%package winbind-krb5-locator
Summary: Samba winbind krb5 locator
Group: Applications/System
Requires: %{name}-winbind-clients = %{samba_version}-%{release}
Conflicts: samba-winbind-krb5-locator < %{samba_version}
Provides: samba-winbind-krb5-locator = %{samba_version}-%{release}

%description winbind-krb5-locator
The winbind krb5 locator is a plugin for the system kerberos library
to allow the local kerberos library to use the same KDC as samba and
winbind use

## --------------------------------------------------------------------
%package winbind-clients
Summary: Samba winbind clients
Group: Applications/System
Conflicts: samba-winbind-clients < %{samba_version}
Provides: samba-winbind-clients = %{samba_version}

%description winbind-clients
The %{name}-winbind-clients package provides the NSS library and a PAM
module necessary to communicate to the Winbind Daemon

## --------------------------------------------------------------------
%package -n libsmbclient
Summary: The SMB client library
Summary(ja): SMB クライアントライブラリ
Group: Applications/System
Requires: %{name}-common = %{samba_version}

Conflicts: libsmbclient < %{samba_version}
Provides: libsmbclient = %{samba_version}

%description -n libsmbclient
The libsmbclient contains the SMB client library from the Samba suite.

%description -n libsmbclient -l ja
libsmbclient は Samba クライアントの機能を提供するライブラリを
提供します。

## --------------------------------------------------------------------
%package -n libsmbclient-devel
Summary: Developer tools for the SMB client library
Summary(ja): SMB クライアントライブラリ開発用ファイル
Group: Development/Libraries
Requires: libsmbclient = %{samba_version}

Conflicts: libsmbclient-devel < %{samba_version}
Provides: libsmbclient-devel = %{samba_version}

%description -n libsmbclient-devel
 The libsmbclient-devel package contains the header files and libraries
needed to develop programs that link against the SMB client library
in the Samba suite.

%description -n libsmbclient-devel -l ja
libsmbclient-devel は Samba クライアントの機能を提供するライブラリを
使ったアプリケーションを開発するためのファイルを提供します。

## --------------------------------------------------------------------
%if %with_libwbclient
%package -n libwbclient
Summary: The winbind client library
Group: Applications/System

%description -n libwbclient
 The libwbclient package contains the winbind client library from
the Samba suite.

## --------------------------------------------------------------------
%package -n libwbclient-devel
Summary: Developer tools for the winbind library
Group: Development/Libraries
Requires: libwbclient = %{samba_version}-%{release}

%description -n libwbclient-devel
 The libwbclient-devel package provides developer tools for the wbclient
library.
%endif # with_libwbclient

## --------------------------------------------------------------------
%package dc
Summary: Samba AD Domain Controller
Group: Applications/System
Requires: %{name} = %{samba_version}-%{release}
Requires: %{name}-winbind = %{samba_version}-%{release}
Requires: %{name}-client = %{samba_version}-%{release}
Requires: %{name}-python = %{samba_version}-%{release}
Requires(post): /sbin/chkconfig, /sbin/service, acl

%description dc
The %{name}-dc package provides AD Domain Controller functionality

## --------------------------------------------------------------------
%if %build_compat32

%package -n compat32-libsmbclient
Summary: The SMB client library
Summary(ja): SMB クライアントライブラリ
Group: System Environment/Libraries
Requires: samba-common = %{samba_version}-%{release}

%description -n compat32-libsmbclient
The libsmbclient contains the SMB client library from the Samba suite.

%description -n compat32-libsmbclient -l ja
libsmbclient は Samba クライアントの機能を提供するライブラリを
提供します。

## --------------------------------------------------------------------
%package -n compat32-libwbclient
Summary: The winbind client library
Group: Applications/System
Requires: samba-common = %{samba_version}-%{release}
Requires(pre): /usr/sbin/groupadd
Requires(post): /sbin/chkconfig, /sbin/service, coreutils
Requires(preun): /sbin/chkconfig, /sbin/service

%description -n compat32-libwbclient
 The libwbclient package contains the winbind client library from
the Samba suite.

%endif

## ====================================================================
%prep
%setup -q -n samba-%{samba_version}

#mkdir -p docs-ja
#pushd docs-ja
#tar zxf %{SOURCE2}
#popd

## ====================================================================
%build
sed \
  -e 's|@PROG_CMD@|%{_sbindir}\/samba|g' \
  -e 's|@SAMBA_PID@|%{_var}\/run\/samba/samba\.pid|g' \
  %{SOURCE200} > samba4.init

make distclean

##export PATH=$PATH:$PWD/buildtools/bin
./configure \
  --bundled-libraries=!talloc,!tdb,!pytdb,!ldb,!pyldb,!tevent,!pytevent,!ctdb \
  --with-gettext=/usr \
  --with-shared-modules=idmap_rid,idmap_ad,idmap_tdb2,idmap_hash \
  --with-winbind \
  --with-ads \
  --with-ldap \
  --with-pam \
  --with-pam_smbpass \
  --with-quotas \
  --with-sendfile-support \
  --with-utmp \
  --with-acl-support \
  --with-dnsupdate \
  --with-syslog \
  --with-automount \
  --with-cluster-support \
  --with-ctdb-dir=/usr \
  --with-aio-support \
  --disable-rpath-install \
  --enable-selftest \
  --enable-gnutls \
  --enable-cups \
  --enable-fhs \
  --enable-avahi \
  --prefix=%{_prefix} \
  --localstatedir=/var \
  --libdir=%{_libdir} \
  --mandir=%{_mandir} \
  --with-configdir=%{_sysconfdir}/samba \
  --with-modulesdir=%{_libdir}/samba \
  --with-pammodulesdir=%{_lib}/security \
  --with-lockdir=/var/lib/samba \
  --with-logfilebase=/var/log/samba \
  --with-piddir=/var/run/samba \
  --with-privatedir=/var/lib/samba/private

#  --bundled-libraries=NONE \
#  --with-system-mitkrb5 \


# try and build the manpages
#./release-scripts/build-manpages-nogit

make %{?_smp_mflags} all


# Remove some permission bits to avoid to many dependencies
find examples docs-xml -type f | xargs -r chmod -x

## ====================================================================
%install
rm -rf %{buildroot}

# Create the target build directory hierarchy
mkdir -p %{buildroot}%{samba_includedir}
mkdir -p %{buildroot}%{_initrddir}
mkdir -p %{buildroot}{%{_libdir},%{samba_includedir}}
mkdir -p %{buildroot}%{_libdir}/samba/{auth,charset,idmap,vfs,pdb}
mkdir -p %{buildroot}%{_libdir}/pkgconfig
mkdir -p %{buildroot}/%{_lib}/security
mkdir -p %{buildroot}%{_mandir}
mkdir -p %{buildroot}%{_prefix}/{bin,sbin}
#mkdir -p %{buildroot}%{_prefix}/lib
mkdir -p %{buildroot}%{_sysconfdir}/{pam.d,samba,logrotate.d}
mkdir -p %{buildroot}%{_sysconfdir}/rc.d/init.d
mkdir -p %{buildroot}%{_sysconfdir}/{samba,security,sysconfig}
mkdir -p %{buildroot}%{_sysconfdir}/xinetd.d
mkdir -p %{buildroot}/var/lib/samba/{private,winbindd_privileged,sysvol}
mkdir -p %{buildroot}/var/{run/winbindd,spool}/samba
mkdir -p %{buildroot}/var/log/samba/old
mkdir -p %{buildroot}/%{_libdir}/krb5/plugins/libkrb5

# substitude for passing DESTDIR to waf
#rpm_build_root_escaped=$(echo %{buildroot} | sed -e "s|\/|\\\/|g")
#sed -e "1,4s/\(WAF_BINARY.*$\)/\1 --destdir=%{buildroot}_escaped/" Makefile \
#  > Makefile~; \
#  cat Makefile~ > Makefile; \
#  rm Makefile~

# modify named.conf.dlz
#sed -e "s|\$\{MODULESDIR\}|%{_datadir}\/samba/setup|" source4/setup/named.conf.dlz \
#  > source4/setup/named.conf.dlz~; \
#  cat source4/setup/named.conf.dlz~ > source4/setup/named.conf.dlz; \
#  rm source4/setup/named.conf.dlz~

#DESTDIR=%{buildroot} ./buildtools/bin/waf install
./buildtools/bin/waf install --destdir %{buildroot}

# krb5 plugin install #FIXME: remove autoinstalled?
install -m 0755 bin/shared/winbind_krb5_locator.so \
          ${RPM_BUILD_ROOT}/%{_libdir}/krb5/plugins/libkrb5/winbind_krb5_locator.so

# Install the miscellany
echo 127.0.0.1 localhost > %{buildroot}%{_sysconfdir}/samba/lmhosts
install -m 0644 packaging/systemd/samba.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/samba
#install -m755 setup/smb.init %{buildroot}%{_initrddir}/smb
install -m755 packaging/RHEL/setup/winbind.init %{buildroot}%{_initrddir}/winbind
install -m644 packaging/RHEL/setup/samba.pamd %{buildroot}%{_sysconfdir}/pam.d/samba
#install -m755 packaging/RHEL/setup/smbprint %{buildroot}%{_bindir}
install -m644 packaging/RHEL/setup/smbusers %{buildroot}%{_sysconfdir}/samba/smbusers
install -m644 packaging/RHEL/setup/smb.conf %{buildroot}%{_sysconfdir}/samba/smb.conf
#install -m755 source3/script/mksmbpasswd.sh %{buildroot}%{_bindir}
install -m644 %{SOURCE1} %{buildroot}%{_sysconfdir}/logrotate.d/samba
install -m644 %{SOURCE5} %{buildroot}%{_sysconfdir}/security/pam_winbind.conf
install -m644 %{SOURCE201} %{buildroot}%{_datadir}/samba/setup/named.conf.dlz
install -m755 %{SOURCE100} %{buildroot}%{_initrddir}/nmb
install -m755 %{SOURCE101} %{buildroot}%{_initrddir}/smb
install -m755 %{SOURCE102} %{buildroot}%{_initrddir}/winbind
install -m755 samba4.init %{buildroot}%{_initrddir}/samba

#ln -s ../..%{_initrddir}/smb  %{buildroot}%{_sbindir}/samba
#ln -s ../..%{_initrddir}/winbind  %{buildroot}%{_sbindir}/winbind

mkdir -p %{buildroot}%{_datadir}/samba/perl5/
mv %{buildroot}%{_datadir}/perl5/* %{buildroot}%{_datadir}/samba/perl5/
perl -pi -e 's|^(use .*RealBin.*)/perl5|#\1/samba/perl5|' %{buildroot}%{_bindir}/pidl

# Remove "*.old" files
find %{buildroot} -name "*.old" -exec rm -f {} \;

## Clean out man pages for tools not installed here
#rm -f %{buildroot}%{_mandir}/man1/log2pcap.1*
#rm -f %{buildroot}%{_mandir}/man1/smbsh.1*
#rm -f %{buildroot}%{_mandir}/man5/vfstest.1*
rm -f %{buildroot}%{_libdir}/winbind_krb5_locator.so

# pkgconfig remove 
rm -f %{buildroot}%{_libdir}/pkgconfig/dcerpc.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/dcerpc_atsvc.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/dcerpc_samr.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/gensec.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/ndr.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/ndr_krb5pac.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/ndr_nbt.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/ndr_standard.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/netapi.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/registry.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/samba-credentials.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/samba-hostconfig.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/samba-policy.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/samba-util.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/samdb.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/smbclient-raw.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/talloc.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/tevent.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/torture.pc
rm -f %{buildroot}%{_libdir}/pkgconfig/dcerpc_server.pc

#find docs-ja/output/manpages/ -type f| while read f; do
#  c=`echo -n $f | sed -e 's,^.*\.,,'`
#  gzip -9 $f
#  mkdir -p %{buildroot}%{_mandir}/ja/man$c
#  cp -f $f.gz %{buildroot}%{_mandir}/ja/man$c/
#done


## ====================================================================
%clean
rm -rf %{buildroot}

%pre
if [ "$1" -eq "2" ]; then
  PREV=`/usr/sbin/smbd -V 2>/dev/null | sed -e 's/^Version \([0-9]*\)\..*$/\1/'`
  if [ "x$PREV" == "x3" ]; then
    /sbin/service smb stop >/dev/null 2>&1 || :
    /sbin/service nmb stop >/dev/null 2>&1 || :

    cp -af %{_sysconfdir}/samba/smb.conf %{_sysconfdir}/samba/smb.conf.samba3
    cp -af /var/lib/samba /var/lib/samba3

    echo "Samba is upgraded from version 3.x to 4.x and daemons are stopped."
    echo "Please check and update configurations."
    echo
    echo "The old files are copied:"
    echo "  /etc/samba/smb.conf -> /etc/samba/smb.conf.samba3"
    echo "  /var/lib/samba -> /var/lib/samba3"
    echo
  fi
fi

## ====================================================================
%post
if [ $1 -eq 1 ]; then   # Install
  # chkconfig
  /sbin/chkconfig --add smb
  /sbin/chkconfig --add nmb
fi

if [ $1 -ge 2 ]; then   # Upgrade
  /sbin/service smb condrestart >/dev/null 2>&1 || :
  /sbin/service nmb condrestart >/dev/null 2>&1 || :
fi
exit 0

## --------------------------------------------------------------------
%preun
if [ $1 = 0 ] ; then
  /sbin/service smb stop >/dev/null 2>&1 || :
  /sbin/service nmb stop >/dev/null 2>&1 || :
  /sbin/service samba stop >/dev/null 2>&1 || :
  /sbin/chkconfig --del smb
  /sbin/chkconfig --del nmb
  /sbin/chkconfig --del samba
  # rm -rf /var/log/samba/* /var/lib/samba/*
fi
exit 0

## --------------------------------------------------------------------
%pre winbind
/usr/sbin/groupadd -g 88 wbpriv >/dev/null 2>&1 || :

## --------------------------------------------------------------------
%post winbind
/sbin/chkconfig --add winbind

if [ "$1" -ge "1" ]; then
	/sbin/service winbind condrestart >/dev/null 2>&1 || :
fi

## --------------------------------------------------------------------
%post dc

if [ $1 -eq 1 ]; then   # Install
  # modify named.conf.dlz for DLZ configuration if version 9.9.0 or later
  if [ -f /usr/sbin/named ]; then
    bind_minor_ver=$(named -v | sed -e "s|^BIND \([.0-9]*\)|\1|" | cut -d "." -f 2)
    if [ $bind_minor_ver -gt 8 ]; then
      cat %{_datadir}/samba/setup/named.conf.dlz \
        | sed -e "s|\(database.*dlz_bind9.so\)|# \1|" > %{_datadir}/samba/setup/named.conf.dlz9
      cat %{_datadir}/samba/setup/named.conf.dlz9 > %{_datadir}/samba/setup/named.conf.dlz
      rm %{_datadir}/samba/setup/named.conf.dlz9
    fi
  fi

  /sbin/chkconfig --add samba

  # rename original smb.conf for provisioning
  mv -f %{_sysconfdir}/samba/smb.conf %{_sysconfdir}/samba/smb.conf.old
fi

setfacl -m u:named:rwx /var/lib/samba/private >/dev/null 2>/dev/null || :

if [ -d /var/lib/samba/private/tls ]; then
  chmod 0700 /var/lib/samba/private/tls
fi
if [ -f /var/lib/samba/private/tls/key.pem ]; then
  chmod 0600 /var/lib/samba/private/tls/key.pem
fi

if [ $1 -ge 2 ]; then   # Upgrade
  if [ -f /var/run/samba/samba.pid ]; then
    /sbin/service samba restart >/dev/null 2>&1 || :
  fi
fi

## --------------------------------------------------------------------
%post common
/sbin/ldconfig

setfacl -m u:named:rwx /var/lib/samba/private >/dev/null 2>/dev/null || :

## --------------------------------------------------------------------
%preun winbind
if [ $1 = 0 ] ; then
    /sbin/service winbind stop >/dev/null 2>&1 || :
    /sbin/chkconfig --del winbind
fi
exit 0

## --------------------------------------------------------------------
%postun common
/sbin/ldconfig

## --------------------------------------------------------------------
%post libs
/sbin/ldconfig

## --------------------------------------------------------------------
%postun libs
/sbin/ldconfig

## --------------------------------------------------------------------
%post -n libsmbclient
/sbin/ldconfig

## --------------------------------------------------------------------
%postun -n libsmbclient
/sbin/ldconfig

%if %build_compat32
## --------------------------------------------------------------------
%post -n compat32-libsmbclient
/sbin/ldconfig

## --------------------------------------------------------------------
%postun -n compat32-libsmbclient
/sbin/ldconfig

%endif

%files
%defattr(-,root,root,-)
%doc COPYING MAINTAINERS.txt PFIF.txt README README.Coding README.contributing README.packaging4 Roadmap VERSION WHATSNEW.txt
#%doc docs-ja/docs-xml/output/htmldocs
%{_bindir}/smbstatus
%{_bindir}/eventlogadm
%{_sbindir}/nmbd
%{_sbindir}/smbd
%{_libdir}/samba/auth
%{_libdir}/samba/vfs
%config(noreplace) %{_sysconfdir}/logrotate.d/samba
%config(noreplace) %{_sysconfdir}/pam.d/samba
%attr(0700,root,root) %dir /var/log/samba
%attr(0700,root,root) %dir /var/log/samba/old
%attr(1777,root,root) %dir /var/spool/samba
%{_initrddir}/nmb
%{_initrddir}/smb
%{_mandir}/man1/smbstatus.1.gz
%{_mandir}/man7/samba.7.gz
%{_mandir}/man8/eventlogadm.8.gz
%{_mandir}/man8/nmbd.8.gz
%{_mandir}/man8/smbd.8.gz
%{_mandir}/man8/vfs_acl_tdb.8.gz
%{_mandir}/man8/vfs_acl_xattr.8.gz
%{_mandir}/man8/vfs_aio_fork.8.gz
%{_mandir}/man8/vfs_aio_linux.8.gz
%{_mandir}/man8/vfs_aio_pthread.8.gz
%{_mandir}/man8/vfs_audit.8.gz
%{_mandir}/man8/vfs_btrfs.8.gz
%{_mandir}/man8/vfs_cacheprime.8.gz
%{_mandir}/man8/vfs_cap.8.gz
%{_mandir}/man8/vfs_catia.8.gz
%{_mandir}/man8/vfs_commit.8.gz
%{_mandir}/man8/vfs_crossrename.8.gz
%{_mandir}/man8/vfs_default_quota.8.gz
%{_mandir}/man8/vfs_dirsort.8.gz
%{_mandir}/man8/vfs_extd_audit.8.gz
%{_mandir}/man8/vfs_fake_perms.8.gz
%{_mandir}/man8/vfs_fileid.8.gz
%{_mandir}/man8/vfs_full_audit.8.gz
%{_mandir}/man8/vfs_gpfs.8.gz
%{_mandir}/man8/vfs_linux_xfs_sgid.8.gz
%{_mandir}/man8/vfs_media_harmony.8.gz
%{_mandir}/man8/vfs_netatalk.8.gz
%{_mandir}/man8/vfs_notify_fam.8.gz
%{_mandir}/man8/vfs_prealloc.8.gz
%{_mandir}/man8/vfs_preopen.8.gz
%{_mandir}/man8/vfs_readahead.8.gz
%{_mandir}/man8/vfs_readonly.8.gz
%{_mandir}/man8/vfs_recycle.8.gz
%{_mandir}/man8/vfs_scannedonly.8.gz
%{_mandir}/man8/vfs_shadow_copy.8.gz
%{_mandir}/man8/vfs_shadow_copy2.8.gz
%{_mandir}/man8/vfs_smb_traffic_analyzer.8.gz
%{_mandir}/man8/vfs_streams_depot.8.gz
%{_mandir}/man8/vfs_streams_xattr.8.gz
%{_mandir}/man8/vfs_syncops.8.gz
%{_mandir}/man8/vfs_time_audit.8.gz
%{_mandir}/man8/vfs_tsmsm.8.gz
%{_mandir}/man8/vfs_xattr_tdb.8.gz
# ja manuals
#%{_mandir}/ja/man1/smbstatus.1.gz
#%{_mandir}/ja/man7/samba.7.gz
#%{_mandir}/ja/man8/eventlogadm.8.gz
#%{_mandir}/ja/man8/nmbd.8.gz
#%{_mandir}/ja/man8/smbd.8.gz
#%{_mandir}/ja/man8/vfs_acl_tdb.8.gz
#%{_mandir}/ja/man8/vfs_acl_xattr.8.gz
#%{_mandir}/ja/man8/vfs_aio_fork.8.gz
#%{_mandir}/ja/man8/vfs_aio_linux.8.gz
#%{_mandir}/ja/man8/vfs_aio_pthread.8.gz
#%{_mandir}/ja/man8/vfs_audit.8.gz
#%{_mandir}/ja/man8/vfs_cacheprime.8.gz
#%{_mandir}/ja/man8/vfs_cap.8.gz
#%{_mandir}/ja/man8/vfs_catia.8.gz
#%{_mandir}/ja/man8/vfs_commit.8.gz
#%{_mandir}/ja/man8/vfs_crossrename.8.gz
#%{_mandir}/ja/man8/vfs_default_quota.8.gz
#%{_mandir}/ja/man8/vfs_dirsort.8.gz
#%{_mandir}/ja/man8/vfs_extd_audit.8.gz
#%{_mandir}/ja/man8/vfs_fake_perms.8.gz
#%{_mandir}/ja/man8/vfs_fileid.8.gz
#%{_mandir}/ja/man8/vfs_full_audit.8.gz
#%{_mandir}/ja/man8/vfs_gpfs.8.gz
#%{_mandir}/ja/man8/vfs_media_harmony.8.gz
#%{_mandir}/ja/man8/vfs_netatalk.8.gz
#%{_mandir}/ja/man8/vfs_notify_fam.8.gz
#%{_mandir}/ja/man8/vfs_prealloc.8.gz
#%{_mandir}/ja/man8/vfs_preopen.8.gz
#%{_mandir}/ja/man8/vfs_readahead.8.gz
#%{_mandir}/ja/man8/vfs_readonly.8.gz
#%{_mandir}/ja/man8/vfs_recycle.8.gz
#%{_mandir}/ja/man8/vfs_scannedonly.8.gz
#%{_mandir}/ja/man8/vfs_shadow_copy.8.gz
#%{_mandir}/ja/man8/vfs_shadow_copy2.8.gz
#%{_mandir}/ja/man8/vfs_smb_traffic_analyzer.8.gz
#%{_mandir}/ja/man8/vfs_streams_depot.8.gz
#%{_mandir}/ja/man8/vfs_streams_xattr.8.gz
#%{_mandir}/ja/man8/vfs_time_audit.8.gz
#%{_mandir}/ja/man8/vfs_tsmsm.8.gz
#%{_mandir}/ja/man8/vfs_xattr_tdb.8.gz

## --------------------------------------------------------------------
%files libs
%defattr(-,root,root)
%{_libdir}/libdcerpc-atsvc.so.*
%{_libdir}/libdcerpc-binding.so.*
%{_libdir}/libdcerpc-samr.so.*
%{_libdir}/libdcerpc.so.*
%{_libdir}/libgensec.so.*
%{_libdir}/libndr-krb5pac.so.*
%{_libdir}/libndr-nbt.so.*
%{_libdir}/libndr-standard.so.*
%{_libdir}/libndr.so.*
%{_libdir}/libregistry.so.*
%{_libdir}/libsamba-credentials.so.*
%{_libdir}/libsamba-hostconfig.so.*
%{_libdir}/libsamba-policy.so.*
%{_libdir}/libsamba-util.so.*
%{_libdir}/libsamdb.so.*
%{_libdir}/libsmbclient-raw.so.*
%{_libdir}/libsmbconf.so.*
%{_libdir}/libsmbldap.so.*
%{_libdir}/libtevent-util.so.*
%{_libdir}/libpdb.so.*

# libraries needed by the public libraries
%{_libdir}/samba/libCHARSET3.so
%{_libdir}/samba/libMESSAGING.so
%{_libdir}/samba/libLIBWBCLIENT_OLD.so
%{_libdir}/samba/libaddns.so
%{_libdir}/samba/libads.so
%{_libdir}/samba/libasn1util.so
%{_libdir}/samba/libauth4.so
%{_libdir}/samba/libauth_sam_reply.so
%{_libdir}/samba/libauth_unix_token.so
%{_libdir}/samba/libauthkrb5.so
%{_libdir}/samba/libccan.so
%{_libdir}/samba/libcli-ldap-common.so
%{_libdir}/samba/libcli-ldap.so
%{_libdir}/samba/libcli-nbt.so
%{_libdir}/samba/libcli_cldap.so
%{_libdir}/samba/libcli_smb_common.so
%{_libdir}/samba/libcli_spoolss.so
%{_libdir}/samba/libcliauth.so
#%{_libdir}/samba/libclidns.so
%{_libdir}/samba/libcluster.so
%{_libdir}/samba/libcmdline-credentials.so
#%{_libdir}/samba/libcom_err-samba4.so.0
#%{_libdir}/samba/libcom_err-samba4.so.0.25
%{_libdir}/samba/libdbwrap.so
%{_libdir}/samba/libdcerpc-samba.so
%{_libdir}/samba/libdcerpc-samba4.so
%{_libdir}/samba/libdfs_server_ad.so
%{_libdir}/samba/liberrors.so
%{_libdir}/samba/libevents.so
%{_libdir}/samba/libflag_mapping.so
%{_libdir}/samba/libgpo.so
%{_libdir}/samba/libgse.so
%{_libdir}/samba/libinterfaces.so
%{_libdir}/samba/libiniparser.so
%{_libdir}/samba/libkrb5samba.so
%{_libdir}/samba/libldbsamba.so
%{_libdir}/samba/liblibcli_lsa3.so
%{_libdir}/samba/liblibcli_netlogon3.so
%{_libdir}/samba/liblibsmb.so
%{_libdir}/samba/libsmb_transport.so
%{_libdir}/samba/libmsrpc3.so
%{_libdir}/samba/libndr-samba.so
%{_libdir}/samba/libndr-samba4.so
%{_libdir}/samba/libnet_keytab.so
%{_libdir}/samba/libnetif.so
%{_libdir}/samba/libnon_posix_acls.so
%{_libdir}/samba/libnpa_tstream.so
#%{_libdir}/samba/libpopt.so
%{_libdir}/samba/libposix_eadb.so
%{_libdir}/samba/libprocess_model.so
%{_libdir}/samba/libreplace.so
%{_libdir}/samba/libsamba-modules.so
%{_libdir}/samba/libsamba-net.so
%{_libdir}/samba/libsamba-security.so
%{_libdir}/samba/libsamba-sockets.so
%{_libdir}/samba/libsamba_python.so
%{_libdir}/samba/libsamdb-common.so
%{_libdir}/samba/libsecrets3.so
%{_libdir}/samba/libserver-role.so
%{_libdir}/samba/libservice.so
%{_libdir}/samba/libshares.so
%{_libdir}/samba/libsamba3-util.so
%{_libdir}/samba/libsmbd_base.so
%{_libdir}/samba/libsmbd_conn.so
%{_libdir}/samba/libsmbd_shim.so
%{_libdir}/samba/libsmbldaphelper.so
%{_libdir}/samba/libsmbpasswdparser.so
%{_libdir}/samba/libsmbregistry.so
%{_libdir}/samba/libsocket_wrapper.so
%{_libdir}/samba/libtdb-wrap.so
%{_libdir}/samba/libtdb_compat.so
%{_libdir}/samba/libtrusts_util.so
%{_libdir}/samba/libutil_cmdline.so
%if %{with_ntdb}
%{_libdir}/samba/libutil_ntdb.so
%endif
%{_libdir}/samba/libutil_reg.so
%{_libdir}/samba/libutil_setid.so
%{_libdir}/samba/libutil_tdb.so
%{_libdir}/samba/libuid_wrapper.so
%{_libdir}/samba/libxattr_tdb.so

%{_libdir}/samba/libdb-glue.so
%{_libdir}/samba/libHDB_SAMBA4.so
%{_libdir}/samba/libasn1-samba4.so.8
%{_libdir}/samba/libasn1-samba4.so.8.0.0
%{_libdir}/samba/libgssapi-samba4.so.2
%{_libdir}/samba/libgssapi-samba4.so.2.0.0
%{_libdir}/samba/libhcrypto-samba4.so.5
%{_libdir}/samba/libhcrypto-samba4.so.5.0.1
%{_libdir}/samba/libhdb-samba4.so.11
%{_libdir}/samba/libhdb-samba4.so.11.0.2
%{_libdir}/samba/libheimbase-samba4.so.1
%{_libdir}/samba/libheimbase-samba4.so.1.0.0
%{_libdir}/samba/libhx509-samba4.so.5
%{_libdir}/samba/libhx509-samba4.so.5.0.0
%{_libdir}/samba/libkrb5-samba4.so.26
%{_libdir}/samba/libkrb5-samba4.so.26.0.0
%{_libdir}/samba/libroken-samba4.so.19
%{_libdir}/samba/libroken-samba4.so.19.0.1
%{_libdir}/samba/libwind-samba4.so.0
%{_libdir}/samba/libwind-samba4.so.0.0.0

%if %{with_ntdb}
%{_libdir}/samba/libntdb.so.*
%endif

%if ! %with_libsmbclient
%{_libdir}/libsmbclient.so.*
%{_libdir}/libsmbsharemodes.so.*
%{_mandir}/man7/libsmbclient.7.gz
# ja manual
#%{_mandir}/ja/man7/libsmbclient.7.gz
%endif # ! with_libsmbclient

%if ! %with_libwbclient
%{_libdir}/libwbclient.so.*
%{_libdir}/samba/libwinbind-client.so
%endif # ! with_libwbclient

## --------------------------------------------------------------------
%files common
%defattr(-,root,root)
#%{_libdir}/samba/charset ???
#%{_sysconfdir}/tmpfiles.d/samba.conf
%{_bindir}/net
%{_bindir}/pdbedit
%{_bindir}/profiles
%{_bindir}/smbcontrol
%{_bindir}/testparm
%{_libdir}/libnetapi.so.*
%{_libdir}/samba/libprinting_migrate.so
%{_datadir}/samba/codepages
%dir /var/run/samba
%dir /var/run/winbindd
%dir /var/lib/samba
%dir /var/cache/samba
%attr(700,root,root) %dir /var/lib/samba/private
%attr(755,root,root) %dir %{_sysconfdir}/samba
%config(noreplace) %{_sysconfdir}/samba/smb.conf
%config(noreplace) %{_sysconfdir}/samba/lmhosts
%config(noreplace) %{_sysconfdir}/samba/smbusers
%config(noreplace) %{_sysconfdir}/sysconfig/samba
%{_mandir}/man1/profiles.1.gz
%{_mandir}/man1/smbcontrol.1.gz
%{_mandir}/man1/testparm.1.gz
%{_mandir}/man5/lmhosts.5.gz
%{_mandir}/man5/smb.conf.5.gz
%{_mandir}/man8/net.8.gz
%{_mandir}/man8/pdbedit.8.gz
# ja manuals
#%{_mandir}/ja/man1/profiles.1.gz
#%{_mandir}/ja/man1/smbcontrol.1.gz
#%{_mandir}/ja/man1/testparm.1.gz
#%{_mandir}/ja/man5/lmhosts.5.gz
#%{_mandir}/ja/man5/smb.conf.5.gz
#%{_mandir}/ja/man8/net.8.gz
#%{_mandir}/ja/man8/pdbedit.8.gz

# common libraries
%{_libdir}/samba/libauth.so
%{_libdir}/samba/libpopt_samba3.so
%{_libdir}/samba/pdb

%if %with_pam_smbpass
/%{_lib}/security/pam_smbpass.so
%endif

## --------------------------------------------------------------------
%files dc
%defattr(-,root,root)
#%{_bindir}/samba-dig
%{_bindir}/samba-tool
%{_sbindir}/samba_kcc
%{_sbindir}/samba
%{_sbindir}/samba_dnsupdate
%{_sbindir}/samba_spnupdate
%{_sbindir}/samba_upgradedns
%{_initrddir}/samba
%{_libdir}/libdcerpc-server.so.*
%{_libdir}/mit_samba.so
%{_libdir}/samba/bind9/dlz_bind9.so
%{_libdir}/samba/bind9/dlz_bind9_9.so
%{_libdir}/samba/ldb
%{_libdir}/samba/libdlz_bind9_for_torture.so
%{_libdir}/samba/libdsdb-module.so
%{_libdir}/samba/libheimntlm-samba4.so.1
%{_libdir}/samba/libheimntlm-samba4.so.1.0.1
%{_libdir}/samba/libkdc-samba4.so.2
%{_libdir}/samba/libkdc-samba4.so.2.0.0
%{_libdir}/samba/libntvfs.so
%{_libdir}/samba/libpac.so
%{_libdir}/samba/gensec
%{_libdir}/samba/process_model
%{_libdir}/samba/service
%dir /var/lib/samba/sysvol
%{_datadir}/samba/setup
%{_mandir}/man8/samba.8.gz
%{_mandir}/man8/samba-tool.8.gz
#%{_mandir}/man3/ldb.3.gz
# ja manuals
#%{_mandir}/ja/man8/samba.8.gz
#%{_mandir}/ja/man8/samba-tool.8.gz

## --------------------------------------------------------------------
%files winbind
%defattr(-,root,root)
#%{_bindir}/wbinfo3
%{_libdir}/samba/idmap
%{_libdir}/samba/nss_info
%{_libdir}/samba/libnss_info.so
%{_libdir}/samba/libnss_wrapper.so
%{_libdir}/samba/libidmap.so
%{_sbindir}/winbindd
%attr(750,root,wbpriv) %dir /var/lib/samba/winbindd_privileged
%config(noreplace) %{_sysconfdir}/security/pam_winbind.conf
%{_mandir}/man5/pam_winbind.conf.5.gz
%{_mandir}/man8/winbindd.8.gz
%{_mandir}/man8/idmap_*.8*
#%{_datadir}/locale/*/LC_MESSAGES/pam_winbind.mo
%{_initrddir}/winbind
# ja manuals
#%{_mandir}/ja/man5/pam_winbind.conf.5.gz
#%{_mandir}/ja/man8/winbindd.8.gz
#%{_mandir}/ja/man8/idmap_*.8*

## --------------------------------------------------------------------
%files winbind-krb5-locator
%defattr(-,root,root)
%{_libdir}/krb5/plugins/libkrb5/winbind_krb5_locator.so
%{_mandir}/man7/winbind_krb5_locator.7.gz
# ja manual
#%{_mandir}/ja/man7/winbind_krb5_locator.7.gz

## --------------------------------------------------------------------
%files winbind-clients
%defattr(-,root,root)
%{_bindir}/ntlm_auth
#%{_bindir}/ntlm_auth3
%{_bindir}/wbinfo
%{_libdir}/libnss_winbind.so*
%{_libdir}/libnss_wins.so*
#/%{smb_lib}/libnss_winbind.so.2
#/%{smb_lib}/libnss_wins.so.2
/%{_lib}/security/pam_winbind.so
%{_mandir}/man1/ntlm_auth.1.gz
%{_mandir}/man1/wbinfo.1.gz
%{_mandir}/man8/pam_winbind.8.gz
# ja manuals
#%{_mandir}/ja/man1/ntlm_auth.1.gz
#%{_mandir}/ja/man1/wbinfo.1.gz
#%{_mandir}/ja/man8/pam_winbind.8.gz

## --------------------------------------------------------------------
%files client
%defattr(-,root,root)
%{_bindir}/cifsdd
%{_bindir}/dbwrap_tool
#%{_bindir}/debug2html
#%{_bindir}/log2pcap
%{_bindir}/nmblookup
%{_bindir}/nmblookup4
%{_bindir}/oLschema2ldif
%{_bindir}/regdiff
%{_bindir}/regpatch
%{_bindir}/regshell
%{_bindir}/regtree
%{_bindir}/rpcclient
%{_bindir}/samba-regedit
%{_bindir}/sharesec
%{_bindir}/smbcacls
%{_bindir}/smbclient
%{_bindir}/smbclient4
%{_bindir}/smbcquotas
#%{_bindir}/smbfilter
%{_bindir}/smbget
#%{_bindir}/findsmg
#%{_bindir}/smbtar
#%{_bindir}/smbiconv
%{_bindir}/smbpasswd
%{_bindir}/smbspool
%{_bindir}/smbta-util
%{_bindir}/smbtar
%{_bindir}/smbtree
#%{_bindir}/split_tokens
%exclude %{_libdir}/samba/libldb-cmdline.so
%{_mandir}/man1/dbwrap_tool.1.gz
%{_mandir}/man1/findsmb.1.gz
%{_mandir}/man1/log2pcap.1.gz
%{_mandir}/man1/nmblookup.1.gz
%{_mandir}/man1/nmblookup4.1.gz
%{_mandir}/man1/oLschema2ldif.1.gz
%{_mandir}/man1/regdiff.1.gz
%{_mandir}/man1/regpatch.1.gz
%{_mandir}/man1/regshell.1.gz
%{_mandir}/man1/regtree.1.gz
%{_mandir}/man1/rpcclient.1.gz
%{_mandir}/man1/sharesec.1.gz
%{_mandir}/man1/smbcacls.1.gz
%{_mandir}/man1/smbclient.1.gz
%{_mandir}/man1/smbcquotas.1.gz
%{_mandir}/man1/smbget.1.gz
%{_mandir}/man1/smbtar.1.gz
%{_mandir}/man1/smbtree.1.gz
%{_mandir}/man5/smbgetrc.5.gz
%{_mandir}/man5/smbpasswd.5.gz
%{_mandir}/man8/samba-regedit.8.gz
%{_mandir}/man8/smbpasswd.8.gz
%{_mandir}/man8/smbspool.8.gz
%{_mandir}/man8/smbta-util.8.gz
#ja manuals
#%{_mandir}/ja/man1/dbwrap_tool.1.gz
#%{_mandir}/ja/man1/findsmb.1.gz
#%{_mandir}/ja/man1/log2pcap.1.gz
#%{_mandir}/ja/man1/nmblookup.1.gz
#%{_mandir}/ja/man1/rpcclient.1.gz
#%{_mandir}/ja/man1/sharesec.1.gz
#%{_mandir}/ja/man1/smbcacls.1.gz
#%{_mandir}/ja/man1/smbclient.1.gz
#%{_mandir}/ja/man1/smbcquotas.1.gz
#%{_mandir}/ja/man1/smbget.1.gz
#%{_mandir}/ja/man1/smbtar.1.gz
#%{_mandir}/ja/man1/smbtree.1.gz
#%{_mandir}/ja/man5/smbgetrc.5.gz
#%{_mandir}/ja/man5/smbpasswd.5.gz
#%{_mandir}/ja/man8/smbpasswd.8.gz
#%{_mandir}/ja/man8/smbspool.8.gz
#%{_mandir}/ja/man8/smbta-util.8.gz

%if %{with_ntdb}
%{_bindir}/ntdbbackup
%{_bindir}/ntdbdump
%{_bindir}/ntdbrestore
%{_bindir}/ntdbtool

%{_mandir}/man3/ntdb.3.gz
%{_mandir}/man8/ntdbbackup.8.gz
%{_mandir}/man8/ntdbdump.8.gz
%{_mandir}/man8/ntdbrestore.8.gz
%{_mandir}/man8/ntdbtool.8.gz
%%endif

## --------------------------------------------------------------------
%files test
%defattr(-,root,root)
#%{_bindir}/asystest
#%{_bindir}/dbwrap_torture
%{_bindir}/gentest
%{_bindir}/locktest
#%{_bindir}/locktest2
#%{_bindir}/locktest3
%{_bindir}/masktest
#%{_bindir}/masktest3
#%{_bindir}/msgtest
%{_bindir}/ndrdump
#%{_bindir}/nsstest
#%{_bindir}/pdbtest
#%{_bindir}/pthreadpooltest
#%{_bindir}/rpc_open_tcp
#%{_bindir}/smbconftort
%{_bindir}/smbtorture
#%{_bindir}/smbtorture3
#%{_bindir}/test_lp_load
#%{_bindir}/timelimit
#%{_bindir}/versiontest
#%{_bindir}/vfstest
#%{_bindir}/vlp
%{_libdir}/libtorture.so.*
%{_libdir}/samba/libsubunit.so
#%{_libdir}/samba/libdlz_bind9_for_torture.so
%{_mandir}/man1/gentest.1.gz
%{_mandir}/man1/locktest.1.gz
%{_mandir}/man1/masktest.1.gz
%{_mandir}/man1/ndrdump.1.gz
%{_mandir}/man1/smbtorture.1.gz
%{_mandir}/man1/vfstest.1.gz
# ja manual
#%{_mandir}/ja/man1/vfstest.1.gz

## --------------------------------------------------------------------
%files devel
%defattr(-,root,root)
%{_includedir}/samba-4.0/charset.h
%{_includedir}/samba-4.0/core/doserr.h
%{_includedir}/samba-4.0/core/error.h
%{_includedir}/samba-4.0/core/ntstatus.h
%{_includedir}/samba-4.0/core/werror.h
%{_includedir}/samba-4.0/credentials.h
%{_includedir}/samba-4.0/dcerpc.h
%{_includedir}/samba-4.0/dlinklist.h
%{_includedir}/samba-4.0/domain_credentials.h
%{_includedir}/samba-4.0/gen_ndr/atsvc.h
%{_includedir}/samba-4.0/gen_ndr/auth.h
%{_includedir}/samba-4.0/gen_ndr/dcerpc.h
%{_includedir}/samba-4.0/gen_ndr/epmapper.h
%{_includedir}/samba-4.0/gen_ndr/krb5pac.h
%{_includedir}/samba-4.0/gen_ndr/lsa.h
%{_includedir}/samba-4.0/gen_ndr/mgmt.h
%{_includedir}/samba-4.0/gen_ndr/misc.h
%{_includedir}/samba-4.0/gen_ndr/nbt.h
%{_includedir}/samba-4.0/gen_ndr/drsblobs.h
%{_includedir}/samba-4.0/gen_ndr/drsuapi.h
%{_includedir}/samba-4.0/gen_ndr/ndr_drsblobs.h
%{_includedir}/samba-4.0/gen_ndr/ndr_drsuapi.h
%{_includedir}/samba-4.0/gen_ndr/ndr_atsvc.h
%{_includedir}/samba-4.0/gen_ndr/ndr_atsvc_c.h
%{_includedir}/samba-4.0/gen_ndr/ndr_dcerpc.h
%{_includedir}/samba-4.0/gen_ndr/ndr_epmapper.h
%{_includedir}/samba-4.0/gen_ndr/ndr_epmapper_c.h
%{_includedir}/samba-4.0/gen_ndr/ndr_krb5pac.h
%{_includedir}/samba-4.0/gen_ndr/ndr_mgmt.h
%{_includedir}/samba-4.0/gen_ndr/ndr_mgmt_c.h
%{_includedir}/samba-4.0/gen_ndr/ndr_misc.h
%{_includedir}/samba-4.0/gen_ndr/ndr_nbt.h
%{_includedir}/samba-4.0/gen_ndr/ndr_samr.h
%{_includedir}/samba-4.0/gen_ndr/ndr_samr_c.h
%{_includedir}/samba-4.0/gen_ndr/ndr_svcctl.h
%{_includedir}/samba-4.0/gen_ndr/ndr_svcctl_c.h
%{_includedir}/samba-4.0/gen_ndr/netlogon.h
%{_includedir}/samba-4.0/gen_ndr/samr.h
%{_includedir}/samba-4.0/gen_ndr/security.h
%{_includedir}/samba-4.0/gen_ndr/server_id.h
%{_includedir}/samba-4.0/gen_ndr/svcctl.h
%{_includedir}/samba-4.0/gensec.h
%{_includedir}/samba-4.0/ldap-util.h
%{_includedir}/samba-4.0/ldap_errors.h
%{_includedir}/samba-4.0/ldap_message.h
%{_includedir}/samba-4.0/ldap_ndr.h
%{_includedir}/samba-4.0/ldb_wrap.h
%{_includedir}/samba-4.0/lookup_sid.h
%{_includedir}/samba-4.0/machine_sid.h
%{_includedir}/samba-4.0/ndr.h
%{_includedir}/samba-4.0/ndr/ndr_drsblobs.h
%{_includedir}/samba-4.0/ndr/ndr_drsuapi.h
%{_includedir}/samba-4.0/ndr/ndr_svcctl.h
%{_includedir}/samba-4.0/ndr/ndr_nbt.h
%{_includedir}/samba-4.0/netapi.h
%{_includedir}/samba-4.0/param.h
%{_includedir}/samba-4.0/passdb.h
%{_includedir}/samba-4.0/policy.h
%{_includedir}/samba-4.0/read_smb.h
%{_includedir}/samba-4.0/registry.h
%{_includedir}/samba-4.0/roles.h
%{_includedir}/samba-4.0/rpc_common.h
%{_includedir}/samba-4.0/samba/session.h
%{_includedir}/samba-4.0/samba/version.h
%{_includedir}/samba-4.0/share.h
%{_includedir}/samba-4.0/smb2.h
%{_includedir}/samba-4.0/smb2_constants.h
%{_includedir}/samba-4.0/smb2_create_blob.h
%{_includedir}/samba-4.0/smb2_lease.h
%{_includedir}/samba-4.0/smb2_signing.h
%{_includedir}/samba-4.0/smb_cli.h
%{_includedir}/samba-4.0/smb_cliraw.h
%{_includedir}/samba-4.0/smb_common.h
%{_includedir}/samba-4.0/smb_composite.h
%{_includedir}/samba-4.0/smbconf.h
%{_includedir}/samba-4.0/smb_constants.h
%{_includedir}/samba-4.0/smb_ldap.h
%{_includedir}/samba-4.0/smbldap.h
%{_includedir}/samba-4.0/smb_raw.h
%{_includedir}/samba-4.0/smb_raw_interfaces.h
%{_includedir}/samba-4.0/smb_raw_signing.h
%{_includedir}/samba-4.0/smb_raw_trans2.h
%{_includedir}/samba-4.0/smb_request.h
%{_includedir}/samba-4.0/smb_seal.h
%{_includedir}/samba-4.0/smb_signing.h
%{_includedir}/samba-4.0/smb_unix_ext.h
%{_includedir}/samba-4.0/smb_util.h
%{_includedir}/samba-4.0/tdr.h
%{_includedir}/samba-4.0/torture.h
%{_includedir}/samba-4.0/tsocket.h
%{_includedir}/samba-4.0/tsocket_internal.h
%{_includedir}/samba-4.0/samba_util.h
%{_includedir}/samba-4.0/util/attr.h
%{_includedir}/samba-4.0/util/byteorder.h
%{_includedir}/samba-4.0/util/data_blob.h
%{_includedir}/samba-4.0/util/debug.h
%{_includedir}/samba-4.0/util/memory.h
%{_includedir}/samba-4.0/util/safe_string.h
%{_includedir}/samba-4.0/util/string_wrappers.h
%{_includedir}/samba-4.0/util/talloc_stack.h
%{_includedir}/samba-4.0/util/tevent_ntstatus.h
%{_includedir}/samba-4.0/util/tevent_unix.h
%{_includedir}/samba-4.0/util/tevent_werror.h
%{_includedir}/samba-4.0/util/time.h
%{_includedir}/samba-4.0/util/xfile.h
%{_includedir}/samba-4.0/util_ldb.h
%{_libdir}/libdcerpc-atsvc.so
%{_libdir}/libdcerpc-binding.so
%{_libdir}/libdcerpc-samr.so
%{_libdir}/libdcerpc.so
%{_libdir}/libgensec.so
%{_libdir}/libndr-krb5pac.so
%{_libdir}/libndr-nbt.so
%{_libdir}/libndr-standard.so
%{_libdir}/libndr.so
%{_libdir}/libnetapi.so
%{_libdir}/libregistry.so
%{_libdir}/libsamba-credentials.so
%{_libdir}/libsamba-hostconfig.so
%{_libdir}/libsamba-policy.so
%{_libdir}/libsamba-util.so
%{_libdir}/libsamdb.so
%{_libdir}/libsmbclient-raw.so
%{_libdir}/libsmbconf.so
%{_libdir}/libsmbldap.so
%{_libdir}/libtevent-util.so
%{_libdir}/libtorture.so
%{_libdir}/libpdb.so
#%{_libdir}/samba/libdlz_bind9_for_torture.so
#%{_libdir}/pkgconfig/dcerpc.pc
#%{_libdir}/pkgconfig/dcerpc_atsvc.pc
#%{_libdir}/pkgconfig/dcerpc_samr.pc
#%{_libdir}/pkgconfig/gensec.pc
#%{_libdir}/pkgconfig/ndr.pc
#%{_libdir}/pkgconfig/ndr_krb5pac.pc
#%{_libdir}/pkgconfig/ndr_nbt.pc
#%{_libdir}/pkgconfig/ndr_standard.pc
#%{_libdir}/pkgconfig/netapi.pc
#%{_libdir}/pkgconfig/registry.pc
#%{_libdir}/pkgconfig/samba-credentials.pc
#%{_libdir}/pkgconfig/samba-hostconfig.pc
#%{_libdir}/pkgconfig/samba-policy.pc
#%{_libdir}/pkgconfig/samba-util.pc
#%{_libdir}/pkgconfig/samdb.pc
#%{_libdir}/pkgconfig/smbclient-raw.pc
#%{_libdir}/pkgconfig/talloc.pc
#%{_libdir}/pkgconfig/tevent.pc
#%{_libdir}/pkgconfig/torture.pc

%{_includedir}/samba-4.0/dcerpc_server.h
%{_libdir}/libdcerpc-server.so
#%{_libdir}/pkgconfig/dcerpc_server.pc

%if %with_talloc
%{_includedir}/samba-4.0/pytalloc.h
%endif

%if ! %with_libsmbclient
%{_includedir}/samba-4.0/libsmbclient.h
%{_includedir}/samba-4.0/smb_share_modes.h
%endif # ! with_libsmbclient

%if ! %with_libwbclient
%{_libdir}/libwbclient.so
%{_includedir}/samba-4.0/wbclient.h
%endif # ! with_libwbclient

## --------------------------------------------------------------------
%files python
%defattr(-,root,root,-)
%{python_sitearch}/*
%exclude %{python_sitearch}/ldb.so
%exclude %{python_sitearch}/_tevent.so

## --------------------------------------------------------------------
%files pidl
%defattr(-,root,root,-)
%{_datadir}/samba/perl5
%{_mandir}/man1/pidl.1.gz
%{_mandir}/man3/Parse::Pidl::Wireshark::NDR.3pm.gz
%{_mandir}/man3/Parse::Pidl::Wireshark::Conformance.3pm.gz
%{_mandir}/man3/Parse::Pidl::Dump.3pm.gz
%{_mandir}/man3/Parse::Pidl::NDR.3pm.gz
%{_mandir}/man3/Parse::Pidl::Util.3pm.gz
%attr(755,root,root) %{_bindir}/pidl

## --------------------------------------------------------------------
%if %with_libsmbclient
%files -n libsmbclient
%defattr(-,root,root)
%{_libdir}/libsmbclient.so.*
%{_libdir}/libsmbsharemodes.so.*
%{_mandir}/man7/libsmbclient.7.gz
# ja manual
#%{_mandir}/ja/man7/libsmbclient.7.gz

## --------------------------------------------------------------------
%files -n libsmbclient-devel
%defattr(-,root,root)
%{_includedir}/samba-4.0/libsmbclient.h
%{_includedir}/samba-4.0/smb_share_modes.h
%{_libdir}/libsmbclient.so
%{_libdir}/libsmbsharemodes.so
%{_libdir}/pkgconfig/smbclient.pc
%{_libdir}/pkgconfig/smbsharemodes.pc
#%{_mandir}/man7/libsmbclient.7*
%endif # with_libsmbclient

## --------------------------------------------------------------------
%if %with_libwbclient
%files -n libwbclient
%defattr(-,root,root)
%{_libdir}/libwbclient.so.*
%{_libdir}/samba/libwinbind-client.so

## --------------------------------------------------------------------
%files -n libwbclient-devel
%defattr(-,root,root)
%{_includedir}/samba-4.0/wbclient.h
%{_libdir}/libwbclient.so
%{_libdir}/pkgconfig/wbclient.pc
%endif # with_libwbclient

%if %build_compat32

## --------------------------------------------------------------------
%files -n compat32-libwbclient
%defattr(755,root,root)
%{_libdir}/libwbclient.so.*
%{_libdir}/samba/libwinbind-client.so

## --------------------------------------------------------------------
%files -n compat32-libsmbclient
%attr(755,root,root) %{_libdir}/libsmbclient.so.*
%attr(755,root,root) %{_libdir}/libsmbsharemodes.so.*

%endif

%changelog
* Wed Mar 12 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.1.6-1
- new upstream release.
- removed samba-ja-docs (docs-ja for 4.1.x has not released yet).

* Mon Dec 09 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.1.3-1
- new upstream release.

* Thu Nov 28 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.1.2-1
- new upstream release.
- removed a sub package "samba-swat" (removed in upstream).
- %%post was made to fix the permission of TLS key (CVE-2013-4476).

* Wed Oct 09 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.10-1
- new upstream release.

* Tue Oct 08 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.9-1
- new upstream release.

* Tue Mar 26 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.4-1
- new upstream release.
- fixed dependency.
- added documents from samba-docs-ja-4.0.0-1.

* Mon Mar 04 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.3-2
- fixed directory to place private data.

* Sun Mar 03 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.3-1
- new upstream release.
- fixed dates of %%changelog.

* Mon Dec 17 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.0-1
- new upstream release.

* Wed May 02 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.15-1
- new upstream release. (to fix CVE-2012-2111)
- added charset options to smb.conf.

* Sat Apr 14 2012 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.14-1
- new upstream release. (to fix CVE-2012-1182)

* Tue Aug 09 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.11-1
- new upstream release. (to fix BTS:1189)

* Sat Jul 30 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.10-1
- new upstream release. (to fix CVE-2011-2522 and CVE-2011-2694)

* Mon Jul 18 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.8-3
- updated Source6.

* Fri Mar 25 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.8-2
- fix smb.conf(5).

* Thu Mar 24 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.5.8-1
- new upstream release.
- updated patches.
- added subpackages 'winbind-krb5-locator' and 'winbind-client'.
- dropped tdb and talloc subpackages became independent packages.
- dropped {,u}mount.cifs were included in cifs-utils.

* Sat Oct 02 2010 Shu KONNO <owa@bg.wakwak.com> 3.3.10-13
- rebuilt with rpm-4.8.1 for pkg-config
- changed spec file name as vine style
- dropt script lines in %%build that no work

* Sun Feb  7 2010 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 3.3.10-12
- add patch1000 for fix CVE-2010-0547 (cifs.mount)

* Sat Jan 30 2010 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.10-11
- new upstream release.

* Fri Nov 20 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.9-10
- added 'Packager' tag.

* Sun Oct 25 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.9-9
- new upstream release.
- added '--disable-fam' option.
- added 'compat32-*' subpackages.
- added 'libuuid-devel' to 'BuildRequires:'.

* Thu Jul 30 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.7-7
- new upstream release.

* Thu Jun 25 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.6-6
- new upstream release.

* Thu Jun  4 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.4-5
- increased release number for libtalloc/libtdb.

* Tue Jun  2 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.4-2
- fixed dependency.
- fixed modulepath.

* Fri May 29 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.4-1
- new upstream release.

* Sun Mar 01 2009 NAKAMURA Kenta <kenta@vinelinux.org> 3.2.5-4
- rebuilt with openldap-2.4.11

* Sat Jan 17 2009 Ryoiochi INAGAKI <ryo1@bc.wakwak.com> 3.2.5-3
- samba-doc: changed Group to Applications/Documentation
- samba-winbind-devel: changed Group to Development/Libraries
- libsmbclient: changed Group to System Environment/Libraries
- libsmbclient-devel: changed Group to Development/Libraries
- libtalloc: changed Group to System Environment/Libraries
- libtalloc-devel: changed Group to Development/Libraries
- libtdb: fixed summary
          changed Group to System Environment/Libraries
- libtdb-devel: changed Group to Development/Libraries

* Thu Dec 04 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 3.2.5-2
- new upstream release

* Sat Nov 01 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 3.2.3-1
- new upstream release
- drop jp patch
- use UTF-8 as default charset
- rename samba-libsmbclient to libsmbclient

* Fri Apr 11 2008 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 3.0.28a-1
- new upstream release.
- remove gamin-devel from BuildRequires: (no longer needed).

* Sat Sep 15 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 3.0.24-0vl4
- BuildRequires: gamin-devel (see [wishes:0127])

* Wed May 16 2007 KAZUKI SHIMURA <ksh753@gmail.com> 3.0.24-0vl3
- [SECURITY FIX] add security patches (#50-52)
  - CVE-2007-2444: local SID/Name translation bug (user privilege elevation)
  - CVE-2007-2446: multiple heap overflows allow remote code execution
  - CVE-2007-2447: remote command injection vulnerability

* Fri Mar 09 2007 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.24-0vl2
- apply upstream patches (#0-5)
  - fix an issues with servers set to "security = share" and Vista clients
    that send NTLMv2 responses
  - fixe several point-n-print bugs with Vista clients
  - fix failure when using the Vista backup utility
  - fix expansion of the %a smb.conf variable for Vista clients
  - fix MS-DFS referrals with Windows Vista clients
  - fix for Vista failing to delete directories on a Samba share
- display service start/stop messages ([VineSeed:13299])

* Wed Feb 14 2007 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.24-0vl1
- [SECURITY FIX] new upstream release
  - CVE-2007-0452: potential denial of service bug in smbd
  - CVE-2007-0453: buffer overrun in NSS host lookup winbind library on Solaris
  - CVE-2007-0454: format string bug in afsacl.so vfs plugin

* Thu Dec 14 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23d-0vl1
- new upstream release

* Sat Nov 25 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23c-0vl3
- disable swat (via inetd) by default
- fix code for editing %%{_sysconfdir}/inetd.conf

* Sun Sep 17 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23c-0vl2
- fix dependencies:
  - move PreReq: mktemp, psmisc, fileutils, sed, gawk, grep to -swat
  - drop PreReq: gawk from -client
  - drop PreReq: inetd from -swat
  - drop Requires: tcp_wrappers from -swat (is needed by inetd)
- fix %%post etc...
  - drop code for editing /etc/services: no more needed
  - move code for editing %%{_sysconfdir}/{hosts.*,inetd.conf}
    from %%triggerin swat -- inetd to %%post swat
  - check if %%{_sysconfdir}/inetd.conf exist before updating at %%postun

* Fri Sep 08 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23c-0vl1
- new upstream release

* Sun Aug 27 2006 NAKAMURA Kenta <kenta@vinelinux.org> 3.0.23b-0vl2
- rebuilt with openldap-2.3.27-0vl1

* Mon Aug 14 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23b-0vl1
- new upstream release

* Fri Jul 28 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23a-0vl1
- new upstream release

* Sat Jul 22 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.23-0vl1
- [SECURITY] new upstream release
  - Memory exhaustion DoS against smbd (CVE-2006-3403)
- update patches
  - buildroot.patch (#100)
  - logfiles.patch (#103)
  - smb.conf.patch (#106)
- update filter-requires-samba.sh (source999)
  - get rid of bogus dependency on perl(Unicode::MapUTF8)

* Fri Jun 23 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.22-0vl1
- new upstream release
- renumber patches
  - 000- for upstream patches
  - 050- for security patches
  - 100- for generic patches
- update logfiles.patch (#103)
- drop warning.patch (#104)
- not apply hex.patch (#105)
- add smb.conf.patch (#106)
- drop samba.log (source1), smb.conf (source2)
- use samba.pamd.stack instead of samba.pamd
- define macro: pkgingdir
- add files:
  - samba-client
    - %%{_bindir}/{smbget,eventlogadm}
  - samba-common:
    - %%{_bindir}/tdbtool
- separate development files to samba-libsmbclient-devel
- change groups

* Sat Apr 15 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.14a-0vl5
- remove unneeded dependencies
  - update filter-requires-samba.sh (source999)
  - overwrite __find_requires instead of __perl_requires

* Tue Mar 28 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.14a-0vl4
- rebuild with readline-5.1

* Sat Aug 13 2005 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.14a-0vl3
- separate doc package with %%docpkg
- use %%htmlview instead of %%browser

* Sat Jul 16 2005 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.14a-0vl2
- add %%config(noreplace) against %%{_sysconfdir}/xinetd.d/swat

* Fri Jul 15 2005 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.14a-0vl1
- new upstream release
- install %%{_sysconfdir}/xinetd.d/swat
- update filter-requires-samba.sh
- add swat.desktop.in instead of swat.desktop
  - switch browser by %%browser
- drop i18n patches
- update logfiles.patch (#3)
- add warning.patch (#4)

* Sun Jul 10 2005 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.10-0vl2
- fix samba.log
  - thanks, K. Moriyama [VinePlus:02606]
- remove docs/manpages from %%doc

* Mon Dec 27 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.10-0vl1
- new upstream release
- update struplower_m_i18n.patch (#102)
- drop obsolete patch (#10)

* Fri Dec 17 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.9-0vl2
- [SECURITY FIX] fix possible remote code execution (CAN-2004-1154)
  - add samba-3.0.9-CAN-2004-1154.patch (#10)
- update patch (#102)

* Fri Nov 26 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.9-0vl1
- new upstream release
- drop obsolete patches (#10,11,110)
- update patches (#3,102)

* Sun Nov 21 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.7-0vl6
- [SECURITY FIX] fix smbd buffer overrun (CAN-2004-0882)
  - add samba-3.0.7-CAN-2004-0882.patch (patch11)
- update Source URL

* Tue Nov 09 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.7-0vl5
- [SECURITY FIX] fix smbd remote DoS vulnerability (CAN-2004-0930)
  - add samba-3.0.7-CAN-2004-0930.patch (patch10)

* Fri Oct 15 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.7-0vl4
- update samba.log, {smb,winbind}.init
- use *.log as logfile name instead of log.* (patch3)

* Wed Oct 06 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.7-0vl3
- change directories from %%{_localstatedir}/lock/samba
  - LOCKDIR: %%{_localstatedir}/cache/samba
  - PIDDIR:  %%{_localstatedir}/run
- restart {smb,winbind} at postun (upgrade)
- samba-common
  - convert smbpasswd at triggerpostun -- samba < 3.0.7
  - add convert_smbpasswd
  - add PreReq: gawk

* Sat Sep 25 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.7-0vl2
- add docs_ja (source101) from 3.0.5-16ml

* Wed Sep 22 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 3.0.7-0vl1
- new upstream release (shift to 3.0 series)
  - refer to 3.0.6-3 (Fedora Core), 3.0.5-16ml (MIRACLE)
  - drop obsolete paches, configure options
  - update buildroot.patch
  - add I18N patches (#101-)
  - update smb.conf
- add URL
- use more macros
- change LIBDIR from %%{_sysconfdir}/samba to %%{_libdir}/samba
- move %%{_localstatedir}/log/samba, smbpasswd to samba-common
- move smbspool, smbcacls, rpcclient to samba-client
- update descriptions

* Wed Sep 08 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 2.2.11.ja.1.0-0vl1
- new upstream release

* Wed Sep 01 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 2.2.11.ja.1.0-0vl0.beta1
- 2.2.11-ja-1.0beta1
  - drop patch10
- add BuildPreReq: openssl-devel
- swat
  - add PreReq/Requires: inetd
  - add swat.desktop

* Sun Jul 25 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 2.2.9.ja.1.0-0vl3
- fix changelog

* Sat Jul 24 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 2.2.9.ja.1.0-0vl2
- [SECURITY FIX] fix buffer overflow (CAN-2004-0686)
  - add samba-2.2.9-ja-1.0-mangle.patch (Patch10)
- add BuildPreReq: cups-devel
- add Prereq: chkconfig mktemp psmisc (instead of each files)

* Thu Jun 03 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 2.2.9.ja.1.0-0vl1
- new upstream release

* Thu May 27 2004 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 2.2.9.ja.1.0-0vl0.beta1
- 2.2.9-ja-1.0beta1
- add BuildPreReq: readline-devel

* Sat Jan 24 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 2.2.8a.ja.1.1-0vl3
- add ldconfig in %%post/%%postun script for libsmbclient

* Sat Jan 24 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 2.2.8a.ja.1.1-0vl2
- add libsmbclient subpackage.

* Thu Sep 11 2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 2.2.8a.ja.1.1-0vl1
- new upstream release.

* Sat Aug 09 2003 KAZUKI SHIMURA <rito@pos.to> 2.2.8a.ja-1.0vl3
- fix smb.conf (SAMBADOC's path)

* Tue May 27 2003 Tomoya TAKA <taka@vinelinux.org> 2.2.8a.ja-1.0vl2
- tentatively skip to build examples/VFS on alpha

* Tue May 27 2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 2.2.8a.ja-1.0vl1
- new upstream release.

* Mon May 19 2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 2.2.7b.ja-1.0vl2
- fix smb.conf
- fix smbadduser

* Thu Apr 17 2003 KAZUKI SHIMURA <rito@pos.to> 2.2.7b.ja-1.0vl1
- new upstream version

* Sun Mar 23 2003 Satoshi MACHINO <machino@vinelinux.org> 2.2.7a.ja-1.1vl2
- added smbinit-vine.patch
	-- added '-D' option in smbd and nmbd

* Thu Mar 20 2003 Satoshi MACHINO <machino@vinelinux.org> 2.2.7a.ja-1.1vl1
- New upstream version
	-- security fix.

* Wed Feb 26 2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.7a.ja-1.0vl5
- merged from SPEC for RH60 by samba-jp.

* Mon Feb 17  2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.7a.ja-1.0vl4.beta1
- fix 'Requires:'.

* Tue Jan 28 2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.7a.ja-1.0vl3.alpha1
- disable --with-tdbsam.

* Sat Dec 28 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.7a.ja-1.0vl2.alpha1
- modify %%post script for new password database.

* Fri Dec 27 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.7a.ja-1.0vl1.alpha1

* Tue Nov 19 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.6.ja-1.0vl1.alpha2
- apply alpha2 patch.

* Fri Nov 15 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.6.ja-1.0vl1.alpha1
- remove swat from package 'samba'.

* Thu Nov 14 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.6.ja-1.0vl0.alpha1
- enable winbind modules.
- change numbering rule.

* Thu Oct 24 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.6_ja_0.alpha1-0vl1

* Tue Jun 11 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.4_ja_0.alpha1.3-0vl1

* Sun Mar 17 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.2_ja_1.1-0vl1
- disable winbind modules (2.2.2 or earlier has critical bugs).
- modify 'Requires:'.

* Fri Mar 15 2002 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
- 2.2.2_ja_1.1-0vl0
- shift sources to 2.2.x.
- add debugging mode for '%%files' section.
- modify spec largely because of too many difference between 2.0.x and 2.2.x.
-  . exchange %%prep, %%build, %%install section with samba-jp's spec.
-  . create a package 'samba-swat'.
-  . move smbclient and nmblookup to samba-common.
-  . move testprns to package 'samba' because it's checking tool for 
-    server on LOCALHOST.
-  . move '%%post' to '%%post swat'.
-  . disable '%%post common'.

* Sun Dec 02 2001 Toru Sagami <sagami@vinelinux.org>
- 2.0.10_ja_1.2

* Mon Sep 03 2001 Toru Sagami <sagami@vinelinux.org>
- 2.0.10_ja_1.1-0vl4
- eliminate executable bit in %%doc to erase perl/sh requirement

* Thu Aug 23 2001 Toru Sagami <sagami@vinelinux.org>
- 2.0.10_ja_1.1-0vl3: s/$RPM_BUILD_ROOT/%%{buildroot}/
- patch swat/ja/help/welcome.html to hide some missing matter
- also remove docs/zh_{CN,TW} files in %%doc

* Wed Aug 22 2001 Satoshi MACHINO <machino@vinelinux.org> 2.0.10_ja_1.1-0vl2
- for VineSeed
- deleted %%define _syssbindir and _localedir (defined in rpmmacros in rpm-3.0.6-0vl14)

* Wed Aug 22 2001 Satoshi MACHINO <machino@vinelinux.org> 2.0.10_ja_1.1-0vl1
- 2.0.10_ja_1.1
- for 2.1.x update

* Fri Aug 17 2001 <sagami@vinelinux.org>
- 2.0.10_ja_1.0-0vl2
- remove almost duplicated docs/{,ja/}{manpages,yodldocs} files in %%doc

* Mon Jul 09 2001 <sagami@vinelinux.org>
- 2.0.10_ja_1.0-0vl1: includes secrity fix
 (http://www.samba.org/samba/whatsnew/macroexploit.html)
- remove using_samba, HowToUseSamba and docs/ja_JP.SJIS directory from %%doc

* Thu May 31 2001 <sagami@vinelinux.org>
- 2.0.9_ja_1.0-0vl1: added swat/ja/help/HowToUseSamba
- added BuildPreReq = pam-devel for Vine 2.1.5+
- fixed init script to match our current/old style
- eliminate CVS related files from %%doc

* Thu Apr 19 2001 <sagami@vinelinux.org>
- 2.0.7_ja_2.2-0vl1

* Thu Dec 21 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
- 2.0.7_ja_1.3-0vl2
- rebuilt with readline2
- use better macros (although not almost complete... needs comfirmation)

* Tue Sep 19 2000 Jun Nishii <jun@vinelinux.org>
- 2.0.7_ja_1.3-0vl1

* Tue Sep 12 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
- 2.0.7_ja_1.2.1-0vl2
- fixed missing Changelog.ja (was Chagelog.ja)

* Tue Sep 12 2000 Jun Nishii <jun@vinelinux.org>
- updated to 2.0.7-ja-1.2.1

* Wed Jul 19 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- updated to 2.0.7-ja-1.2

* Tue Jul 11 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- added some Japanese documents to %doc

* Mon Jul 10 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- updated to 2.0.7-ja-1.0

* Mon May 29 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- updated to 2.0.7-ja-0.99

* Mon May 29 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- added rpccilent
- modified tcpdconf for stability.

* Fri May 26 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- first test release for Vine based on RH6.2 spec file.
- activated swat in default for only localhost.

* Fri Feb 25 2000 Bill Nottingham <notting@redhat.com>
- fix trigger, again.

* Mon Feb  7 2000 Bill Nottingham <notting@redhat.com>
- fix trigger.

* Fri Feb  4 2000 Bill Nottingham <notting@redhat.com>
- turn on quota support

* Mon Jan 31 2000 Cristian Gafton <gafton@redhat.com>
- rebuild to fox dependencies
- man pages are compressed

* Fri Jan 21 2000 Bill Nottingham <notting@redhat.com>
- munge post scripts slightly

* Wed Jan 19 2000 Bill Nottingham <notting@redhat.com>
- turn on mmap again. Wheee.
- ship smbmount on alpha

* Mon Dec  6 1999 Bill Nottingham <notting@redhat.com>
- turn off mmap. ;)

* Wed Dec  1 1999 Bill Nottingham <notting@redhat.com>
- change /var/log/samba to 0700
- turn on mmap support

* Thu Nov 11 1999 Bill Nottingham <notting@redhat.com>
- update to 2.0.6

* Fri Oct 29 1999 Bill Nottingham <notting@redhat.com>
- add a %defattr for -common

* Tue Oct  5 1999 Bill Nottingham <notting@redhat.com>
- shift some files into -client
- remove /home/samba from package.

* Tue Sep 28 1999 Bill Nottingham <notting@redhat.com>
- initscript oopsie. killproc <name> -HUP, not other way around.

* Sun Sep 26 1999 Bill Nottingham <notting@redhat.com>
- script cleanups. Again.

* Wed Sep 22 1999 Bill Nottingham <notting@redhat.com>
- add a patch to fix dropped reconnection attempts

* Mon Sep  6 1999 Jeff Johnson <jbj@redhat.com>
- use cp rather than mv to preserve /etc/services perms (#4938 et al).
- use mktemp to generate /etc/tmp.XXXXXX file name.
- add prereqs on sed/mktemp/killall (need to move killall to /bin).
- fix trigger syntax (i.e. "samba < 1.9.18p7" not "samba < samba-1.9.18p7")

* Mon Aug 30 1999 Bill Nottingham <notting@redhat.com>
- sed "s|nawk|gawk|" /usr/bin/convert_smbpasswd

* Sat Aug 21 1999 Bill Nottingham <notting@redhat.com>
- fix typo in mount.smb

* Fri Aug 20 1999 Bill Nottingham <notting@redhat.com>
- add a %trigger to work around (sort of) broken scripts in
  previous releases

* Mon Aug 16 1999 Bill Nottingham <notting@redhat.com>
- initscript munging

* Mon Aug  9 1999 Bill Nottingham <notting@redhat.com>
- add domain parsing to mount.smb

* Fri Aug  6 1999 Bill Nottingham <notting@redhat.com>
- add a -common package, shuffle files around.

* Fri Jul 23 1999 Bill Nottingham <notting@redhat.com>
- add a chmod in %postun so /etc/services & inetd.conf don't become unreadable

* Wed Jul 21 1999 Bill Nottingham <notting@redhat.com>
- update to 2.0.5
- fix mount.smb - smbmount options changed again.........
- fix postun. oops.
- update some stuff from the samba team's spec file.

* Fri Jun 18 1999 Bill Nottingham <notting@redhat.com>
- split off clients into separate package
- don't run samba by default

* Mon Jun 14 1999 Bill Nottingham <notting@redhat.com>
- fix one problem with mount.smb script
- fix smbpasswd on sparc with a really ugly kludge

* Thu Jun 10 1999 Dale Lovelace <dale@redhat.com>
- fixed logrotate script

* Tue May 25 1999 Bill Nottingham <notting@redhat.com>
- turn of 64-bit locking on 32-bit platforms

* Thu May 20 1999 Bill Nottingham <notting@redhat.com>
- so many releases, so little time
- explicitly uncomment 'printing = bsd' in sample config

* Tue May 18 1999 Bill Nottingham <notting@redhat.com>
- update to 2.0.4a
- fix mount.smb arg ordering

* Fri Apr 16 1999 Bill Nottingham <notting@redhat.com>
- go back to stop/start for restart (-HUP didn't work in testing)

* Fri Mar 26 1999 Bill Nottingham <notting@redhat.com>
- add a mount.smb to make smb mounting a little easier.
- smb filesystems apparently don't work on alpha. Oops.

* Thu Mar 25 1999 Bill Nottingham <notting@redhat.com>
- always create codepages

* Tue Mar 23 1999 Bill Nottingham <notting@redhat.com>
- logrotate changes

* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com> 
- auto rebuild in the new build environment (release 3)

* Fri Mar 19 1999 Preston Brown <pbrown@redhat.com>
- updated init script to use graceful restart (not stop/start)

* Tue Mar  9 1999 Bill Nottingham <notting@redhat.com>
- update to 2.0.3

* Thu Feb 18 1999 Bill Nottingham <notting@redhat.com>
- update to 2.0.2

* Mon Feb 15 1999 Bill Nottingham <notting@redhat.com>
- swat swat

* Tue Feb  9 1999 Bill Nottingham <notting@redhat.com>
- fix bash2 breakage in post script

* Fri Feb  5 1999 Bill Nottingham <notting@redhat.com>
- update to 2.0.0

* Mon Oct 12 1998 Cristian Gafton <gafton@redhat.com>
- make sure all binaries are stripped

* Thu Sep 17 1998 Jeff Johnson <jbj@redhat.com>
- update to 1.9.18p10.
- fix %triggerpostun.

* Tue Jul 07 1998 Erik Troan <ewt@redhat.com>
- updated postun triggerscript to check $0
- clear /etc/codepages from %preun instead of %postun

* Mon Jun 08 1998 Erik Troan <ewt@redhat.com>
- made the %postun script a tad less agressive; no reason to remove
  the logs or lock file (after all, if the lock file is still there,
  samba is still running)
- the %postun and %preun should only exectute if this is the final
  removal
- migrated %triggerpostun from Red Hat's samba package to work around
  packaging problems in some Red Hat samba releases

* Sun Apr 26 1998 John H Terpstra <jht@samba.anu.edu.au>
- minor tidy up in preparation for release of 1.9.18p5
- added findsmb utility from SGI package

* Wed Mar 18 1998 John H Terpstra <jht@samba.anu.edu.au>
- Updated version and codepage info.
- Release to test name resolve order

* Sat Jan 24 1998 John H Terpstra <jht@samba.anu.edu.au>
- Many optimisations (some suggested by Manoj Kasichainula <manojk@io.com>
- Use of chkconfig in place of individual symlinks to /etc/rc.d/init/smb
- Compounded make line
- Updated smb.init restart mechanism
- Use compound mkdir -p line instead of individual calls to mkdir
- Fixed smb.conf file path for log files
- Fixed smb.conf file path for incoming smb print spool directory
- Added a number of options to smb.conf file
- Added smbadduser command (missed from all previous RPMs) - Doooh!
- Added smbuser file and smb.conf file updates for username map