fedora-cvs-commits@redhat.com
[Top] [All Lists]

rpms/dmraid/devel dmraid-1.0.0.rc9-counts.patch, NONE, 1.1 dmraid-1.0.0.

Subject: rpms/dmraid/devel dmraid-1.0.0.rc9-counts.patch, NONE, 1.1 dmraid-1.0.0.rc9-destdir.patch, NONE, 1.1 dmraid-1.0.0.rc9-dupes.patch, NONE, 1.1 dmraid-1.0.0.rc9-exports.patch, NONE, 1.1 dmraid-1.0.0.rc9-install.patch, NONE, 1.1 dmraid-1.0.0.rc9-selinux.patch, NONE, 1.1 dmraid-1.0.0.rc9-table.patch, NONE, 1.1 .cvsignore, 1.6, 1.7 dmraid.spec, 1.25, 1.26 sources, 1.13, 1.14
From:
Date: Thu, 10 Nov 2005 17:08:12 -0500
Author: pjones

Update of /cvs/dist/rpms/dmraid/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv12563

Modified Files:
        .cvsignore dmraid.spec sources 
Added Files:
        dmraid-1.0.0.rc9-counts.patch dmraid-1.0.0.rc9-destdir.patch 
        dmraid-1.0.0.rc9-dupes.patch dmraid-1.0.0.rc9-exports.patch 
        dmraid-1.0.0.rc9-install.patch dmraid-1.0.0.rc9-selinux.patch 
        dmraid-1.0.0.rc9-table.patch 
Log Message:
- update to 1.0.0.rc9
- add dmraid-devel


dmraid-1.0.0.rc9-counts.patch:
 include/dmraid/metadata.h |    2 ++
 lib/format/format.c       |    4 +++-
 2 files changed, 5 insertions(+), 1 deletion(-)

--- NEW FILE dmraid-1.0.0.rc9-counts.patch ---
--- dmraid/1.0.0.rc9/include/dmraid/metadata.h.counts   2005-11-09 
16:51:26.000000000 -0500
+++ dmraid/1.0.0.rc9/include/dmraid/metadata.h  2005-11-09 16:55:50.000000000 
-0500
@@ -180,6 +180,8 @@
         * for arbitrary block devices here.
         */
        struct list_head devs;
+       unsigned int total_devs;        /* The number of devices expected */
+       unsigned int found_devs;        /* The number of devices found */
 
        char *name;                     /* Name of the set. */
 
--- dmraid/1.0.0.rc9/lib/format/format.c.counts 2005-11-09 16:54:37.000000000 
-0500
+++ dmraid/1.0.0.rc9/lib/format/format.c        2005-11-09 16:55:31.000000000 
-0500
@@ -261,7 +261,9 @@
                return;
 
        sectors = total_sectors(lc, rs);
-       devs = count_devs(lc, rs, ct_dev);
+       rs->total_devs = devs = count_devs(lc, rs, ct_dev);
        list_for_each_entry(rd, &rs->devs, devs) {
                unsigned int devices = f_devices(rd, f_devices_context);
+               /* FIXME: error if the metadatas aren't all the same? */
+               rs->found_devs = devices;
 

dmraid-1.0.0.rc9-destdir.patch:
 make.tmpl.in |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

--- NEW FILE dmraid-1.0.0.rc9-destdir.patch ---
--- dmraid/1.0.0.rc9/make.tmpl.in.destdir       2005-10-13 16:37:28.000000000 
-0400
+++ dmraid/1.0.0.rc9/make.tmpl.in       2005-10-13 16:36:52.000000000 -0400
@@ -28,14 +28,16 @@
   libdir = @libdir@
   sbindir = @sbindir@
   includedir = @includedir@
+  infodir = @infodir@
+  mandir = @mandir@
 else
   libdir = $(DESTDIR)@KLIBC_LIB_DIR@
   sbindir = $(DESTDIR)@KLIBC_SBIN_DIR@
   includedir = $(DESTDIR)@KLIBC_INCLUDE_DIR@
+  infodir = @infodir@
+  mandir = @mandir@
 endif
 
-infodir = $(DESTDIR)@infodir@
-mandir = $(DESTDIR)@mandir@
 
 # setup misc variables
 # define the ownership variables for the binaries and man pages

dmraid-1.0.0.rc9-dupes.patch:
 dmraid.h |    6 +-----
 1 files changed, 1 insertion(+), 5 deletions(-)

--- NEW FILE dmraid-1.0.0.rc9-dupes.patch ---
--- dmraid/1.0.0.rc9/include/dmraid/dmraid.h.dupes      2005-10-13 
15:07:39.000000000 -0400
+++ dmraid/1.0.0.rc9/include/dmraid/dmraid.h    2005-10-13 15:07:56.000000000 
-0400
@@ -16,6 +16,7 @@
 #include <dmraid/lib_context.h>
 #include <dmraid/display.h>
 #include <dmraid/format.h>
+#include <dmraid/metadata.h>
 
 /*
  * Library init/exit
@@ -55,11 +56,6 @@
 extern const char *get_set_name(struct lib_context *lc, void *rs);
 extern int group_set(struct lib_context *lc, char *name);
 
-enum set_type {
-       SETS,
-       PARTITIONS,
-};
-
 enum activate_type {
        A_ACTIVATE,
        A_DEACTIVATE,

dmraid-1.0.0.rc9-exports.patch:
 .export.sym |   10 ++++++++++
 1 files changed, 10 insertions(+)

--- NEW FILE dmraid-1.0.0.rc9-exports.patch ---
--- dmraid/1.0.0.rc9/lib/.export.sym.exports    2005-11-09 17:23:45.000000000 
-0500
+++ dmraid/1.0.0.rc9/lib/.export.sym    2005-11-09 17:25:05.000000000 -0500
@@ -5,6 +5,8 @@
                check_valid_format;
                collapse_delimiter;
                count_devices;
+               count_devs;
+               count_sets;
                _dbg_free;
                _dbg_malloc;
                _dbg_realloc;
@@ -17,11 +19,18 @@
                dm_version;
                erase_metadata;
                find_set;
+               get_dm_type;
                get_set_type;
                get_set_name;
+               get_status;
+               get_type;
                group_set;
                init_locking;
                lc_inc_opt;
+               lc_list;
+               lc_opt;
+               lc_stralloc_opt;
+               lc_strcat_opt;
                libdmraid_exit;
                libdmraid_init;
                libdmraid_date;
@@ -33,6 +42,7 @@
                process_sets;
                remove_delimiter;
                remove_white_space;
+               total_sectors;
                unlock_resource;
 
        local:

dmraid-1.0.0.rc9-install.patch:
 Makefile.in |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)

--- NEW FILE dmraid-1.0.0.rc9-install.patch ---
--- dmraid/1.0.0.rc9/lib/Makefile.in.install    2005-10-13 14:38:40.000000000 
-0400
+++ dmraid/1.0.0.rc9/lib/Makefile.in    2005-10-13 14:39:32.000000000 -0400
@@ -63,9 +63,14 @@
        for f in $(INSTALL_TARGETS); \
        do \
                n=$$(basename $${f}) ; \
-               $(INSTALL) -o $(OWNER) -g $(GROUP) -m 555 $(STRIP) \
-               $$f $(libdir)/$${n}.@DMRAID_LIB_VERSION@; \
-               $(LN_S) -f $${n}.@DMRAID_LIB_VERSION@ $(libdir)/$${n}; \
+               if [[ "$$n" =~ '.so$$' ]]; then \
+                       $(INSTALL) -o $(OWNER) -g $(GROUP) -m 555 $(STRIP) \
+                               $$f $(libdir)/$${n}.@DMRAID_LIB_VERSION@; \
+                       $(LN_S) -f $${n}.@DMRAID_LIB_VERSION@ $(libdir)/$${n}; \
+               else \
+                       $(INSTALL) -o $(OWNER) -g $(GROUP) -m 555 $(STRIP) \
+                               $$f $(libdir)/$${n}; \
+               fi \
        done
 
 install: install_dmraid_libs

dmraid-1.0.0.rc9-selinux.patch:
 Makefile.in |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

--- NEW FILE dmraid-1.0.0.rc9-selinux.patch ---
--- dmraid/1.0.0.rc9/tools/Makefile.in.selinux  2005-10-13 13:25:13.000000000 
-0400
+++ dmraid/1.0.0.rc9/tools/Makefile.in  2005-10-13 13:25:24.000000000 -0400
@@ -33,7 +33,7 @@
                DMRAIDLIBS += -ldevmapper
        endif
 
-       DMRAIDLIBS += -lselinux
+       DMRAIDLIBS += -lselinux -lsepol
 endif
 
 # We just link klibc static and get it over with

dmraid-1.0.0.rc9-table.patch:
 include/dmraid/dmraid.h |    1 +
 lib/.export.sym         |    1 +
 lib/activate/activate.c |   20 ++++++++++++++++++++
 3 files changed, 22 insertions(+)

--- NEW FILE dmraid-1.0.0.rc9-table.patch ---
--- dmraid/1.0.0.rc9/include/dmraid/dmraid.h.table      2005-10-31 
15:17:28.000000000 -0500
+++ dmraid/1.0.0.rc9/include/dmraid/dmraid.h    2005-10-31 15:17:28.000000000 
-0500
@@ -55,6 +55,7 @@
 extern const char *get_set_type(struct lib_context *lc, void *rs);
 extern const char *get_set_name(struct lib_context *lc, void *rs);
 extern int group_set(struct lib_context *lc, char *name);
+extern char *libdmraid_make_table(struct lib_context *lc, struct raid_set *rs);
 
 enum activate_type {
        A_ACTIVATE,
--- dmraid/1.0.0.rc9/lib/.export.sym.table      2005-05-24 06:56:05.000000000 
-0400
+++ dmraid/1.0.0.rc9/lib/.export.sym    2005-11-03 15:08:46.000000000 -0500
@@ -34,8 +34,9 @@
                libdmraid_exit;
                libdmraid_init;
                libdmraid_date;
                libdmraid_version;
+               libdmraid_make_table;
                list_formats;
                lock_resource;
                log_alloc_err;
                plog;
--- dmraid/1.0.0.rc9/lib/activate/activate.c.table      2005-09-21 
09:55:44.000000000 -0400
+++ dmraid/1.0.0.rc9/lib/activate/activate.c    2005-11-03 17:54:56.000000000 
-0500
@@ -474,6 +474,26 @@
        return do_device(lc, rs, dm_unregister_for_event);
 }
 
+char *libdmraid_make_table(struct lib_context *lc, struct raid_set *rs)
+{
+       char *table = NULL;
+       char *ret;
+       struct type_handler *h;
+
+       if (T_GROUP(rs))
+               return NULL;
+
+       h = handler(rs);
+
+       if (!h->f(lc, &table, rs)) {
+               log_err(lc, "no mapping possible for RAID set %s", rs->name);
+               return NULL;
+       }
+       ret = strdup(table);
+       free_string(lc, &table);
+       return ret;
+}
+
 /* Activate a single set. */
 static int activate_subset(struct lib_context *lc, struct raid_set *rs,
                           enum dm_what what)


Index: .cvsignore
===================================================================
RCS file: /cvs/dist/rpms/dmraid/devel/.cvsignore,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- .cvsignore  19 May 2005 14:53:27 -0000      1.6
+++ .cvsignore  10 Nov 2005 22:08:09 -0000      1.7
@@ -1,4 +1 @@
-dmraid-1.0.0-rc5f.tar.bz2
-dmraid-1.0.0.rc6.tar.bz2
-dmraid-1.0.0.rc7.tar.bz2
-dmraid-1.0.0.rc8.tar.bz2
+dmraid-1.0.0.rc9.tar.bz2


Index: dmraid.spec
===================================================================
RCS file: /cvs/dist/rpms/dmraid/devel/dmraid.spec,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- dmraid.spec 15 Oct 2005 13:14:32 -0000      1.25
+++ dmraid.spec 10 Nov 2005 22:08:09 -0000      1.26
@@ -6,48 +6,78 @@
 
 Summary: dmraid (Device-mapper RAID tool and library)
 Name: dmraid
-Version: 1.0.0.rc8
-Release: FC4_6
+Version: 1.0.0.rc9
+Release: FC5_2
 License: GPL
 Group: System Environment/Base
 URL: http://people.redhat.com/heinzm/sw/dmraid
-Source: dmraid-%{version}.tar.bz2
-Patch1: dmraid-selinux.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
 BuildRequires: device-mapper
-# Patch0: maybelater.patch
+Source: ftp://people.redhat.com/heinzm/sw/dmraid/src/dmraid-%{version}.tar.bz2
+Patch0: dmraid-1.0.0.rc9-selinux.patch
+Patch1: dmraid-1.0.0.rc9-install.patch
+Patch2: dmraid-1.0.0.rc9-dupes.patch
+Patch3: dmraid-1.0.0.rc9-exports.patch
+Patch4: dmraid-1.0.0.rc9-table.patch
+Patch5: dmraid-1.0.0.rc9-destdir.patch
+Patch6: dmraid-1.0.0.rc9-counts.patch
 
-ExcludeArch:   alpha
-ExcludeArch:   ia64
-ExcludeArch:   ppc
-ExcludeArch:   ppc64
 ExcludeArch:   s390
 ExcludeArch:   s390x
 
+%define dmraid_build_dso 0
+
 %description
 DMRAID supports RAID device discovery, RAID set activation and display of
 properties for ATARAID on Linux >= 2.4 using device-mapper.
 
+%package -n dmraid-devel
+Summary: Development libraries and headers for dmraid.
+Group: Development/Libraries
+
+%description -n dmraid-devel
+dmraid-devel provides a library interface for RAID device discovery,
+RAID set activation and display of properties for ATARAID volumes.
+
 %prep
 %setup -q -n dmraid/%{version}
-%patch1 -p2
+%patch0 -p2 -b .selinux
+%patch1 -p2 -b .install
+%patch2 -p2 -b .dupes
+%patch3 -p2 -b .exports
+%patch4 -p2 -b .table
+%patch5 -p2 -b .destdir
+%patch6 -p2 -b .counts
 
 %build
-%configure --prefix=${RPM_BUILD_ROOT}/usr --sbindir=${RPM_BUILD_ROOT}/sbin 
--libdir=${RPM_BUILD_ROOT}/%{_lib} --mandir=${RPM_BUILD_ROOT}/%{_mandir} 
--enable-debug --enable-static_link
+%configure --prefix=${RPM_BUILD_ROOT}/usr --sbindir=${RPM_BUILD_ROOT}/sbin 
--libdir=${RPM_BUILD_ROOT}/%{_libdir} --mandir=${RPM_BUILD_ROOT}/%{_mandir} 
--includedir=${RPM_BUILD_ROOT}/%{_includedir} --enable-debug 
--enable-static_link
 make DESTDIR=$RPM_BUILD_ROOT
 mv tools/dmraid tools/dmraid.static
 make clean
-%configure --prefix=${RPM_BUILD_ROOT}/usr --sbindir=${RPM_BUILD_ROOT}/sbin 
--libdir=${RPM_BUILD_ROOT}/%{_lib} --mandir=${RPM_BUILD_ROOT}/%{_mandir} 
--enable-debug
+%configure --prefix=${RPM_BUILD_ROOT}/usr --sbindir=${RPM_BUILD_ROOT}/sbin 
--libdir=${RPM_BUILD_ROOT}/%{_libdir} --mandir=${RPM_BUILD_ROOT}/%{_mandir} 
--includedir=${RPM_BUILD_ROOT}/%{_includedir} --enable-debug 
--disable-static_link
+%if "%{dmraid_build_dso}" == "1"
+(cd lib ; make DESTDIR=$RPM_BUILD_ROOT libdmraid.so)
+make DESTDIR=$RPM_BUILD_ROOT
+%else
 make DESTDIR=$RPM_BUILD_ROOT
+%endif
 
 %install
 rm -rf $RPM_BUILD_ROOT
-mkdir -p $RPM_BUILD_ROOT{%{_libdir},/sbin,%{_sbindir},%{_bindir},/%{_lib}}
+install -m 755 -d 
$RPM_BUILD_ROOT{%{_libdir},/sbin,%{_sbindir},%{_bindir},%{_libdir},%{_includedir}/dmraid/,/var/lock/dmraid}
 make DESTDIR=$RPM_BUILD_ROOT install
-
-# install static version
 install -m 755 tools/dmraid.static $RPM_BUILD_ROOT/sbin/dmraid.static
-rm -f $RPM_BUILD_ROOT/%{_lib}/lib*.a.*
+install -m 644 include/dmraid/*.h $RPM_BUILD_ROOT%{_includedir}/dmraid/
+
+# install the static library
+install -m 755 lib/libdmraid.a $RPM_BUILD_ROOT%{_libdir}
+
+# if requested, install the dso
+%if "%{dmraid_build_dso}" == "1"
+install -m 755 lib/libdmraid.so \
+       $RPM_BUILD_ROOT%{_libdir}/libdmraid.so.%{version}
+(cd $RPM_BUILD_ROOT/%{_libdir} ; ln -sf libdmraid.so.%{version} libdmraid.so)
+%endif
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -57,8 +87,31 @@
 %doc CHANGELOG CREDITS KNOWN_BUGS LICENSE LICENSE_GPL LICENSE_LGPL README TODO
 /%{_mandir}/man8/*
 /sbin/*
+%if "%{dmraid_build_dso}" == "1"
+%{_libdir}/libdmraid.so.*
+%endif
+
+%files -n dmraid-devel
+%defattr(-,root,root)
+%dir %{_includedir}/dmraid
+%{_includedir}/dmraid/*
+%{_libdir}/libdmraid.a
+
+%if "%{dmraid_build_dso}" == "1"
+%{_libdir}/libdmraid.so
+%endif
 
 %changelog
+* Thu Nov 10 2005 Peter Jones <pjones@xxxxxxxxxx> 1.0.0.rc9-FC5_2
+- update to 1.0.0.rc9
+- make "make install" do the right thing with the DSO
+- eliminate duplicate definitions in the headers
+- export more symbols in the DSO
+- add api calls to retrieve dm tables
+- fix DESTDIR for 'make install' 
+- add api calls to identify degraded devices
+- remove several arch excludes
+
 * Sat Oct 15 2005 Florian La Roche <laroche@xxxxxxxxxx>
 - add -lselinux -lsepol for new device-mapper deps
 


Index: sources
===================================================================
RCS file: /cvs/dist/rpms/dmraid/devel/sources,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- sources     19 May 2005 14:52:13 -0000      1.13
+++ sources     10 Nov 2005 22:08:09 -0000      1.14
@@ -1 +1 @@
-a43a0c7e2328e8038a632d03027f320c  dmraid-1.0.0.rc8.tar.bz2
+09084ba1d7a229f9aa416a5f3b371546  dmraid-1.0.0.rc9.tar.bz2

-- 
fedora-cvs-commits mailing list
fedora-cvs-commits@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-cvs-commits

<Prev in Thread] Current Thread [Next in Thread>
  • rpms/dmraid/devel dmraid-1.0.0.rc9-counts.patch, NONE, 1.1 dmraid-1.0.0.rc9-destdir.patch, NONE, 1.1 dmraid-1.0.0.rc9-dupes.patch, NONE, 1.1 dmraid-1.0.0.rc9-exports.patch, NONE, 1.1 dmraid-1.0.0.rc9-install.patch, NONE, 1.1 dmraid-1.0.0.rc9-selinux.patch, NONE, 1.1 dmraid-1.0.0.rc9-table.patch, NONE, 1.1 .cvsignore, 1.6, 1.7 dmraid.spec, 1.25, 1.26 sources, 1.13, 1.14, fedora-cvs-commits <=