diff options
author | Fabian Groffen <grobian@gentoo.org> | 2011-01-25 22:48:15 +0100 |
---|---|---|
committer | Karel Zak <kzak@redhat.com> | 2011-01-31 17:53:25 +0100 |
commit | 9f55bf3794ca98852dd1f352f993dea60d83a2e1 (patch) | |
tree | 96feb1d44cba7d6463f7b7a8906f3c35fe657263 | |
parent | aada54e028b73ddbea96039375b1d1768fcf3496 (diff) | |
download | util-linux-old-9f55bf3794ca98852dd1f352f993dea60d83a2e1.tar.gz |
libblkid: conditionalise parts from blkid/topology for Linux
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
-rw-r--r-- | shlibs/blkid/src/topology/Makefile.am | 13 | ||||
-rw-r--r-- | shlibs/blkid/src/topology/topology.c | 2 | ||||
-rw-r--r-- | shlibs/blkid/src/topology/topology.h | 6 |
3 files changed, 14 insertions, 7 deletions
diff --git a/shlibs/blkid/src/topology/Makefile.am b/shlibs/blkid/src/topology/Makefile.am index 11c348b6..775fea3e 100644 --- a/shlibs/blkid/src/topology/Makefile.am +++ b/shlibs/blkid/src/topology/Makefile.am @@ -5,10 +5,13 @@ libblkid_topology_la_LIBADD = noinst_LTLIBRARIES = libblkid_topology.la libblkid_topology_la_SOURCES = topology.c \ - topology.h \ + topology.h + +if LINUX +libblkid_topology_la_SOURCES += sysfs.c \ + dm.c \ + lvm.c \ ioctl.c \ - sysfs.c \ md.c \ - dm.c \ - evms.c \ - lvm.c + evms.c +endif diff --git a/shlibs/blkid/src/topology/topology.c b/shlibs/blkid/src/topology/topology.c index f39f49fb..27dc755f 100644 --- a/shlibs/blkid/src/topology/topology.c +++ b/shlibs/blkid/src/topology/topology.c @@ -74,12 +74,14 @@ struct blkid_struct_topology { */ static const struct blkid_idinfo *idinfos[] = { +#ifdef __linux__ &ioctl_tp_idinfo, &sysfs_tp_idinfo, &md_tp_idinfo, &dm_tp_idinfo, &lvm_tp_idinfo, &evms_tp_idinfo +#endif }; diff --git a/shlibs/blkid/src/topology/topology.h b/shlibs/blkid/src/topology/topology.h index b7429d90..6d2f4334 100644 --- a/shlibs/blkid/src/topology/topology.h +++ b/shlibs/blkid/src/topology/topology.h @@ -11,12 +11,14 @@ extern int blkid_topology_set_physical_sector_size(blkid_probe pr, unsigned long /* * topology probers */ +#ifdef __linux__ extern const struct blkid_idinfo ioctl_tp_idinfo; -extern const struct blkid_idinfo sysfs_tp_idinfo; extern const struct blkid_idinfo md_tp_idinfo; -extern const struct blkid_idinfo dm_tp_idinfo; extern const struct blkid_idinfo evms_tp_idinfo; +extern const struct blkid_idinfo sysfs_tp_idinfo; +extern const struct blkid_idinfo dm_tp_idinfo; extern const struct blkid_idinfo lvm_tp_idinfo; +#endif #endif /* BLKID_TOPOLOGY_H */ |