Re: [Samba] RPM building tools for Samba 4.0.3 on RHEL 6 published bye me on Github

2013-03-22 Thread Miguel Medalha

Regarding your latest samba.spec for version 4.0.4-0.1

If with_dc is activated, the build still fails with:

RPM build errors:
Installed (but unpackaged) file(s) found:
   /usr/lib64/samba/ldb/ildap.so

As I reported before, there is an entry for ldbsamba_extensions.so 
under # ldb libraries built with DC activated but not for ildap.so.

The file gets built but not packaged.


Also, the installation of the samba-libs package fails with:

error: Failed dependencies:
libdfs_server_ad.so()(64bit) is needed by 
samba-libs-0:4.0.4-0.1.el6.x86_64
libdfs_server_ad.so(SAMBA_4.0.4)(64bit) is needed by 
samba-libs-0:4.0.4-0.1.el6.x86_64


The query rpm --query --requires -p 
samba-libs-4.0.4-0.1.el6.x86_64.rpm gives libdfs_server_ad.so as a 
requirement.


Is there any reason why my previous suggestion to package 
libdfs_server_ad.so in samba-libs instead of samba-dc-libs was not 
accepted?
If you do that, under the condition %if %with_dc, the error 
disappears. Please note that samba-libs must always be installed 
before samba-dc-libs, so that the samba-dc-libs requirement at 
install has already been satisfied by samba-libs.



As also reported before, the same happens with libposix_eadb.so. It is 
required by samba. I suggested that it be moved to the same section as 
libdfs_server_ad.so, i.e. in samba-libs under %if %with_dc.


If these two steps are taken, both build and install complete flawlessly 
and you get a working AD DC installation.




If this is accepted, as a final touch and for the sake of consistency, 
the %exclude for /libdfs_server_ad.so should go into LIBS, under 
%if %with_dc:


%else
# formerly excluded in files dc
%exclude %{_libdir}/samba/libdfs_server_ad.so
%endif # with_dc

and the %exclude for /ildap.so and ldbsamba_extensions.so should 
go into DC-LIBS, also under %if %with_dc


%else
%doc packaging/RHEL-rpms/README.dc-libs
# formerly excluded in files dc
%exclude %{_libdir}/samba/ldb/ildap.so
%exclude %{_libdir}/samba/ldb/ldbsamba_extensions.so
%endif # with_dc

Best regards
Miguel

--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


Re: [Samba] RPM building tools for Samba 4.0.3 on RHEL 6 published bye me on Github

2013-03-20 Thread Miguel Medalha


I tested the .spec file you posted today. There's still a glitch remaining.

If built with the file as it is (%global with_dc 0) the packages build 
cleanly.


However, if %global with_dc 1 is used, the build fails with the 
following error:


RPM build errors:
Installed (but unpackaged) file(s) found:
   /usr/lib64/samba/ldb/ildap.so

I can see that this file is excluded in the packging list pertaining to 
DC-LIBS, if with_dc is disabled but it is not one of the # ldb 
libraries built with DC activated, contrary to the other file always 
excluded in the Fedora .spec (ldbsamba_extensions.so), which is listed 
in your file.


When I do a rpm query for --whatrequires both files, the answer is that 
no package requires either file. As such, they should probably be always 
excluded, as happens with the Fedora .spec file.



One more thing: since Samba 4.0.4 is out now, maybe you should update 
your files to match? This is just a security release that presents no 
problem whatsoever when built with the same specs as 4.0.3. I did it and 
all went well. I have an experimental AD domain controller working 
correctly it it.


Thank you again

--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


Re: [Samba] RPM building tools for Samba 4.0.3 on RHEL 6 published bye me on Github

2013-03-20 Thread Miguel Medalha


I forgot something.

%{_libdir}/samba/libdfs_server_ad.so
%{_libdir}/samba/libposix_eadb.so

