rpms/cdcollect/F-7 cdcollect-0.6.0.patch, NONE, 1.1 cdcollect-libdir.patch, NONE, 1.1 cdcollect.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
Dan Horak (sharkcz)
fedora-extras-commits at redhat.com
Wed Sep 26 19:12:59 UTC 2007
- Previous message (by thread): rpms/pungi/devel .cvsignore, 1.27, 1.28 pungi.spec, 1.29, 1.30 sources, 1.28, 1.29
- Next message (by thread): rpms/xorg-x11-server/devel xserver-1.3.0-intel-by-default.patch, NONE, 1.1 xorg-x11-server-1.0.1-fpic-libxf86config.patch, 1.3, 1.4 xorg-x11-server.spec, 1.251, 1.252 xserver-1.3.0-randr-updates.patch, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: sharkcz
Update of /cvs/pkgs/rpms/cdcollect/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv26328
Modified Files:
.cvsignore sources
Added Files:
cdcollect-0.6.0.patch cdcollect-libdir.patch cdcollect.spec
Log Message:
- initial import
cdcollect-0.6.0.patch:
--- NEW FILE cdcollect-0.6.0.patch ---
diff -Nru cdcollect-0.6.0-orig/resources/glade/gui.glade cdcollect-0.6.0/resources/glade/gui.glade
--- cdcollect-0.6.0-orig/resources/glade/gui.glade 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/resources/glade/gui.glade 2007-07-16 21:30:02.000000000 +0200
@@ -1143,7 +1143,7 @@
<child>
<widget class="GtkLabel" id="label10">
<property name="visible">True</property>
- <property name="label" translatable="yes">Mount Point:</property>
+ <property name="label" translatable="yes">Device:</property>
<property name="use_underline">False</property>
<property name="use_markup">False</property>
<property name="justify">GTK_JUSTIFY_LEFT</property>
@@ -1169,7 +1169,7 @@
</child>
<child>
- <widget class="GtkEntry" id="entry_mount">
+ <widget class="GtkEntry" id="entry_device">
<property name="visible">True</property>
<property name="tooltip" translatable="yes">Mount directory for CDs (CD must already be mounted)</property>
<property name="can_focus">True</property>
diff -Nru cdcollect-0.6.0-orig/src/Conf.cs cdcollect-0.6.0/src/Conf.cs
--- cdcollect-0.6.0-orig/src/Conf.cs 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/src/Conf.cs 2007-07-16 21:48:45.000000000 +0200
@@ -35,7 +35,6 @@
public string default_cd_device;
- public string default_cd_mount;
public Conf ()
{
@@ -61,9 +60,6 @@
/* Get the CD device */
default_cd_device = "/dev/hdc";
- /* Get the mount point for */
- default_cd_mount = "/media/cdrom";
-
/* create home dirs if they not exists */
create_home_dirs ();
}
diff -Nru cdcollect-0.6.0-orig/src/ImportCDWindow.cs cdcollect-0.6.0/src/ImportCDWindow.cs
--- cdcollect-0.6.0-orig/src/ImportCDWindow.cs 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/src/ImportCDWindow.cs 2007-07-16 22:45:47.000000000 +0200
@@ -50,6 +50,7 @@
// Private variables
private static Glade.XML gxml;
private string mount;
+ private string device;
private bool use_infoplugins, use_compplugins, compplugins_recursive, use_thumbs;
private int key = -10;
@@ -67,7 +68,7 @@
// Methods
- public ImportCDWindow (string mount_point, bool info, bool comp, bool recursive, bool thumbs, Gtk.Window parent) : base (IntPtr.Zero)
+ public ImportCDWindow (string default_device, bool info, bool comp, bool recursive, bool thumbs, Gtk.Window parent) : base (IntPtr.Zero)
{
/* Show Main Dialog using glade */
gxml = new Glade.XML (null, "gui.glade", "win_importcd", null);
@@ -80,7 +81,8 @@
/* Prepare gui */
prepare_gui ();
- mount = mount_point;
+ device = default_device;
+ mount = get_mount();
use_infoplugins = info;
use_compplugins = comp;
compplugins_recursive = recursive;
@@ -330,10 +332,10 @@
/* Open the device */
try {
- fdev = new FileStream (CDCollect.conf.default_cd_device,
+ fdev = new FileStream (device,
System.IO.FileMode.Open, System.IO.FileAccess.Read);
} catch {
- Console.WriteLine ("Can not open device " + CDCollect.conf.default_cd_device);
+ Console.WriteLine ("Can not open device " + device);
return("Unknown");
}
@@ -343,7 +345,7 @@
fdev.Seek (32808, SeekOrigin.Begin);
r = fdev.Read (buf, 0, 32);
} catch (System.Exception e) {
- Console.WriteLine ("Can not read device " + CDCollect.conf.default_cd_device);
+ Console.WriteLine ("Can not read device " + device);
return ("Unknown");
}
@@ -373,6 +375,33 @@
}
}
+
+ private string get_mount ()
+ {
+ TextReader f;
+ string line;
+ string mount = "none";
+ string [] fields;
+
+ /* Open the /etc/mtab */
+ try {
+ f = new StreamReader("/etc/mtab");
+ } catch {
+ Console.WriteLine ("Can not open /etc/mtab");
+ return(mount);
+ }
+ /* Read all line, check whether it contains our device and filesystem type is iso9660 */
+ while ((line = f.ReadLine()) != null) {
+ fields = line.Split(' ');
+ if ((fields[0] == device) && (fields[2] == "iso9660")) {
+ mount = fields[1];
+ }
+ }
+
+ f.Close();
+
+ return (mount);
+ }
}
diff -Nru cdcollect-0.6.0-orig/src/Main.cs cdcollect-0.6.0/src/Main.cs
--- cdcollect-0.6.0-orig/src/Main.cs 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/src/Main.cs 2007-07-16 21:48:14.000000000 +0200
@@ -572,7 +572,7 @@
{
/* Create import window */
ImportCDWindow win_importcd = new ImportCDWindow(
- (string) conf.getkey ("prefs/mount_point",conf.default_cd_mount),
+ (string) conf.getkey ("prefs/device",conf.default_cd_device),
(bool) conf.getkey ("prefs/use_information_plugins",true),
(bool) conf.getkey ("prefs/use_compression_plugins",true),
(bool) conf.getkey ("prefs/compression_plugins_recursive",true),
@@ -591,8 +591,8 @@
/* Check if CD has been read */
if (key==-1) {
new ErrorDialog (String.Format (Catalog.GetString (
- "Directory <b>{0}</b> not found.\nPlease change the CD mount point in the Preferences window."),
- (string) conf.getkey ("prefs/mount_point",conf.default_cd_mount)), win_main);
+ "Directory <b>{0}</b> not found.\nPlease change the CD device in the Preferences window."),
+ (string) conf.getkey ("prefs/device",conf.default_cd_device)), win_main);
} else if (key==-2) {
new ErrorDialog (Catalog.GetString ("The mount directory is empty. Please make sure the CD is mounted."), win_main);
} else if (key==-3) {
@@ -637,7 +637,7 @@
{
/* Create Preferences window */
new PreferencesWindow(
- (string) conf.getkey ("prefs/mount_point",conf.default_cd_mount),
+ (string) conf.getkey ("prefs/device",conf.default_cd_device),
(bool) conf.getkey ("prefs/use_information_plugins",true),
(bool) conf.getkey ("prefs/use_compression_plugins",true),
(bool) conf.getkey ("prefs/compression_plugins_recursive",true),
diff -Nru cdcollect-0.6.0-orig/src/PreferencesWindow.cs cdcollect-0.6.0/src/PreferencesWindow.cs
--- cdcollect-0.6.0-orig/src/PreferencesWindow.cs 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/src/PreferencesWindow.cs 2007-07-16 21:45:51.000000000 +0200
@@ -37,7 +37,7 @@
[Glade.Widget] public Gtk.Window win_prefs;
[Glade.Widget] public Gtk.Button btn_ok;
[Glade.Widget] public Gtk.Button btn_cancel;
- [Glade.Widget] public Gtk.Entry entry_mount;
+ [Glade.Widget] public Gtk.Entry entry_device;
[Glade.Widget] public Gtk.CheckButton cbtn_info;
[Glade.Widget] public Gtk.CheckButton cbtn_comp;
@@ -50,7 +50,7 @@
private static Glade.XML gxml;
// Methods
- public PreferencesWindow (string mount, bool info, bool comp, bool recursive, bool thumbs, Gtk.Window parent) : base (IntPtr.Zero)
+ public PreferencesWindow (string device, bool info, bool comp, bool recursive, bool thumbs, Gtk.Window parent) : base (IntPtr.Zero)
{
// Show Main Dialog using glade
gxml = new Glade.XML (null, "gui.glade", "win_prefs", null);
@@ -65,7 +65,7 @@
win_prefs.Title = Catalog.GetString ("CDCollect: Preferences");
// Fill preferences
- entry_mount.Text = mount;
+ entry_device.Text = device;
cbtn_info.Active = info;
cbtn_comp.Active = comp;
cbtn_recursive.Active = recursive;
@@ -79,7 +79,7 @@
win_prefs.ShowAll ();
// Select focus
- entry_mount.GrabFocus();
+ entry_device.GrabFocus();
}
@@ -94,7 +94,7 @@
public void on_ok_clicked (object o, EventArgs args)
{
- CDCollect.conf.setkey ("prefs/mount_point", entry_mount.Text);
+ CDCollect.conf.setkey ("prefs/device", entry_device.Text);
CDCollect.conf.setkey ("prefs/use_information_plugins", cbtn_info.Active);
CDCollect.conf.setkey ("prefs/use_compression_plugins", cbtn_comp.Active);
CDCollect.conf.setkey ("prefs/compression_plugins_recursive", cbtn_recursive.Active);
cdcollect-libdir.patch:
--- NEW FILE cdcollect-libdir.patch ---
diff -Nru cdcollect-0.6.0-orig/src/cdcollect.in cdcollect-0.6.0/src/cdcollect.in
--- cdcollect-0.6.0-orig/src/cdcollect.in 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/src/cdcollect.in 2007-07-17 18:08:13.000000000 +0200
@@ -1,6 +1,6 @@
#!/bin/sh
-LD_LIBRARY_PATH="@prefix@/lib/cdcollect:$LD_LIBRARY_PATH"
+LD_LIBRARY_PATH="@libdir@/cdcollect:$LD_LIBRARY_PATH"
export LD_LIBRARY_PATH
-mono @prefix@/lib/cdcollect/cdcollect.exe $@
+mono @libdir@/cdcollect/cdcollect.exe $@
diff -Nru cdcollect-0.6.0-orig/src/Makefile.am cdcollect-0.6.0/src/Makefile.am
--- cdcollect-0.6.0-orig/src/Makefile.am 2006-11-24 18:12:13.000000000 +0100
+++ cdcollect-0.6.0/src/Makefile.am 2007-07-17 18:06:59.000000000 +0200
@@ -63,7 +63,7 @@
all: cdcollect.exe
-cdcollectlibdir = $(prefix)/lib/cdcollect
+cdcollectlibdir = $(libdir)/cdcollect
install-data-local: cdcollect.exe
$(mkinstalldirs) $(DESTDIR)$(cdcollectlibdir)
@@ -72,7 +72,7 @@
bin_SCRIPTS = cdcollect
cdcollect: cdcollect.in
- sed -e "s|\@prefix\@|$(prefix)|" < $(srcdir)/cdcollect.in > cdcollect
+ sed -e "s|\@libdir\@|$(libdir)|" < $(srcdir)/cdcollect.in > cdcollect
chmod +x cdcollect
EXTRA_DIST = \
diff -Nru cdcollect-0.6.0-orig/src/Makefile.in cdcollect-0.6.0/src/Makefile.in
--- cdcollect-0.6.0-orig/src/Makefile.in 2006-11-24 18:12:36.000000000 +0100
+++ cdcollect-0.6.0/src/Makefile.in 2007-07-17 18:07:51.000000000 +0200
@@ -270,7 +270,7 @@
-resource:$(top_srcdir)/resources/icons/cdcollect_small.png,cdcollect_small.png \
-resource:$(top_srcdir)/resources/icons/cdmovie.png,cdmovie.png
-cdcollectlibdir = $(prefix)/lib/cdcollect
+cdcollectlibdir = $(libdir)/cdcollect
bin_SCRIPTS = cdcollect
EXTRA_DIST = \
$(CDCOLLECT_CSFILES) \
@@ -485,7 +485,7 @@
$(INSTALL_DATA) cdcollect.exe $(DESTDIR)$(cdcollectlibdir)/cdcollect.exe
cdcollect: cdcollect.in
- sed -e "s|\@prefix\@|$(prefix)|" < $(srcdir)/cdcollect.in > cdcollect
+ sed -e "s|\@libdir\@|$(libdir)|" < $(srcdir)/cdcollect.in > cdcollect
chmod +x cdcollect
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
--- NEW FILE cdcollect.spec ---
# rpmbuild creates an empty debuginfo package, this is a Mono application
#%define debug_package %{nil}
Name: cdcollect
Version: 0.6.0
Release: 3%{?dist}
Summary: Simple CD/DVD catalog for GNOME
Group: Applications/Productivity
License: GPLv2+
URL: http://cdcollect.sourceforge.net
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Patch0: cdcollect-libdir.patch
Patch1: cdcollect-0.6.0.patch
BuildRequires: mono-devel >= 1.1.17, gtk-sharp2-devel >= 2.8.0, gnome-sharp-devel
BuildRequires: glib2-devel, sqlite-devel >= 3.3.5, mono-data-sqlite, gettext
BuildRequires: perl(XML::Parser), desktop-file-utils
Requires: mono-core >= 1.1.17, gtk-sharp2 >= 2.8.0, gnome-sharp
Requires: sqlite >= 3.3.5, mono-data-sqlite
Requires(pre): GConf2
Requires(post): GConf2
Requires(preun): GConf2
%description
CDCollect is a simple CD/DVD catalog for GNOME written in C# using Mono
and GTK#. All data are stored in a sqlite database.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
%configure --disable-schemas-install
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
desktop-file-install --vendor fedora \
--remove-category="Application" \
--delete-original \
--dir $RPM_BUILD_ROOT%{_datadir}/applications \
$RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop
%find_lang %{name}
%clean
rm -rf $RPM_BUILD_ROOT
%pre
if [ "$1" -gt 1 ]; then
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
gconftool-2 --makefile-uninstall-rule \
%{_sysconfdir}/gconf/schemas/%{name}.schemas >/dev/null || :
fi
%post
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
gconftool-2 --makefile-install-rule \
%{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
%preun
if [ "$1" -eq 0 ]; then
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
gconftool-2 --makefile-uninstall-rule \
%{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
fi
%files -f %{name}.lang
%defattr(-,root,root,-)
%doc AUTHORS COPYING ChangeLog README TODO
%config(noreplace) %{_sysconfdir}/gconf/schemas/%{name}.schemas
%{_bindir}/%{name}
%{_libdir}/%{name}
%{_datadir}/applications/fedora-%{name}.desktop
%{_datadir}/pixmaps/%{name}.png
%changelog
* Wed Sep 26 2007 Dan Horak <dan[at]danny.cz> 0.6.0-3
- fixed URLs
- removed unneeded BR: pkgconfig
* Mon Sep 24 2007 Dan Horak <dan[at]danny.cz> 0.6.0-2
- update license tag
- fix desktop file installation
* Tue Jul 17 2007 Dan Horak <dan[at]danny.cz> 0.6.0-1
- initial version
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/cdcollect/F-7/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 26 Sep 2007 16:44:56 -0000 1.1
+++ .cvsignore 26 Sep 2007 19:12:27 -0000 1.2
@@ -0,0 +1 @@
+cdcollect-0.6.0.tar.bz2
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/cdcollect/F-7/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 26 Sep 2007 16:44:56 -0000 1.1
+++ sources 26 Sep 2007 19:12:27 -0000 1.2
@@ -0,0 +1 @@
+33f71604b9dfb84497b4bc2fce69e89b cdcollect-0.6.0.tar.bz2
- Previous message (by thread): rpms/pungi/devel .cvsignore, 1.27, 1.28 pungi.spec, 1.29, 1.30 sources, 1.28, 1.29
- Next message (by thread): rpms/xorg-x11-server/devel xserver-1.3.0-intel-by-default.patch, NONE, 1.1 xorg-x11-server-1.0.1-fpic-libxf86config.patch, 1.3, 1.4 xorg-x11-server.spec, 1.251, 1.252 xserver-1.3.0-randr-updates.patch, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list