--- system-config-samba-1.2.50.orig/debian/pycompat +++ system-config-samba-1.2.50/debian/pycompat @@ -0,0 +1 @@ +2 --- system-config-samba-1.2.50.orig/debian/system-config-samba.8 +++ system-config-samba-1.2.50/debian/system-config-samba.8 @@ -0,0 +1,25 @@ +.\" Hey, EMACS: -*- nroff -*- +.TH SYSTEM-CONFIG-SAMBA 8 "Jun 12, 2007" +.SH NAME +system-config-samba \- GUI for managing Samba shares and users +.SH SYNOPSIS +.B system-config-samba +.SH DESCRIPTION +This manual page documents briefly the +.B system-config-samba +command. +.PP +.B system-config-samba +is a program that provides a graphical interface for managing Samba users and shares. +.SH SEE ALSO +.BR samba (7) +.br +The program is fully documented at +.nh +.I file:///usr/share/doc/system-config-samba/index.html +.hy +.SH AUTHOR +redhat-config-samba was written by Brent Fox . +.PP +This manual page was written by Soren Hansen , +for Ubuntu (but may be used by others). --- system-config-samba-1.2.50.orig/debian/system-config-samba.docs +++ system-config-samba-1.2.50/debian/system-config-samba.docs @@ -0,0 +1 @@ +doc/* --- system-config-samba-1.2.50.orig/debian/system-config-samba.manpages +++ system-config-samba-1.2.50/debian/system-config-samba.manpages @@ -0,0 +1 @@ +debian/system-config-samba.8 --- system-config-samba-1.2.50.orig/debian/changelog +++ system-config-samba-1.2.50/debian/changelog @@ -0,0 +1,27 @@ +system-config-samba (1.2.50-0ubuntu2.2) hardy-proposed; urgency=low + + * Add 06_fix_crash_onhelp to debian/patches/00list (LP: #215571) + + -- Luca Falavigna Wed, 24 Sep 2008 22:51:58 +0200 + +system-config-samba (1.2.50-0ubuntu2.1) hardy-proposed; urgency=low + + * debian/patches/06_fix_crash_onhelp.dpatch. + - Fix crasher when clicking on the help button. (LP: #215571) + + -- Chuck Short Thu, 29 May 2008 16:29:20 -0400 + +system-config-samba (1.2.50-0ubuntu2) gutsy; urgency=low + + * Remove writeSmbPasswdFile from old patch. + * Add descriptions for the included dpatches. + * Don't use python-disutils cdbs class. + + -- Soren Hansen Mon, 10 Sep 2007 10:11:52 +0200 + +system-config-samba (1.2.50-0ubuntu1) gutsy; urgency=low + + * Initial release + + -- Soren Hansen Sat, 01 Sep 2007 13:47:34 +0200 + --- system-config-samba-1.2.50.orig/debian/control +++ system-config-samba-1.2.50/debian/control @@ -0,0 +1,15 @@ +Source: system-config-samba +Section: admin +Priority: optional +Maintainer: Soren Hansen +Build-Depends: cdbs (>= 0.4.43), debhelper (>= 5.0.38), dpatch, intltool, python-central (>= 0.5.6), python-all-dev (>= 2.3.5-11) +Standards-Version: 3.7.2 +XS-Python-Version: current + +Package: system-config-samba +Architecture: all +Depends: ${python:Depends}, samba, python-libuser +XB-Python-Version: ${python:Versions} +Description: GUI for managing samba shares and users + system-config-samba is a graphical user interface for creating, + modifying, and deleting samba shares and users. --- system-config-samba-1.2.50.orig/debian/rules +++ system-config-samba-1.2.50/debian/rules @@ -0,0 +1,36 @@ +#!/usr/bin/make -f + +DEB_PYTHON_SYSTEM=pycentral +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/makefile.mk +include /usr/share/cdbs/1/rules/dpatch.mk +include /usr/share/dpatch/dpatch.make + +DEB_MAKE_INSTALL_TARGET := install DESTDIR=$(CURDIR)/debian/tmp/ +DEB_MAKE_CLEAN_TARGET := clean + +clean:: + make -C po clean + +binary-install/system-config-samba:: + dh_pycentral /usr/share/system-config-samba + dh_desktop + dh_icons + +install/system-config-samba:: + rm debian/tmp/usr/bin/system-config-samba + rmdir debian/tmp/usr/bin + install -d debian/tmp/usr/sbin/ + ln -s /usr/share/system-config-samba/system-config-samba.py debian/tmp/usr/sbin/system-config-samba + +# Temporary rule until the author starts being more "upstream"-ish and publishes the tarballs directly +get-orig-source:: + test -f system-config-samba.spec && mv system-config-samba.spec system-config-samba.spec.tmp + + wget http://koji.fedoraproject.org/packages/system-config-samba/1.2.50/1.fc8/src/system-config-samba-1.2.50-1.fc8.src.rpm + rpm2cpio *.src.rpm | cpio -i + bunzip2 -c system-config-samba-*.tar.bz2 | gzip -c > `basename system-config-samba*.bz2 .bz2`.gz + rm system-config-samba-*.src.rpm system-config-samba-*.bz2 system-config-samba.spec + + test -f system-config-samba.spec.tmp && mv system-config-samba.spec.tmp system-config-samba.spec + --- system-config-samba-1.2.50.orig/debian/compat +++ system-config-samba-1.2.50/debian/compat @@ -0,0 +1 @@ +5 --- system-config-samba-1.2.50.orig/debian/copyright +++ system-config-samba-1.2.50/debian/copyright @@ -0,0 +1,40 @@ +This package was debianized by Soren Hansen on +Thu, 31 May 2007 08:59:20 +0200. + +It was downloaded from http://mirrors.dotsrc.org/fedora/6/source/SRPMS/system-config-samba-1.2.35-1.1.src.rpm + +Upstream Author: + + Brent Fox + +Copyright: + +src/samba-share.py: + Copyright (C) 2004 Red Hat, Inc. + Copyright (C) 2004 Brent Fox + +All other files: + Copyright (C) 2002, 2003 Red Hat, Inc. + Copyright (C) 2002, 2003 Brent Fox + +License: + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + 02110-1301, USA. + +For the full license, please see `/usr/share/common-licenses/GPL-2'. + +The Debian packaging is (C) 2007, Soren Hansen and +is licensed under the GPL, see `/usr/share/common-licenses/GPL-2'. --- system-config-samba-1.2.50.orig/debian/system-config-samba.install +++ system-config-samba-1.2.50/debian/system-config-samba.install @@ -0,0 +1 @@ +debian/tmp/usr --- system-config-samba-1.2.50.orig/debian/patches/00list +++ system-config-samba-1.2.50/debian/patches/00list @@ -0,0 +1,6 @@ +01_interpreter_path_fix +02_get_rid_of_rhpl +03_sysvrc +04_desktop +05_fixperms +06_fix_crash_onhelp --- system-config-samba-1.2.50.orig/debian/patches/04_desktop.dpatch +++ system-config-samba-1.2.50/debian/patches/04_desktop.dpatch @@ -0,0 +1,30 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 06_desktop.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Fix desktop file +## DP: - Make .desktop file compliant: +## DP: + Don't use absolute path in Exec. +## DP: + Add gksu to Exec. +## DP: + Add Version and Encoding. +## DP: + Remove Application and add Network to Categories. + + +@DPATCH@ +diff -urNad system-config-samba-1.2.50~/system-config-samba.desktop.in system-config-samba-1.2.50/system-config-samba.desktop.in +--- system-config-samba-1.2.50~/system-config-samba.desktop.in 2007-09-01 13:38:33.000000000 +0200 ++++ system-config-samba-1.2.50/system-config-samba.desktop.in 2007-09-01 13:39:24.842305381 +0200 +@@ -1,9 +1,11 @@ + [Desktop Entry] ++Version=1.0 ++Encoding=UTF-8 + _Name=Samba + _Comment=Create, modify, and delete samba shares + Categories=System;Settings; +-Icon=system-config-samba.png +-Exec=/usr/bin/system-config-samba ++Icon=system-config-samba ++Exec=gksu system-config-samba + Type=Application + StartupNotify=true + Terminal=false --- system-config-samba-1.2.50.orig/debian/patches/03_sysvrc.dpatch +++ system-config-samba-1.2.50/debian/patches/03_sysvrc.dpatch @@ -0,0 +1,60 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 03_sysvrc.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: We don't use /sbin/service to manage samba.. + +@DPATCH@ +diff -urNad system-config-samba-1.2.50~/src/sambaBackend.py system-config-samba-1.2.50/src/sambaBackend.py +--- system-config-samba-1.2.50~/src/sambaBackend.py 2007-09-01 15:04:13.585689391 +0200 ++++ system-config-samba-1.2.50/src/sambaBackend.py 2007-09-01 15:04:25.405865338 +0200 +@@ -30,46 +30,11 @@ + + class SambaBackend: + +- def nmbIsService (self): +- # Check if nmb is its own service +- s = os.system ('/sbin/chkconfig --list nmb >& /dev/null') +- if s == 0: +- return True +- else: +- return False +- + def isSambaRunning (self): +- services = [ ('smb', 'smbd') ] +- +- if self.nmbIsService (): +- services.append ( ('nmb', 'nmbd') ) +- +- for service, procname in services: +- fd = os.popen ('LC_MESSAGES=C /sbin/service %s status' % service) +- lines = fd.readlines () +- fd.close () +- +- for line in lines: +- if string.find (line, procname) >= 0: +- if not string.find (line, 'running') > 0: +- return False +- +- return True ++ return os.path.exists('/var/run/samba/smbd.pid') + + def startSamba(self): +- services = ['smb'] +- +- if self.nmbIsService (): +- services.append ('nmb') +- +- for service in services: +- os.system ('/sbin/service %s start > /dev/null' % service) ++ os.system ('/usr/sbin/invoke-rc.d samba start > /dev/null') + + def restartSamba(self): +- services = ['smb'] +- +- if self.nmbIsService (): +- services.append ('nmb') +- +- for service in services: +- os.system ('/sbin/service %s restart > /dev/null' % service) ++ os.system ('/usr/sbin/invoke-rc.d samba restart > /dev/null') --- system-config-samba-1.2.50.orig/debian/patches/02_get_rid_of_rhpl.dpatch +++ system-config-samba-1.2.50/debian/patches/02_get_rid_of_rhpl.dpatch @@ -0,0 +1,133 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 02_get_rid_of_rhpl.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Work around rhpl dependency (basically just use gettext instead). + +@DPATCH@ +diff -urNad system-config-samba-1.2.35~/src/addUserWin.py system-config-samba-1.2.35/src/addUserWin.py +--- system-config-samba-1.2.35~/src/addUserWin.py 2005-04-01 17:35:37.000000000 +0200 ++++ system-config-samba-1.2.35/src/addUserWin.py 2007-05-31 15:34:48.824218138 +0200 +@@ -24,8 +24,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + gtk.glade.bindtextdomain(domain) +diff -urNad system-config-samba-1.2.35~/src/basicPreferencesWin.py system-config-samba-1.2.35/src/basicPreferencesWin.py +--- system-config-samba-1.2.35~/src/basicPreferencesWin.py 2005-04-01 17:35:37.000000000 +0200 ++++ system-config-samba-1.2.35/src/basicPreferencesWin.py 2007-05-31 15:34:48.824218138 +0200 +@@ -26,8 +26,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + gtk.glade.bindtextdomain(domain) +diff -urNad system-config-samba-1.2.35~/src/mainWindow.py system-config-samba-1.2.35/src/mainWindow.py +--- system-config-samba-1.2.35~/src/mainWindow.py 2006-03-29 15:13:29.000000000 +0200 ++++ system-config-samba-1.2.35/src/mainWindow.py 2007-05-31 15:34:48.824218138 +0200 +@@ -33,8 +33,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + gtk.glade.bindtextdomain(domain) +diff -urNad system-config-samba-1.2.35~/src/samba-share.py system-config-samba-1.2.35/src/samba-share.py +--- system-config-samba-1.2.35~/src/samba-share.py 2004-03-22 22:00:09.000000000 +0100 ++++ system-config-samba-1.2.35/src/samba-share.py 2007-05-31 15:34:48.824218138 +0200 +@@ -28,8 +28,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + translate.textdomain ("system-config-samba") + + TRUE = 1 +diff -urNad system-config-samba-1.2.35~/src/sambaBackend.py system-config-samba-1.2.35/src/sambaBackend.py +--- system-config-samba-1.2.35~/src/sambaBackend.py 2004-03-05 00:55:01.000000000 +0100 ++++ system-config-samba-1.2.35/src/sambaBackend.py 2007-05-31 15:34:48.824218138 +0200 +@@ -23,8 +23,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + +diff -urNad system-config-samba-1.2.35~/src/sambaParser.py system-config-samba-1.2.35/src/sambaParser.py +--- system-config-samba-1.2.35~/src/sambaParser.py 2005-04-01 17:35:37.000000000 +0200 ++++ system-config-samba-1.2.35/src/sambaParser.py 2007-05-31 15:34:48.824218138 +0200 +@@ -28,8 +28,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + +diff -urNad system-config-samba-1.2.35~/src/sambaUserData.py system-config-samba-1.2.35/src/sambaUserData.py +--- system-config-samba-1.2.35~/src/sambaUserData.py 2005-04-01 17:35:37.000000000 +0200 ++++ system-config-samba-1.2.35/src/sambaUserData.py 2007-05-31 15:34:48.824218138 +0200 +@@ -24,8 +24,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + gtk.glade.bindtextdomain(domain) +diff -urNad system-config-samba-1.2.35~/src/sambaUserWin.py system-config-samba-1.2.35/src/sambaUserWin.py +--- system-config-samba-1.2.35~/src/sambaUserWin.py 2005-04-01 17:35:37.000000000 +0200 ++++ system-config-samba-1.2.35/src/sambaUserWin.py 2007-05-31 15:34:48.824218138 +0200 +@@ -26,8 +26,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + gtk.glade.bindtextdomain(domain) +diff -urNad system-config-samba-1.2.35~/src/shareWindow.py system-config-samba-1.2.35/src/shareWindow.py +--- system-config-samba-1.2.35~/src/shareWindow.py 2005-04-01 17:35:37.000000000 +0200 ++++ system-config-samba-1.2.35/src/shareWindow.py 2007-05-31 15:34:48.824218138 +0200 +@@ -28,8 +28,8 @@ + ## + ## I18N + ## +-from rhpl.translate import _, N_ +-import rhpl.translate as translate ++from gettext import gettext as _ ++import gettext as translate + domain = 'system-config-samba' + translate.textdomain (domain) + gtk.glade.bindtextdomain(domain) --- system-config-samba-1.2.50.orig/debian/patches/01_interpreter_path_fix.dpatch +++ system-config-samba-1.2.50/debian/patches/01_interpreter_path_fix.dpatch @@ -0,0 +1,25 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 01_interpreter_path_fix.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Set #!/usr/bin/python instead of #!/usr/bin/python2 + +@DPATCH@ +diff -urNad system-config-samba-1.2.35~/src/samba-share.py system-config-samba-1.2.35/src/samba-share.py +--- system-config-samba-1.2.35~/src/samba-share.py 2004-03-22 22:00:09.000000000 +0100 ++++ system-config-samba-1.2.35/src/samba-share.py 2007-05-31 10:23:38.260243333 +0200 +@@ -1,4 +1,4 @@ +-#!/usr/bin/python2 ++#!/usr/bin/python + + ## samba-share.py - Contains the startup script for system-config-samba + ## Copyright (C) 2004 Red Hat, Inc. +diff -urNad system-config-samba-1.2.35~/src/system-config-samba.py system-config-samba-1.2.35/src/system-config-samba.py +--- system-config-samba-1.2.35~/src/system-config-samba.py 2004-10-10 00:50:14.000000000 +0200 ++++ system-config-samba-1.2.35/src/system-config-samba.py 2007-05-31 10:23:18.759132028 +0200 +@@ -1,4 +1,4 @@ +-#!/usr/bin/python2 ++#!/usr/bin/python + + ## system-config-samba.py - Contains the startup script for system-config-samba + ## Copyright (C) 2002, 2003 Red Hat, Inc. --- system-config-samba-1.2.50.orig/debian/patches/05_fixperms.dpatch +++ system-config-samba-1.2.50/debian/patches/05_fixperms.dpatch @@ -0,0 +1,35 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 05_fixperms.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Stop installing png's, .glade file and all other files that are not to be run, with mode 775. + +@DPATCH@ +diff -urNad system-config-samba-1.2.50~/Makefile system-config-samba-1.2.50/Makefile +--- system-config-samba-1.2.50~/Makefile 2007-09-01 13:44:37.000000000 +0200 ++++ system-config-samba-1.2.50/Makefile 2007-09-01 13:47:07.326916809 +0200 +@@ -41,16 +41,17 @@ + mkdir -p $(DESTDIR)/usr/share/pixmaps + mkdir -p $(DESTDIR)/usr/share/applications + mkdir -p $(DESTDIR)/usr/share/icons/hicolor/48x48/apps +- install src/*.py src/smb.conf.template $(DESTDIR)$(PKGDATADIR) ++ install -m 644 src/*.py src/smb.conf.template $(DESTDIR)$(PKGDATADIR) + for py in src/*.py ; do \ + sed -e s,@VERSION@,$(VERSION),g $${py} > $(DESTDIR)$(PKGDATADIR)/`basename $${py}` ; \ + done +- install src/*.glade $(DESTDIR)$(PKGDATADIR) +- install $(PKGNAME).pam $(DESTDIR)$(PAMD_DIR)/$(PKGNAME) +- install $(PKGNAME).console $(DESTDIR)$(SECURITY_DIR)/$(PKGNAME) +- install pixmaps/*.png $(DESTDIR)$(PKGIMAGEDIR) +- install pixmaps/${PKGNAME}.png $(DESTDIR)/usr/share/icons/hicolor/48x48/apps +- install ${PKGNAME}.desktop $(DESTDIR)/usr/share/applications/${PKGNAME}.desktop ++ for py in sambaoptionscheck.py samba-share.py system-config-samba.py ; do \ ++ chmod 755 $(DESTDIR)$(PKGDATADIR)/$${py} ; \ ++ done ++ install -m 644 src/*.glade $(DESTDIR)$(PKGDATADIR) ++ install -m 644 pixmaps/*.png $(DESTDIR)$(PKGIMAGEDIR) ++ install -m 644 pixmaps/${PKGNAME}.png $(DESTDIR)/usr/share/icons/hicolor/48x48/apps ++ install -m 644 ${PKGNAME}.desktop $(DESTDIR)/usr/share/applications/${PKGNAME}.desktop + ln -sf consolehelper $(DESTDIR)/usr/bin/$(PKGNAME) + for d in $(SUBDIRS); do \ + (cd $$d; $(MAKE) DESTDIR=$(DESTDIR) MANDIR=$(MANDIR) install) \ --- system-config-samba-1.2.50.orig/debian/patches/06_fix_crash_onhelp.dpatch +++ system-config-samba-1.2.50/debian/patches/06_fix_crash_onhelp.dpatch @@ -0,0 +1,21 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run + +@DPATCH@ +diff -Naur system-config-samba-1.2.50.orig/src/mainWindow.py system-config-samba-1.2.50/src/mainWindow.py +--- system-config-samba-1.2.50.orig/src/mainWindow.py 2007-08-31 11:27:50.000000000 -0400 ++++ system-config-samba-1.2.50/src/mainWindow.py 2008-05-29 16:24:45.000000000 -0400 +@@ -471,8 +471,12 @@ + dlg.destroy() + + def onHelpClicked(self, *args): +- help_page = "file:///usr/share/doc/system-config-samba-" + "@VERSION@" + "/index.html" +- path = "/usr/bin/htmlview" ++ help_page = "ghelp:///usr/share/doc/system-config-samba/index.html" ++ paths = [ "/usr/bin/yelp", None] ++ ++ for path in paths: ++ if path and os.access (path, os.X_OK): ++ break + + if path == None: + dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_WARNING, gtk.BUTTONS_OK,