As I said before, those two entries MUST be within ### LIBS, under 
%if %with_dc. Otherwise, the build completes cleanly but the install 
process of samba-libs and samba fails with the following:


error: Failed dependencies:
libdfs_server_ad.so()(64bit) is needed by 
samba-libs-0:4.0.4-1.el6.x86_64
libdfs_server_ad.so(SAMBA_4.0.4)(64bit) is needed by 
samba-libs-0:4.0.4-1.el6.x86_64


error: Failed dependencies:
libposix_eadb.so()(64bit) is needed by samba-0:4.0.3-0.6.el6.x86_64
libposix_eadb.so(SAMBA_4.0.3)(64bit) is needed by 
samba-0:4.0.3-0.6.el6.x86_64



I suggest doing the described inclusions and, for the sake of 
consistency, moving the correspondent exclusion to the same section:


### LIBS
%if %with_dc
%{_libdir}/samba/libdfs_server_ad.so
%{_libdir}/samba/libposix_eadb.so
%else
# formerly excluded in files dc
%exclude %{_libdir}/samba/libdfs_server_ad.so
%endif # with_dc

If these steps are taken, everything builds and installs correctly, 
whether AD DC is activated or not.



The Fedora .spec file excludes samba/libdfs_server_ad.so from the 
build process altogether because Fedora is not using the AD DC component 
of Samba 4 due to lack of support with MIT Kerberos.


---

On the matter of the release of Samba 4.0.4, shouldn't the Obsoletes 
statement now include the form Obsoletes: samba  %{samba_depver} 
instead of only Obsoletes: samba4  %{samba_depver}? You now need to 
Obsolete all versions of Samba 4 prior to 4.0.4, both release and 
pre-release.


Also, I think that the form you are still using for Provides (for 
example Provides: samba4-common = %{samba_depver}) is no longer 
correct. According to the Samba team conventions, after the release of 
Samba 4 the form should now be Provides: samba-common = %{samba_depver}.


In a previous mail to you, I suggested:

Provides: samba = %{samba_depver}
Conflicts: samba4  %{samba_depver}
Obsoletes: samba  %{samba_depver}

I used Conflicts for samba4 because there are significant 
differences between the pre-release and the release versions.

Or maybe we could use two Obsoletes statements instead...

Best regards
Miguel

--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


Re: [Samba] RPM building tools for Samba 4.0.3 on RHEL 6 published bye me on Github

2013-03-20 Thread Nico Kadel-Garcia
I'll update as soon as I find cycles...

Nico Kadel-Garcia
Email: nka...@gmail.com
Sent from iPhone

On Mar 20, 2013, at 15:37, Miguel Medalha miguelmeda...@sapo.pt wrote:

 built
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


Re: [Samba] RPM building tools for Samba 4.0.3 on RHEL 6 published bye me on Github

2013-02-22 Thread Nico Kadel-Garcia
On Fri, Feb 22, 2013 at 12:40 PM, Diego Remolina
diego.remol...@physics.gatech.edu wrote:
 I think a lot of your work was probably prior to RHEL 6.4, but have you
 tried looking at their new SRPM for samba 4.0.0 and adapting it to 4.0.3?

Unfortunately somewhere between 4.0.0 and 4.0.3. they introduced now
related package dependencies on  libtalloc, libtdb, libtevent,
iniparser, and krb5. So the RHEL 6.4 inlcudes krb5-1.10, which
eliminates one problem, but doesn't resolve the others. That's why I
put updates for those as well up at https://github.com/nkadel/ and
into the Samba repository building tools at
https://github.com/nkadel/samba4repo/.

