sbin_PROGRAMS += fdisk
dist_man_MANS += fdisks/fdisk.8
fdisk_SOURCES = \
- fdisks/dos_part_types.h \
fdisks/fdisk.c \
fdisks/fdisk.h \
fdisks/fdisk-ask.c \
fdisks/fdiskbsdlabel.c \
fdisks/fdiskbsdlabel.h \
- fdisks/fdiskdoslabel.c \
- fdisks/fdiskdoslabel.h \
fdisks/fdisk-menu.c \
fdisks/partname.c \
fdisks/common.h
};
static struct systypes i386_sys_types[] = {
- #include "dos_part_types.h"
+ #include "pt-mbr-partnames.h"
};
#ifdef __GNU__
#include "pt-sun.h"
#include "pt-mbr.h"
-#include "fdiskdoslabel.h"
#include "fdiskbsdlabel.h"
struct menu_entry {
#include "closestream.h"
#include "pt-sun.h" /* to toggle flags */
-#include "fdiskdoslabel.h"
#include "fdiskbsdlabel.h"
#ifdef HAVE_LINUX_COMPILER_H
#define NETBSD_PARTITION 0xa9
#define DKTYPENAMES
#include "fdiskbsdlabel.h"
-#include "fdiskdoslabel.h"
#include "all-io.h"
/*
+++ /dev/null
-#ifndef FDISK_DOS_LABEL_H
-#define FDISK_DOS_LABEL_H
-
-extern struct dos_partition *fdisk_dos_get_partition(
- struct fdisk_context *cxt,
- size_t i);
-
-extern int fdisk_dos_fix_order(struct fdisk_context *cxt);
-extern int fdisk_dos_move_begin(struct fdisk_context *cxt, int i);
-extern int fdisk_dos_list_extended(struct fdisk_context *cxt);
-
-/* toggle flags */
-#define DOS_FLAG_ACTIVE 1
-
-#endif
};
static struct systypes i386_sys_types[] = {
- #include "dos_part_types.h"
+ #include "pt-mbr-partnames.h"
};
/*
include/xgetpass.h \
include/pt-sgi.h \
include/pt-mbr.h \
+ include/pt-mbr-partnames.h \
include/pt-sun.h
\
libfdisk/src/sun.c \
libfdisk/src/sgi.c \
+ libfdisk/src/dos.c \
libfdisk/src/gpt.c
/*
*
- * Copyright (C) 2013 Karel Zak <kzak@redhat.com>
+ * Copyright (C) 2007-2013 Karel Zak <kzak@redhat.com>
+ * 2012 Davidlohr Bueso <dave@gnu.org>
*
* This is re-written version for libfdisk, the original was fdiskdoslabel.c
* from util-linux fdisk.
#include "c.h"
#include "nls.h"
#include "randutils.h"
-#include "common.h"
#include "pt-mbr.h"
#include "fdiskP.h"
-#include "fdiskdoslabel.h"
-
#include <ctype.h>
#define MAXIMUM_PARTS 60
* Partition types
*/
static struct fdisk_parttype dos_parttypes[] = {
- #include "dos_part_types.h"
+ #include "pt-mbr-partnames.h"
};
#define set_hsc(h,s,c,sector) { \
dos_partition_get_start(p) || dos_partition_get_size(p));
}
-
static int get_partition_unused_primary(struct fdisk_context *cxt)
{
size_t orgmax = cxt->label->nparts_max;
extern int fdisk_gpt_partition_set_uuid(struct fdisk_context *cxt, size_t i);
extern int fdisk_gpt_partition_set_name(struct fdisk_context *cxt, size_t i);
+/* dos.c */
+extern struct dos_partition *fdisk_dos_get_partition(
+ struct fdisk_context *cxt,
+ size_t i);
+
+extern int fdisk_dos_fix_order(struct fdisk_context *cxt);
+extern int fdisk_dos_move_begin(struct fdisk_context *cxt, int i);
+extern int fdisk_dos_list_extended(struct fdisk_context *cxt);
+
+#define DOS_FLAG_ACTIVE 1
+
/* ask.c */
#define fdisk_is_ask(a, x) (fdisk_ask_get_type(a) == FDISK_ASKTYPE_ ## x)