libpool (2.10+3) unstable; urgency=low

* Use native version scheme per new dpkg
  * Do not ship sys/pool.h and sys/pool_impl.h
  * Require new uts-dev instead
  * Removed libpool-no-nvpair.patch
  * Removed libpool-strip-sys-pool.h.patch
  * Added libpool-min-max.patch
  * Strip library
  * Added libpool1-dbg package
  * libpool1-dev depends on uts-dev (>= 2.10+5)
This commit is contained in:
Igor Pashev 2013-09-16 18:06:24 +04:00
parent 652f5f59ca
commit 0a875cd162
7 changed files with 49 additions and 163 deletions

View File

@ -1,3 +1,17 @@
libpool (2.10+3) unstable; urgency=low
* Use native version scheme per new dpkg
* Do not ship sys/pool.h and sys/pool_impl.h
* Require new uts-dev instead
* Removed libpool-no-nvpair.patch
* Removed libpool-strip-sys-pool.h.patch
* Added libpool-min-max.patch
* Strip library
* Added libpool1-dbg package
* libpool1-dev depends on uts-dev (>= 2.10+5)
-- Igor Pashev <pashev.igor@gmail.com> Mon, 16 Sep 2013 18:05:37 +0400
libpool (2.10-2) unstable; urgency=low
* Add /usr/include/sys/pool.h (removed from unix-libc-dev)

View File

@ -10,6 +10,7 @@ Build-Depends:
libscf1-dev, lib32scf1-dev,
libnvpair1-dev, lib32nvpair1-dev,
libexacct1-dev, lib32exacct1-dev,
uts-dev (>= 2.10+5),
quilt,
symlinks,
Standards-Version: 3.9.3
@ -42,12 +43,23 @@ Description: pool configuration manipulation library
pools configuration files, as well as that for commiting an existing
configuration to becoming the running OS configuration.
Package: libpool1-dbg
Section: debug
Priority: extra
Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Architecture: illumos-any
Depends: ${shlibs:Depends}, ${misc:Depends}, libpool1 (= ${binary:Version})
Description: pool configuration manipulation library: debug symbols
This package contains the detached debugging symbols for the libpool library
Package: libpool1-dev
Section: libdevel
Priority: optional
Architecture: illumos-any
Provides: libpool-dev
Depends: libpool1 (= ${binary:Version}), ${misc:Depends}, libc1-dev
Depends: libpool1 (= ${binary:Version}), ${misc:Depends}, libc1-dev,
uts-dev (>= 2.10+5)
Description: pool configuration manipulation library (development files)
This package contains the header files and symlinks needed
to compile applications that use libpool.

View File

@ -0,0 +1,19 @@
Index: libpool/usr/src/lib/libpool/common/pool_commit.c
===================================================================
--- libpool.orig/usr/src/lib/libpool/common/pool_commit.c 2012-10-08 04:25:41.000000000 +0400
+++ libpool/usr/src/lib/libpool/common/pool_commit.c 2013-09-16 17:42:06.432106940 +0400
@@ -77,8 +77,14 @@
#include "pool_internal.h"
#include "pool_impl.h"
+#ifndef MIN
#define MIN(x, y) ((x) < (y) ? (x) : (y))
+#endif
+
+#ifndef MAX
#define MAX(x, y) ((x) > (y) ? (x) : (y))
+#endif
+
#define POA_IMPORTANCE_NUM 0
#define POA_SURPLUS_TO_DEFAULT_NUM 1

View File

@ -1,35 +0,0 @@
Index: libpool/usr/src/uts/common/sys/pool_impl.h
===================================================================
--- libpool.orig/usr/src/uts/common/sys/pool_impl.h 2012-10-08 00:26:00.000000000 +0000
+++ libpool/usr/src/uts/common/sys/pool_impl.h 2012-11-08 16:52:55.860975682 +0000
@@ -32,7 +32,6 @@
#include <sys/types.h>
#include <sys/cpupart.h>
#include <sys/exacct_catalog.h>
-#include <sys/nvpair.h>
#ifdef __cplusplus
extern "C" {
@@ -280,22 +279,6 @@
#define PP_INIT 0x0010
#define PP_HIDDEN 0x0020
-#ifdef _KERNEL
-
-/*
- * For special properties
- */
-typedef struct pool_property {
- char *pp_name; /* name of the property */
- data_type_t pp_type; /* type of the property */
- int pp_perm; /* permissions */
-} pool_property_t;
-
-extern int pool_propput_common(nvlist_t *, nvpair_t *, pool_property_t *);
-extern int pool_proprm_common(nvlist_t *, char *, pool_property_t *);
-
-#endif /* _KERNEL */
-
#ifdef __cplusplus
}
#endif

View File

@ -1,120 +0,0 @@
Index: libpool/usr/src/uts/common/sys/pool.h
===================================================================
--- libpool.orig/usr/src/uts/common/sys/pool.h 2012-10-08 00:26:00.000000000 +0000
+++ libpool/usr/src/uts/common/sys/pool.h 2012-11-11 12:42:06.404259835 +0000
@@ -26,16 +26,6 @@
#ifndef _SYS_POOL_H
#define _SYS_POOL_H
-#include <sys/types.h>
-#include <sys/time.h>
-#include <sys/nvpair.h>
-#include <sys/procset.h>
-#include <sys/list.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
#define POOL_DEFAULT 0 /* default pool's ID */
#define POOL_MAXID 999999 /* maximum possible pool ID */
#define POOL_INVALID -1
@@ -44,98 +34,4 @@
#define POOL_DISABLED 0 /* pools enabled */
#define POOL_ENABLED 1 /* pools disabled */
-#ifdef _KERNEL
-
-struct pool_pset;
-
-typedef struct pool {
- poolid_t pool_id; /* pool ID */
- uint32_t pool_ref; /* # of procs in this pool */
- list_node_t pool_link; /* links to next/prev pools */
- nvlist_t *pool_props; /* pool properties */
- struct pool_pset *pool_pset; /* pool's pset */
-} pool_t;
-
-/*
- * Flags for pool_do_bind
- */
-#define POOL_BIND_PSET 0x00000001
-#define POOL_BIND_ALL POOL_BIND_PSET
-
-/*
- * Result codes for pool_get_class()
- */
-#define POOL_CLASS_UNSET -1 /* no scheduling class set */
-#define POOL_CLASS_INVAL -2 /* class is invalid */
-
-extern int pool_count; /* current number of pools */
-extern pool_t *pool_default; /* default pool pointer */
-extern int pool_state; /* pools state -- enabled/disabled */
-extern void *pool_buf; /* last state snapshot */
-extern size_t pool_bufsz; /* size of pool_buf */
-
-/*
- * Lookup routines
- */
-extern pool_t *pool_lookup_pool_by_id(poolid_t);
-extern pool_t *pool_lookup_pool_by_name(char *);
-extern pool_t *pool_lookup_pool_by_pset(int);
-
-/*
- * Configuration routines
- */
-extern void pool_init(void);
-extern int pool_status(int);
-extern int pool_create(int, int, id_t *);
-extern int pool_destroy(int, int, id_t);
-extern int pool_transfer(int, id_t, id_t, uint64_t);
-extern int pool_assoc(poolid_t, int, id_t);
-extern int pool_dissoc(poolid_t, int);
-extern int pool_bind(poolid_t, idtype_t, id_t);
-extern id_t pool_get_class(pool_t *);
-extern int pool_do_bind(pool_t *, idtype_t, id_t, int);
-extern int pool_query_binding(idtype_t, id_t, id_t *);
-extern int pool_xtransfer(int, id_t, id_t, uint_t, id_t *);
-extern int pool_pack_conf(void *, size_t, size_t *);
-extern int pool_propput(int, int, id_t, nvpair_t *);
-extern int pool_proprm(int, int, id_t, char *);
-extern int pool_propget(char *, int, int, id_t, nvlist_t **);
-extern int pool_commit(int);
-extern void pool_get_name(pool_t *, char **);
-
-/*
- * Synchronization routines
- */
-extern void pool_lock(void);
-extern int pool_lock_intr(void);
-extern int pool_lock_held(void);
-extern void pool_unlock(void);
-extern void pool_barrier_enter(void);
-extern void pool_barrier_exit(void);
-
-typedef enum {
- POOL_E_ENABLE,
- POOL_E_DISABLE,
- POOL_E_CHANGE,
-} pool_event_t;
-
-typedef void pool_event_cb_func_t(pool_event_t, poolid_t, void *);
-
-typedef struct pool_event_cb {
- pool_event_cb_func_t *pec_func;
- void *pec_arg;
- list_node_t pec_list;
-} pool_event_cb_t;
-
-/*
- * Routines used to register interest in changes in cpu pools.
- */
-extern void pool_event_cb_register(pool_event_cb_t *);
-extern void pool_event_cb_unregister(pool_event_cb_t *);
-#endif /* _KERNEL */
-
-#ifdef __cplusplus
-}
-#endif
-
#endif /* _SYS_POOL_H */

View File

@ -1,5 +1,4 @@
libpool-no-note.h.patch
libpool-NULL-0.patch
libpool-dtd-location.patch
libpool-no-nvpair.patch
libpool-strip-sys-pool.h.patch
libpool-min-max.patch

View File

@ -18,9 +18,7 @@ unpack: unpack-stamp
unpack-stamp:
dh_testdir
dh_illumos_gate --build \
$(libs:%=usr/src/lib/%) \
usr/src/uts/common/sys/pool.h \
usr/src/uts/common/sys/pool_impl.h
$(libs:%=usr/src/lib/%)
# Not used and buggy:
echo > usr/src/Makefile.msg.targ
@ -41,7 +39,6 @@ unpatch:
dirs-stamp:
. usr/env.sh; mkdir -p \
debian/tmp/usr/include \
debian/tmp/usr/include/sys \
debian/tmp$$DEB_LIBDIR_32 \
debian/tmp$$DEB_LIBDIR_64 \
debian/tmp$$DEB_USRLIBDIR_32 \
@ -51,7 +48,6 @@ dirs-stamp:
headers-stamp: patch-stamp dirs-stamp
dh_illumos_make $(libs_headers:%=usr/src/lib/%) -t install_h
cp usr/src/uts/common/sys/*.h debian/tmp/usr/include/sys/
touch $@
install build build-arch build-indep: build-stamp
@ -83,6 +79,7 @@ binary-stamp: build-stamp
dh_installchangelogs
dh_link
dh_compress
dh_strip -plibpool1 --dbg-package=libpool1-dbg
dh_fixperms
dh_makeshlibs -- -c4
dh_installdeb