Since building with mock relies on CentOS, or Scientific Linux or a
local RHEL yum repo, to have the updated packages, it's going to be a
while before the new RHEL 6.4 packages are broadly available anyway.
I'll yank them from github.com if and as they become available as part
of 6.4 releases.

 http://ftp.redhat.com/pub/redhat/linux/enterprise/6Server/en/os/SRPMS/samba4-4.0.0-55.el6.rc4.src.rpm

 They have also posted the new SRPMS for the libtdb and libtalloc and other
 software that may be required:

 http://ftp.redhat.com/pub/redhat/linux/enterprise/6Server/en/os/SRPMS/libtalloc-2.0.7-2.el6.src.rpm
 http://ftp.redhat.com/pub/redhat/linux/enterprise/6Server/en/os/SRPMS/libtdb-1.2.10-1.el6.src.rpm
 http://ftp.redhat.com/pub/redhat/linux/enterprise/6Server/en/os/SRPMS/libtevent-0.9.8-8.el6.src.rpm

Those are new enough for Samba 4.0.0, not for Samba 4.0.3.
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


[Samba] RPM building tools for Samba 4.0.3 on RHEL 6 published bye me on Github

2013-02-21 Thread Nico Kadel-Garcia
I've been spending some time backporting Samba 4.0.3 from Fedora 19 to
RHEL 6, partly as proof of concept, partly to make it available to
others. I've published my work at:

https://github.com/nkadel/samba4repo/

The key RPM building tools are at:

https://github.com/nkadel/samba-4.0.3-srpm/

And there are dependencies listed for libtalloc, libtevent, iniparser,
etc. that I've also put up at https://github.com. It works in my basic
testing, but I don't have a local set of Active Directory clients and
servers to play with for full testing.

This includes hooks for building all the components with mock,
including notes on where to get the necessary components from
github.com. The README.md from that directory is below. I'm happy to
make these as refined and idiot proof as anyone would like, since I'm
between jobs right now, but but I don't want to confuse anyone. I've
also noticed that several dependencies, such as krb5-1.10, may be
already available as part of RHEL 6.4 which was released *less than 24
hours ago*.

=
Wrapper for SRPM building tools for Samba 4 on RHEL 6.

These are rebuilt from Fedora rawhide releases, and need to be built
and installed in the following order.

samba4repo-6-x86_64.cfg - install in /etc/mock/
samba4repo.repo - install in /etc/yum.repos.d/.

Then install and enable a yum repository on the local server, or a
designated host, with this kind of layout:

mkdir /var/www/linux
mkdir /var/www/linux/samba4repo
mkdir /var/www/linux/samba4repo/6
mkdir /var/www/linux/samba4repo/6/x86_64
createrepo /var/www/linux/samba4repo/6/x86_64
mkdir /var/www/linux/samba4repo/6/SRPMS
createrepo /var/www/linux/samba4repo/6/SRPMS

Set up symlinks for $releasever names in yum setups.

ln -s -f -n 6 /var/www/linux/samba4repo/6.3
ln -s -f -n 6 /var/www/linux/samba4repo/6Server

The make command will build all components. If they don't exist yet,
they will be git cloned from https://github.com/nkadel/. The
components there are somewhat interwoven with this samba4repo
structure, so review it before building or deploying with it.

*** NOTE: The git repos at github.com do not include the tarballs ***

This is for basic security reasons: I do not want to become
responsible for publishing the source code software for other people's
compnents, and possibly getting hacked and corrupting your software.
You'll need to get the tarballs manually, usually from the Source:
locations designated in the .spec file.

make install will attempt to deploy them in a designated directory
for yum repository access, run createrepo, to get the packages
listeed, and and clear away old mock configurations. createrepo
--update and mock clean are somewhat unreliable in their behavior,
so actually re-running and createrepo and using rm -rf on the mock
cache works better.

Samba 4.0.3 has strong dependencies on additional components that are
not part of RHEL 6, or are not recent enough in RHEL 6, and need to be
built and deployed for local compilation or for mock compilation.
These dependencies are detailed in the Makefile, but include:

iniparser
krb5
libtalloc
libtdb
libldb
libtevent

Nico Kadel-Garcia nka...@gmail.com
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba