Signed-off-by: Diego Elio 'Flameeyes' Pettenò <flameeyes@xxxxxxxxx> --- Makefile.am | 2 +- configure.ac | 1 - fdisk/Makefile.am | 72 ----------------------------------------------------- fdisk/module.am | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 70 insertions(+), 74 deletions(-) delete mode 100644 fdisk/Makefile.am create mode 100644 fdisk/module.am diff --git a/Makefile.am b/Makefile.am index f2d17d8..5cf2700 100644 --- a/Makefile.am +++ b/Makefile.am @@ -44,7 +44,6 @@ SHLIBS_DIRS += shlibs/mount endif SUBDIRS = \ - fdisk \ getopt \ $(SHLIBS_DIRS) \ login-utils \ @@ -107,6 +106,7 @@ tests_helpers_test_md5_SOURCES = tests/helpers/test_md5.c lib/md5.c include lib/module.am include disk-utils/module.am +include fdisk/module.am clean-local: rm -rf tests/output tests/diff diff --git a/configure.ac b/configure.ac index 8488275..bd1657e 100644 --- a/configure.ac +++ b/configure.ac @@ -1132,7 +1132,6 @@ LIBS="" AC_CONFIG_HEADERS(config.h) AC_CONFIG_FILES([ -fdisk/Makefile fsck/Makefile getopt/Makefile hwclock/Makefile diff --git a/fdisk/Makefile.am b/fdisk/Makefile.am deleted file mode 100644 index 36871f3..0000000 --- a/fdisk/Makefile.am +++ /dev/null @@ -1,72 +0,0 @@ -include $(top_srcdir)/config/include-Makefile.am - -EXTRA_DIST = README.fdisk README.cfdisk sfdisk.examples partitiontype.c - -fdisk_common = i386_sys_types.c common.h gpt.c gpt.h \ - $(top_srcdir)/lib/blkdev.c $(top_srcdir)/lib/wholedisk.c \ - $(top_srcdir)/lib/mbsalign.c - -if LINUX -fdisk_common += $(top_srcdir)/lib/linux_version.c -endif - -if !ARCH_M68K - -sbin_PROGRAMS = fdisk -dist_man_MANS = fdisk.8 -fdisk_SOURCES = fdisk.c fdiskbsdlabel.c fdisksgilabel.c \ - fdisksunlabel.c fdiskaixlabel.c fdiskmaclabel.c partname.c \ - fdisk.h fdisksunlabel.h fdisksgilabel.h fdiskaixlabel.h \ - fdiskbsdlabel.h fdiskmaclabel.h $(fdisk_common) - -cflags_blkid = $(AM_CFLAGS) -ldadd_blkid = - -if BUILD_LIBBLKID -# only in-tree libblkid has topology support -ldadd_blkid += $(ul_libblkid_la) -cflags_blkid += -I$(ul_libblkid_incdir) -endif - -if HAVE_STATIC_FDISK -sbin_PROGRAMS += fdisk.static -fdisk_static_SOURCES = $(fdisk_SOURCES) -fdisk_static_LDFLAGS = -all-static -fdisk_static_CFLAGS = $(cflags_blkid) -fdisk_static_LDADD = $(ldadd_blkid) -endif - -fdisk_CFLAGS = $(cflags_blkid) -fdisk_LDADD = $(ldadd_blkid) - -if !ARCH_SPARC - -sbin_PROGRAMS += sfdisk -dist_man_MANS += sfdisk.8 -sfdisk_SOURCES = sfdisk.c partname.c $(fdisk_common) - -if HAVE_STATIC_SFDISK -sbin_PROGRAMS += sfdisk.static -sfdisk_static_SOURCES = $(sfdisk_SOURCES) -sfdisk_static_LDFLAGS = -all-static -endif - -if USE_SLANG -sbin_PROGRAMS += cfdisk -dist_man_MANS += cfdisk.8 -cfdisk_SOURCES = cfdisk.c $(fdisk_common) -cfdisk_CFLAGS = $(cflags_blkid) -cfdisk_LDADD = -lslang $(ldadd_blkid) -else -if HAVE_NCURSES -sbin_PROGRAMS += cfdisk -dist_man_MANS += cfdisk.8 -cfdisk_SOURCES = cfdisk.c $(fdisk_common) -cfdisk_CFLAGS = $(cflags_blkid) -cfdisk_LDADD = @NCURSES_LIBS@ $(ldadd_blkid) -endif -endif - -endif # !ARCH_SPARC -endif # !ARCH_M68K - diff --git a/fdisk/module.am b/fdisk/module.am new file mode 100644 index 0000000..bd57722 --- /dev/null +++ b/fdisk/module.am @@ -0,0 +1,69 @@ +EXTRA_DIST += fdisk/README.fdisk fdisk/README.cfdisk \ + fdisk/sfdisk.examples fdisk/partitiontype.c + +fdisk_common = fdisk/i386_sys_types.c fdisk/common.h fdisk/gpt.c fdisk/gpt.h \ + lib/blkdev.c lib/wholedisk.c lib/mbsalign.c $(linux_version_srcs) + +cflags_blkid = $(AM_CFLAGS) +ldadd_blkid = + +if BUILD_LIBBLKID +# only in-tree libblkid has topology support +ldadd_blkid += $(ul_libblkid_la) +cflags_blkid += -I$(ul_libblkid_incdir) +endif + +fdisk_fdisk_SOURCES = fdisk/fdisk.c fdisk/fdiskbsdlabel.c fdisk/fdisksgilabel.c \ + fdisk/fdisksunlabel.c fdisk/fdiskaixlabel.c fdisk/fdiskmaclabel.c fdisk/partname.c \ + fdisk/fdisk.h fdisk/fdisksunlabel.h fdisk/fdisksgilabel.h fdisk/fdiskaixlabel.h \ + fdisk/fdiskbsdlabel.h fdisk/fdiskmaclabel.h $(fdisk_common) +fdisk_fdisk_CFLAGS = $(cflags_blkid) +fdisk_fdisk_LDADD = $(ldadd_blkid) + +fdisk_fdisk_static_SOURCES = $(fdisk_fdisk_SOURCES) +fdisk_fdisk_static_LDFLAGS = -all-static +fdisk_fdisk_static_CFLAGS = $(cflags_blkid) +fdisk_fdisk_static_LDADD = $(ldadd_blkid) + +fdisk_sfdisk_SOURCES = fdisk/sfdisk.c fdisk/partname.c $(fdisk_common) + +fdisk_sfdisk_static_SOURCES = $(fdisk_sfdisk_SOURCES) +fdisk_sfdisk_static_LDFLAGS = -all-static + +fdisk_cfdisk_SOURCES = fdisk/cfdisk.c $(fdisk_common) +fdisk_cfdisk_CFLAGS = $(cflags_blkid) +fdisk_cfdisk_LDADD = $(ldadd_blkid) + +if BUILD_FSCK + +if !ARCH_M68K +sbin_PROGRAMS += fdisk/fdisk +dist_man_MANS += fdisk/fdisk.8 + +if HAVE_STATIC_FDISK +sbin_PROGRAMS += fdisk/fdisk.static +endif + +if !ARCH_SPARC +sbin_PROGRAMS += fdisk/sfdisk +dist_man_MANS += fdisk/sfdisk.8 + +if HAVE_STATIC_SFDISK +sbin_PROGRAMS += fdisk/sfdisk.static +endif + +if USE_SLANG +sbin_PROGRAMS += fdisk/cfdisk +dist_man_MANS += fdisk/cfdisk.8 +fdisk_cfdisk_LDADD += -lslang +else +if HAVE_NCURSES +sbin_PROGRAMS += fdisk/cfdisk +dist_man_MANS += fdisk/cfdisk.8 +fdisk_cfdisk_LDADD += $(NCURSES_LIBS) +endif +endif + +endif # !ARCH_SPARC +endif # !ARCH_M68K +endif # BUILD_FSCK -- 1.7.1.1 -- To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html