]> git.pld-linux.org Git - packages/device-mapper.git/commitdiff
- obsolete for long time master
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Tue, 3 Aug 2010 12:14:21 +0000 (12:14 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    device-mapper-dmsetup-export.patch -> 1.2
    device-mapper-force-local-headers.patch -> 1.2
    device-mapper-getopt.patch -> 1.5
    device-mapper-klibc.patch -> 1.10
    device-mapper-linking.patch -> 1.3

device-mapper-dmsetup-export.patch [deleted file]
device-mapper-force-local-headers.patch [deleted file]
device-mapper-getopt.patch [deleted file]
device-mapper-klibc.patch [deleted file]
device-mapper-linking.patch [deleted file]

diff --git a/device-mapper-dmsetup-export.patch b/device-mapper-dmsetup-export.patch
deleted file mode 100644 (file)
index 1797403..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-diff --git a/dmsetup/dmsetup.c b/dmsetup/dmsetup.c
-index 25f14a6..b693008 100644
---- a/dmsetup/dmsetup.c
-+++ b/dmsetup/dmsetup.c
-@@ -995,6 +995,94 @@ static int _status(int argc, char **argv
-       return r;
- }
-+static int _export(int argc, char **argv, void *data)
-+{
-+      int r = 0;
-+      struct dm_task *dmt = NULL;
-+      void *next = NULL;
-+      uint64_t start, length;
-+      char *target_type = NULL;
-+      char *params;
-+      struct dm_names *names = (struct dm_names *) data;
-+      const char *name = NULL;
-+      const char *uuid = NULL;
-+      struct dm_info info;
-+
-+      if (data)
-+              name = names->name;
-+      else if (argc == 2)
-+              name = argv[1];
-+
-+      if (!(dmt = dm_task_create(DM_DEVICE_STATUS)))
-+              goto out;
-+
-+      if (!_set_task_device(dmt, name, 0))
-+              goto out;
-+
-+      if (!dm_task_run(dmt))
-+              goto out;
-+
-+      if (!dm_task_get_info(dmt, &info) || !info.exists)
-+              goto out;
-+
-+      if (!name)
-+              name = dm_task_get_name(dmt);
-+
-+      uuid = dm_task_get_uuid(dmt);
-+      printf("DM_NAME=%s\n", name);
-+
-+      if ((uuid = dm_task_get_uuid(dmt)) && *uuid)
-+              printf("DM_UUID=%s\n", uuid);
-+
-+      if (!info.exists) {
-+              printf("DM_STATE=NOTPRESENT\n");
-+              goto out;
-+      }
-+
-+      printf("DM_STATE=%s\n",
-+             info.suspended ? "SUSPENDED" :
-+             (info.read_only ? " READONLY" : "ACTIVE"));
-+
-+      if (!info.live_table && !info.inactive_table)
-+              printf("DM_TABLE_STATE=NONE\n");
-+      else
-+              printf("DM_TABLE_STATE=%s%s%s\n",
-+                     info.live_table ? "LIVE" : "",
-+                     info.live_table && info.inactive_table ? "/" : "",
-+                     info.inactive_table ? "INACTIVE" : "");
-+
-+      if (info.open_count != -1)
-+              printf("DM_OPENCOUNT=%d\n", info.open_count);
-+
-+      printf("DM_LAST_EVENT_NR=%" PRIu32 "\n", info.event_nr);
-+
-+      printf("DM_MAJOR=%d\n", info.major);
-+      printf("DM_MINOR=%d\n", info.minor);
-+
-+      if (info.target_count != -1)
-+              printf("DM_TARGET_COUNT=%d\n", info.target_count);
-+
-+      /* export all table types */
-+      next = dm_get_next_target(dmt, next, &start, &length,
-+                                &target_type, &params);
-+      if (target_type) {
-+              printf("DM_TARGET_TYPES=%s", target_type);
-+              while (next) {
-+                      next = dm_get_next_target(dmt, next, &start, &length,
-+                                                &target_type, &params);
-+                      if (target_type)
-+                              printf(",%s", target_type);
-+              }
-+              printf("\n");
-+      }
-+
-+      r = 1;
-+      out:
-+      if (dmt)
-+              dm_task_destroy(dmt);
-+      return r;
-+}
-+
- /* Show target names and their version numbers */
- static int _targets(int argc __attribute((unused)), char **argv __attribute((unused)), void *data __attribute((unused)))
- {
-@@ -1699,6 +1787,7 @@ static struct command _commands[] = {
-       {"info", "[<device>]", 0, 1, _info},
-       {"deps", "[<device>]", 0, 1, _deps},
-       {"status", "[<device>] [--target <target_type>]", 0, 1, _status},
-+      {"export", "[<device>]", 0, 1, _export},
-       {"table", "[<device>] [--target <target_type>] [--showkeys]", 0, 1, _status},
-       {"wait", "<device> [<event_nr>]", 0, 2, _wait},
-       {"mknodes", "[<device>]", 0, 1, _mknodes},
-diff --git a/man/dmsetup.8 b/man/dmsetup.8
-index 5b2ed9f..c4524aa 100644
---- a/man/dmsetup.8
-+++ b/man/dmsetup.8
-@@ -39,13 +39,16 @@ dmsetup \- low level logical volume mana
- .B dmsetup ls
- .I [--target target_type] [--exec command] [--tree [-o options]]
- .br
--.B dmsetup info 
-+.B dmsetup info
- .I [device_name]
- .br
- .B dmsetup info -c|-C|--columns
- .I [--noheadings] [--separator separator] [-o fields] [-O|--sort sort_fields]
- .I [device_name]
- .br
-+.B dmsetup export
-+.I [device_name]
-+.br
- .B dmsetup deps
- .I [device_name]
- .br
-@@ -138,6 +141,10 @@ device_name in subsequent dmsetup comman
- If successful a device will appear as
- /dev/device-mapper/<device-name>.  
- See below for information on the table format.
-+.IP \fBexport
-+.I [device_name]
-+.br
-+Outputs information in key/value format to be imported by other programs.
- .IP \fBdeps
- .I [device_name]
- .br
diff --git a/device-mapper-force-local-headers.patch b/device-mapper-force-local-headers.patch
deleted file mode 100644 (file)
index 061de36..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -Nur device-mapper.1.02.08/lib/ioctl/libdm-iface.c device-mapper.1.02.08.force-local-headers/lib/ioctl/libdm-iface.c
---- device-mapper.1.02.08/lib/ioctl/libdm-iface.c      2006-08-02 01:59:16.000000000 +0200
-+++ device-mapper.1.02.08.force-local-headers/lib/ioctl/libdm-iface.c  2006-08-02 01:59:17.000000000 +0200
-@@ -36,7 +36,7 @@
- #  define MKDEV(x,y) makedev((x),(y))
- #endif
--#include <linux/dm-ioctl.h>
-+#include "../../kernel/ioctl/dm-ioctl.h"
- /*
-  * Ensure build compatibility.  
diff --git a/device-mapper-getopt.patch b/device-mapper-getopt.patch
deleted file mode 100644 (file)
index ee5c672..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
---- device-mapper.1.02.07/configure.in.orig    2006-05-17 19:23:21.778894500 +0200
-+++ device-mapper.1.02.07/configure.in 2006-05-17 19:31:56.351053250 +0200
-@@ -230,8 +230,8 @@
- ################################################################################
- dnl -- getline included in recent libc
--AC_CHECK_LIB(c, getline, AC_DEFINE([HAVE_GETLINE], 1,
--  [Define to 1 if getline is available.]))
-+AC_CHECK_FUNC(getline, [AC_DEFINE([HAVE_GETLINE], 1,
-+  [Define to 1 if getline is available.])])
- ################################################################################
- dnl -- canonicalize_file_name included in recent libc
-@@ -240,7 +240,7 @@
- ################################################################################
- dnl -- Check for getopt
--AC_CHECK_HEADERS(getopt.h, AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getopt_long is available.]))
-+AC_CHECK_FUNC(getopt_long, [AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getopt_long is available.])])
- ################################################################################
- dnl -- Internationalisation stuff
diff --git a/device-mapper-klibc.patch b/device-mapper-klibc.patch
deleted file mode 100644 (file)
index c4eea77..0000000
+++ /dev/null
@@ -1,150 +0,0 @@
---- device-mapper/configure.in~        2008-07-06 19:22:49.965050005 +0200
-+++ device-mapper/configure.in 2008-07-06 19:26:11.998363857 +0200
-@@ -107,7 +107,7 @@
- ################################################################################
- dnl -- Check for functions
--AC_CHECK_FUNCS([gethostname getpagesize memset mkdir rmdir munmap setlocale \
-+AC_CHECK_FUNCS([gethostname memset mkdir rmdir munmap \
-   strcasecmp strchr strdup strncasecmp strerror strrchr strstr strtol strtoul \
-   uname], , [AC_MSG_ERROR(bailing out)])
- AC_FUNC_ALLOCA
---- device-mapper.1.02.09.orig/configure.in    2006-09-27 18:22:22.000000000 +0000
-+++ device-mapper.1.02.09.klibc/configure.in   2006-09-27 18:22:22.000000000 +0000
-@@ -87,7 +87,7 @@
- AC_HEADER_SYS_WAIT
- AC_HEADER_TIME
--AC_CHECK_HEADERS([ctype.h dirent.h errno.h fcntl.h getopt.h inttypes.h limits.h \
-+AC_CHECK_HEADERS([ctype.h dirent.h errno.h fcntl.h inttypes.h limits.h \
-   stdarg.h stdio.h stdlib.h string.h sys/ioctl.h sys/param.h sys/stat.h \
-   sys/types.h unistd.h], , [AC_MSG_ERROR(bailing out)])
- AC_CHECK_HEADERS(termios.h sys/statvfs.h)
---- device-mapper.1.02.09.orig/dmsetup/dmsetup.c       2006-08-10 20:53:21.000000000 +0000
-+++ device-mapper.1.02.09.klibc/dmsetup/dmsetup.c      2006-09-27 18:22:58.000000000 +0000
-@@ -31,12 +31,13 @@
- #include <dirent.h>
- #include <errno.h>
- #include <unistd.h>
--#include <libgen.h>
- #include <sys/wait.h>
- #include <unistd.h>
- #include <sys/param.h>
-+#ifndef __KLIBC__
- #include <locale.h>
- #include <langinfo.h>
-+#endif
- #ifdef HAVE_SYS_IOCTL_H
- #  include <sys/ioctl.h>
-@@ -1547,9 +1548,11 @@
-       int len;
-       /* Symbol set default */
-+#ifndef __KLIBC__
-       if (!strcmp(nl_langinfo(CODESET), "UTF-8"))
-               _tsym = &_tsym_utf;
-       else
-+#endif
-               _tsym = &_tsym_ascii;
-       /* Default */
-@@ -1647,7 +1650,9 @@
-       memset(&_values, 0, sizeof(_values));
-       namebase = strdup((*argv)[0]);
--      base = basename(namebase);
-+      base = strrchr(namebase,'/');
-+      if (base != NULL) *base++ = 0;
-+      else base = namebase;
-       if (!strcmp(base, "devmap_name")) {
-               free(namebase);
-@@ -1783,7 +1788,9 @@
-       struct command *c;
-       int r = 1;
-+#ifndef __KLIBC__
-       (void) setlocale(LC_ALL, "");
-+#endif
-       if (!_process_switches(&argc, &argv)) {
-               fprintf(stderr, "Couldn't process command line.\n");
---- device-mapper.1.02.22/lib/ioctl/libdm-iface.c.orig 2007-08-21 18:26:07.000000000 +0200
-+++ device-mapper.1.02.22/lib/ioctl/libdm-iface.c      2007-09-09 23:59:33.337996036 +0200
-@@ -134,17 +134,25 @@
-                           uint32_t *number)
- {
-       FILE *fl;
--      char nm[256];
-+      char nm[256], buf[300];
-       int c;
--      uint32_t num;
-+      uint32_t num, size;
-       if (!(fl = fopen(file, "r"))) {
-               log_sys_error("fopen", file);
-               return 0;
-       }
--      while (!feof(fl)) {
--              if (fscanf(fl, "%d %255s\n", &num, &nm[0]) == 2) {
-+      /* Use fread+sscanf for klibc compatibility. */
-+      do {
-+              size = 0;
-+              do {
-+                      num = fread(&buf[size], sizeof(char), 1, fl);
-+                      if (num > 0)
-+                              size++;
-+              } while (num > 0 && buf[size - 1] != '\n');
-+              buf[size] = '\0';
-+              if (sscanf(buf, "%d %255s\n", &num, &nm[0]) == 2) {
-                       if (!strcmp(name, nm)) {
-                               if (number) {
-                                       *number = num;
-@@ -154,10 +162,9 @@
-                               }
-                               dm_bit_set(_dm_bitset, num);
-                       }
--              } else do {
--                      c = fgetc(fl);
--              } while (c != EOF && c != '\n');
--      }
-+              }
-+      } while (size > 0);
-+      
-       if (fclose(fl))
-               log_sys_error("fclose", file);
---- device-mapper.1.02.22/lib/libdm-file.c.orig        2007-08-21 18:26:06.000000000 +0200
-+++ device-mapper.1.02.22/lib/libdm-file.c     2007-09-10 00:20:00.475926641 +0200
-@@ -15,10 +15,16 @@
- #include "lib.h"
--#include <sys/file.h>
- #include <fcntl.h>
- #include <dirent.h>
-+#ifndef __KLIBC__
-+#  include <sys/file.h>
-+#  ifdef linux
-+#    include <malloc.h>
-+#  endif
-+#endif
-+
- static int _create_dir_recursive(const char *dir)
- {
-       char *orig, *s;
-@@ -73,7 +79,11 @@
- int dm_fclose(FILE *stream)
- {
-+#ifdef __KLIBC__
-+      int prev_fail = 0;
-+#else
-       int prev_fail = ferror(stream);
-+#endif
-       int fclose_fail = fclose(stream);
-       /* If there was a previous failure, but fclose succeeded,
diff --git a/device-mapper-linking.patch b/device-mapper-linking.patch
deleted file mode 100644 (file)
index f46707c..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
---- device-mapper.1.02.09/dmeventd/Makefile.in~ 2006-04-19 17:32:05.000000000 +0000
-+++ device-mapper.1.02.09/dmeventd/Makefile.in  2006-09-27 14:15:09.000000000 +0000
-@@ -31,7 +31,7 @@
- include ../make.tmpl
-
- LDFLAGS += -ldl -ldevmapper -lpthread
--CLDFLAGS += -ldl -ldevmapper -lpthread
-+LIBS += -ldl ../lib/ioctl/libdevmapper.so -lpthread
-
- dmeventd: $(LIB_SHARED) dmeventd.o
-        $(CC) -o $@ dmeventd.o $(CFLAGS) $(LDFLAGS) \
This page took 0.084411 seconds and 4 git commands to generate.