summaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authorkwm <kwm@df743ca5-7f9a-e211-a948-0013205c9059>2008-01-19 08:04:13 +0800
committerkwm <kwm@df743ca5-7f9a-e211-a948-0013205c9059>2008-01-19 08:04:13 +0800
commitc9d117d3714b71e828c7a326efd1fcff2202a75f (patch)
tree3a2a3a39e2a1bb97e7b4bcc6033ab298c191f72f /sysutils
parent93930d907dbdaac303efae96c46eb46849b12d84 (diff)
downloadmarcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.tar
marcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.tar.gz
marcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.tar.bz2
marcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.tar.lz
marcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.tar.xz
marcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.tar.zst
marcuscom-ports-c9d117d3714b71e828c7a326efd1fcff2202a75f.zip
Add gnome-volume-manager 2.22.1.
git-svn-id: svn://creme-brulee.marcuscom.com/ports/trunk@10151 df743ca5-7f9a-e211-a948-0013205c9059
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/gnome-volume-manager/Makefile31
-rw-r--r--sysutils/gnome-volume-manager/distinfo3
-rw-r--r--sysutils/gnome-volume-manager/files/patch-gnome-volume-manager.schemas.in11
-rw-r--r--sysutils/gnome-volume-manager/files/patch-src_manager.c232
-rw-r--r--sysutils/gnome-volume-manager/pkg-descr3
-rw-r--r--sysutils/gnome-volume-manager/pkg-plist95
6 files changed, 375 insertions, 0 deletions
diff --git a/sysutils/gnome-volume-manager/Makefile b/sysutils/gnome-volume-manager/Makefile
new file mode 100644
index 000000000..ac1127495
--- /dev/null
+++ b/sysutils/gnome-volume-manager/Makefile
@@ -0,0 +1,31 @@
+# New ports collection makefile for: gnome-volume-manager
+# Date created: 02 May 2006
+# Whom: Jean-Yves Lefort <jylefort@FreeBSD.org>
+#
+# $FreeBSD$
+# $MCom$
+#
+
+PORTNAME= gnome-volume-manager
+PORTVERSION= 2.22.1
+CATEGORIES= sysutils gnome
+MASTER_SITES= ${MASTER_SITE_GNOME}
+MASTER_SITE_SUBDIR= sources/${PORTNAME}/${PORTVERSION:R}
+
+MAINTAINER= gnome@FreeBSD.org
+COMMENT= Automatically mount removable media, and more
+
+LIB_DEPENDS= hal.1:${PORTSDIR}/sysutils/hal \
+ notify.1:${PORTSDIR}/devel/libnotify
+
+USE_XLIB= yes
+USE_BZIP2= yes
+USE_GNOME= gnomeprefix gnomehack intlhack nautilus2
+USE_GMAKE= yes
+USE_GETTEXT= yes
+GNU_CONFIGURE= yes
+CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" LDFLAGS="-L${LOCALBASE}/lib"
+CONFIGURE_ARGS= --disable-multiuser
+GCONF_SCHEMAS= gnome-volume-manager.schemas
+
+.include <bsd.port.mk>
diff --git a/sysutils/gnome-volume-manager/distinfo b/sysutils/gnome-volume-manager/distinfo
new file mode 100644
index 000000000..29774bf19
--- /dev/null
+++ b/sysutils/gnome-volume-manager/distinfo
@@ -0,0 +1,3 @@
+MD5 (gnome-volume-manager-2.22.1.tar.bz2) = a0cb86f541515f33443c848879d04785
+SHA256 (gnome-volume-manager-2.22.1.tar.bz2) = 8305428940e3aab9a7c6ccaa283489170d8de96b873695b541c8a7daacd2d591
+SIZE (gnome-volume-manager-2.22.1.tar.bz2) = 361668
diff --git a/sysutils/gnome-volume-manager/files/patch-gnome-volume-manager.schemas.in b/sysutils/gnome-volume-manager/files/patch-gnome-volume-manager.schemas.in
new file mode 100644
index 000000000..94af083a1
--- /dev/null
+++ b/sysutils/gnome-volume-manager/files/patch-gnome-volume-manager.schemas.in
@@ -0,0 +1,11 @@
+--- gnome-volume-manager.schemas.in.orig Wed Jun 7 21:41:12 2006
++++ gnome-volume-manager.schemas.in Wed Jun 7 21:41:40 2006
+@@ -227,7 +227,7 @@
+ <key>/schemas/desktop/gnome/volume_manager/autoprinter_command</key>
+ <applyto>/desktop/gnome/volume_manager/autoprinter_command</applyto>
+ <type>string</type>
+- <default>gnome-printer-add hal://%h</default>
++ <default>gnome-cups-add hal://%h</default>
+ <locale name="C">
+ <short>printer command</short>
+ <long>Command to run when a printer is connected.</long>
diff --git a/sysutils/gnome-volume-manager/files/patch-src_manager.c b/sysutils/gnome-volume-manager/files/patch-src_manager.c
new file mode 100644
index 000000000..13e0cbf7f
--- /dev/null
+++ b/sysutils/gnome-volume-manager/files/patch-src_manager.c
@@ -0,0 +1,232 @@
+--- src/manager.c.orig 2006-11-07 13:01:17.000000000 -0500
++++ src/manager.c 2007-10-17 00:14:10.000000000 -0400
+@@ -23,9 +23,12 @@
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <dirent.h>
++#include <fcntl.h>
+ #include <signal.h>
+ #include <unistd.h>
+ #include <utmp.h>
++#include <sys/param.h>
++#include <sys/mount.h>
+
+ #include <locale.h>
+
+@@ -1556,12 +1559,27 @@ enum {
+ MOUNT_UID = (1 << 15),
+ MOUNT_UMASK = (1 << 16),
+ MOUNT_UTF8 = (1 << 17),
++ MOUNT_LOCALE = (1 << 18),
++ MOUNT_LONGNAME = (1 << 19),
+ };
+
+ static struct {
+ const char *name;
+ guint32 flag;
+ } mount_options[] = {
++#ifdef __FreeBSD__
++ { "-D=", MOUNT_CODEPAGE }, /* vfat */
++ { "-M=", MOUNT_DMASK }, /* vfat */
++ { "-m=", MOUNT_FMASK }, /* vfat, ntfs */
++ { "-L=", MOUNT_LOCALE }, /* vfat */
++ { "-C=", MOUNT_IOCHARSET }, /* ntfs, ios9660 */
++ { "noatime", MOUNT_NOATIME },
++ { "noexec", MOUNT_NOEXEC },
++ { "ro", MOUNT_READ_ONLY },
++ { "longnames", MOUNT_LONGNAME }, /* vfat */
++ { "sync", MOUNT_SYNC },
++ { "-u=", MOUNT_UID }, /* vfat, ntfs */
++#else
+ { "codepage=", MOUNT_CODEPAGE }, /* vfat */
+ { "data=", MOUNT_DATA }, /* ext3 */
+ { "dirsync", MOUNT_DIRSYNC },
+@@ -1580,6 +1598,7 @@ static struct {
+ { "uid=", MOUNT_UID }, /* vfat, ntfs, udf, iso9660 */
+ { "umask=", MOUNT_UMASK }, /* vfat, ntfs, udf */
+ { "utf8", MOUNT_UTF8 }, /* vfat, iso9660 */
++#endif
+ };
+
+
+@@ -1760,10 +1779,17 @@ gvm_mount_options (GPtrArray *options, g
+ g_slist_free_1 (l);
+ }
+
++#ifndef __FreeBSD__
+ if (opts & MOUNT_UID) {
+ option = g_strdup_printf ("uid=%u", getuid ());
+ g_ptr_array_add (options, option);
+ }
++#else
++ if (opts & MOUNT_UID && (!strcmp (where, "vfat") || !strcmp (where, "ntfs"))) {
++ option = g_strdup_printf ("u=%u", getuid ());
++ g_ptr_array_add (options, option);
++ }
++#endif
+
+ return TRUE;
+ }
+@@ -1813,7 +1839,7 @@ gvm_device_mount (const char *udi, gbool
+
+ return retval;
+ } else {
+- char *mount_point, *fstype, *drive, **moptions, fmask_opt[12], *charset_opt = NULL;
++ char *mount_point, *fstype, *drive, **moptions, fmask_opt[12], *charset_opt = NULL, *locale_opt = NULL;
+ DBusMessage *dmesg, *reply;
+ gboolean freev = FALSE;
+ GPtrArray *options;
+@@ -1893,21 +1919,86 @@ gvm_device_mount (const char *udi, gbool
+
+ if (opts & MOUNT_FMASK) {
+ mask = umask (0);
++#ifdef __FreeBSD__
++ snprintf (fmask_opt, sizeof (fmask_opt), "-m=%#o", mask | 0111);
++#else
+ snprintf (fmask_opt, sizeof (fmask_opt), "fmask=%#o", mask | 0111);
++#endif
+ g_ptr_array_add (options, fmask_opt);
+ umask (mask);
+ }
+
+ if (opts & MOUNT_SHORTNAME)
+ g_ptr_array_add (options, "shortname=lower");
++ if (opts & MOUNT_LONGNAME)
++ g_ptr_array_add (options, "longnames");
++
++ if (opts & MOUNT_LOCALE) {
++ char *locale;
++
++ locale = setlocale(LC_ALL, NULL);
++ if (!locale)
++ locale = getenv("LANG");
++ if (locale) {
++
++ locale_opt = g_strdup_printf ("-L=%s", locale);
++ g_ptr_array_add (options, locale_opt);
++ }
++ }
++
++#ifdef __FreeBSD__
++ if (opts & MOUNT_CODEPAGE) {
++ if ((iocharset = gvm_iocharset ())) {
++ charset_opt = g_strdup_printf ("-D=%s", iocharset);
++ g_ptr_array_add (options, charset_opt);
++ }
++ }
++
++ if (opts & MOUNT_UID) {
++ snprintf (uid, sizeof (uid) - 1, "-u=%s", getuid ());
++ g_ptr_array_add (options, uid);
++ }
++#endif
+ } else if (!strcmp (fstype, "iso9660")) {
+ /* only care about uid= and iocharset= */
++#ifdef __FreeBSD__
++ if (opts & MOUNT_IOCHARSET) {
++ if ((iocharset = gvm_iocharset ())) {
++ charset_opt = g_strdup_printf ("-C=%s", iocharset);
++ g_ptr_array_add (options, charset_opt);
++ }
++ }
++#endif
+ } else if (!strcmp (fstype, "udf")) {
+ /* also care about uid= and iocharset= */
+ if (opts & MOUNT_NOATIME)
+ g_ptr_array_add (options, "noatime");
++#ifdef __FreeBSD__
++ if (opts & MOUNT_IOCHARSET) {
++ if ((iocharset = gvm_iocharset ())) {
++ charset_opt = g_strdup_printf ("-C=%s", iocharset);
++ g_ptr_array_add (options, charset_opt);
++ }
++ }
++#endif
++ } else if (!strcmp (fstype, "ntfs")) {
++ /* only care about uid= and iocharset= */
++#ifdef __FreeBSD__
++ if (opts & MOUNT_IOCHARSET) {
++ if ((iocharset = gvm_iocharset ())) {
++ charset_opt = g_strdup_printf ("-C=%s", iocharset);
++ g_ptr_array_add (options, charset_opt);
++ }
++ }
++
++ if (opts & MOUNT_UID) {
++ snprintf (uid, sizeof (uid) - 1, "-u=%s", getuid ());
++ g_ptr_array_add (options, uid);
++ }
++#endif
+ }
+
++#ifndef __FreeBSD__
+ if (opts & (MOUNT_IOCHARSET|MOUNT_UTF8)) {
+ if ((iocharset = gvm_iocharset ())) {
+ if ((opts & MOUNT_UTF8) && !strcmp (iocharset, "utf8")) {
+@@ -1923,6 +2014,7 @@ gvm_device_mount (const char *udi, gbool
+ snprintf (uid, sizeof (uid) - 1, "uid=%u", getuid ());
+ g_ptr_array_add (options, uid);
+ }
++#endif
+
+ libhal_free_string (fstype);
+ }
+@@ -1947,6 +2039,7 @@ gvm_device_mount (const char *udi, gbool
+
+ g_ptr_array_free (options, TRUE);
+ g_free (charset_opt);
++ g_free (locale_opt);
+
+ policy = g_new (struct _MountPolicy, 1);
+ policy->udi = g_strdup (udi);
+@@ -3185,6 +3278,12 @@ gvm_local_user (void)
+ size_t n;
+ DIR *dir;
+ int vt;
++#ifndef __linux__
++ int bytes, fd;
++ struct stat sb;
++ struct utmp buf[1024];
++ size_t len;
++#endif
+
+ if (local & LOCAL_USER_CHECKED)
+ return (local & LOCAL_USER_FOUND);
+@@ -3208,6 +3307,7 @@ gvm_local_user (void)
+
+ fallback:
+
++#ifdef __linux__
+ if (!(local & LOCAL_USER_FOUND)) {
+ setutent ();
+
+@@ -3222,6 +3322,29 @@ gvm_local_user (void)
+
+ endutent ();
+ }
++#else
++ if ((fd = open (_PATH_UTMP, O_RDONLY, 0)) < 0 || fstat(fd, &sb) == -1) {
++ close (fd);
++ return TRUE;
++ }
++
++ len = (sb.st_size + sizeof(buf) - 1) / sizeof(buf);
++
++ while (!local && len-- > 0) {
++ if (lseek(fd, (off_t) (len * sizeof(buf)), L_SET) == -1 ||
++ (bytes = read (fd, buf, sizeof(buf))) == -1) {
++ close (fd);
++ return TRUE;
++ }
++ for (utmp = &buf[bytes / sizeof(buf[0]) - 1]; !local && utmp >= buf; --utmp) {
++ if (!utmp->ut_name[0] || strncmp (utmp->ut_name, user, n) != 0)
++ continue;
++ local = utmp->ut_host[0] == ':' && utmp->ut_host[1] >= '0' && utmp->ut_host[1] <= '9' || !strncmp (utmp->ut_line, "ttyv", 4) ? LOCAL_USER_FOUND : 0;
++ }
++ }
++
++ close (fd);
++#endif
+
+ local |= LOCAL_USER_CHECKED;
+
diff --git a/sysutils/gnome-volume-manager/pkg-descr b/sysutils/gnome-volume-manager/pkg-descr
new file mode 100644
index 000000000..b8ce9b768
--- /dev/null
+++ b/sysutils/gnome-volume-manager/pkg-descr
@@ -0,0 +1,3 @@
+gnome-volume-manager is a desktop-level daemon that enforces volume-related
+policy in response to events received from HAL. Its goal is to implement all
+functionality as a state-machine in response to asynchronous events from HAL.
diff --git a/sysutils/gnome-volume-manager/pkg-plist b/sysutils/gnome-volume-manager/pkg-plist
new file mode 100644
index 000000000..0670eafa0
--- /dev/null
+++ b/sysutils/gnome-volume-manager/pkg-plist
@@ -0,0 +1,95 @@
+etc/xdg/autostart/gnome-volume-manager.desktop
+bin/gnome-volume-properties
+libexec/gnome-volume-manager
+share/applications/gnome-volume-properties.desktop
+share/gnome-volume-manager/gnome-volume-properties.glade
+share/locale/ang/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ar/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/az/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/be@latin/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/bg/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/bn/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/bn_IN/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/bs/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ca/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/cs/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/cy/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/da/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/de/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/dz/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/el/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/en_CA/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/en_GB/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/es/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/et/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/eu/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/fa/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/fi/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/fr/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/gl/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/gu/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/he/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/hi/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/hr/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/hu/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/id/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/is/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/it/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ja/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ka/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ko/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ku/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/lt/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/lv/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/oc/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/mg/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/mk/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ml/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/mn/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ms/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/nb/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ne/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/nl/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/nn/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/or/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/pa/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/pl/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/pt/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/pt_BR/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ro/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ru/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/rw/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/si/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/sk/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/sl/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/sq/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/sr/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/sr@Latn/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/sv/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/te/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/ta/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/th/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/tr/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/uk/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/vi/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/xh/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/zh_CN/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/zh_HK/LC_MESSAGES/gnome-volume-manager.mo
+share/locale/zh_TW/LC_MESSAGES/gnome-volume-manager.mo
+@dirrmtry share/locale/zh_HK/LC_MESSAGES
+@dirrmtry share/locale/zh_HK
+@dirrmtry share/locale/xh/LC_MESSAGES
+@dirrmtry share/locale/xh
+@dirrmtry share/locale/rw/LC_MESSAGES
+@dirrmtry share/locale/rw
+@dirrmtry share/locale/mg/LC_MESSAGES
+@dirrmtry share/locale/mg
+@dirrmtry share/locale/ku/LC_MESSAGES
+@dirrmtry share/locale/ku
+@dirrmtry share/locale/dz/LC_MESSAGES
+@dirrmtry share/locale/dz
+@dirrmtry share/locale/bn_IN/LC_MESSAGES
+@dirrmtry share/locale/bn_IN
+@dirrmtry share/locale/ang/LC_MESSAGES
+@dirrmtry share/locale/ang
+@dirrmtry share/applications