summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* maint: use a git submodule for gnulibJim Meyering2009-04-112-0/+3
| | | | | | * .gitmodules: New file, to track gnulib. * gnulib: New file, created by running this: git submodule add git://git.sv.gnu.org/gnulib.git gnulib
* maint: sync from coreutilsJim Meyering2009-04-102-13/+20
| | | | | * maint.mk: Sync from coreutils. * bootstrap: Likewise.
* build-from-git: depend on automake-1.10bJim Meyering2009-04-082-3/+3
| | | | | | * bootstrap.conf (buildreq): Note the automake-1.10b requirement. * configure.ac (AM_INIT_AUTOMAKE): Enable new automake options: dist-xz, color-tests, parallel-tests, silent-rules.
* bootstrap.conf: require automake 1.10 since 1.10a is an alpha versionOtavio Salvador2009-04-081-1/+1
|
* * maint.mk: merge with latest from coreutilsJim Meyering2009-03-211-15/+19
|
* maint: indent consistentlyJim Meyering2009-03-211-3/+3
| | | | * doc/po4a.mk (updatepo): Replace TAB+8-spaces with two TABs.
* * bootstrap: sync from coreutilsJim Meyering2009-03-051-20/+172
|
* build: enable "make syntax-check" rule to prohibit trailing spacesJim Meyering2009-03-051-2/+1
| | | | * cfg.mk (local-checks-to-skip): Remove sc_trailing_blank.
* remove all trailing blanksJim Meyering2009-03-05106-1461/+1461
| | | | | | ...by running these commands: t=$'\t' git grep -l "[ $t]\$"|xargs perl -pi -e 's/[ \t]+$//'
* portability: use last_component, not basenameJim Meyering2009-03-054-5/+6
| | | | | | | | | | | * libparted/arch/linux.c (read_device_sysfs_file): Use last_component from gnulib's basename module, not the less-portable "basename" function. (_device_get_partition_range): Likewise. Reported by Karel Zak. * debug/clearfat/Makefile.am (clearfat_LDADD): Link gnulib *after* libparted, not before. * partprobe/Makefile.am (partprobe_LDADD): Likewise. * parted/Makefile.am (parted_LDADD): Likewise.
* test correctly for snprintf failureKarel Zak2009-03-051-1/+1
| | | | | * libparted/arch/linux.c (_device_get_partition_range): Correct test for failed snprintf.
* gpt: plug a memory leak in gpt_read()Petr Uzel2009-03-051-1/+5
| | | | * libparted/labels/gpt.c (gpt_read): Free local variable, "zeros".
* update some release-related administriviaJim Meyering2009-03-053-3/+14
| | | | | | * .prev-version: Record that the previous release was 1.8.8.1. * NEWS: Fill in the date for the previous release. * cfg.mk (old_NEWS_hash): Update
* * maint.mk: Sync from coreutils.Jim Meyering2009-03-051-2/+50
|
* adjust "parted -s dev print" not to emit trailing spacesJim Meyering2009-03-052-7/+17
| | | | | | * parted/table.c (table_render_row): Don't append trailing spaces or delimiter after final field, and trim any other trailing spaces. * tests/t5000-tags.sh: Remove trailing spaces from expected output.
* reword a comment; more formatting changes.Jim Meyering2009-03-051-11/+9
| | | | | | * libparted/arch/linux.c (_disk_sync_part_table): Reword comment to use the "active" voice, not "we ...". Adjust formatting in new/moved code.
* rename all "support" parameters; avoid new compiler warningsJim Meyering2009-03-0510-29/+39
| | | | | | | | | | | | | | | | | | | Change each occurrence like this (which evokes a warning from gcc): - return *supported = MAX_TOTAL_PART; to this: + *max_n = MAX_TOTAL_PART; + return true; I did it mostly mechanically: cd libparted/labels && grep -l 'return .supported = ' *.c|xargs perl -ni \ -e '$m=/^\treturn \*supported( = .*;)/;' \ -e 'print $m ? "\t*max_n$1\n\treturn true;\n" : $_' git grep -l 'int\* supported'|xargs perl -pi -e 's/int\* supported/int *max_n/' That got all but aix.c, which used different spacing: "int *supported", which I changed manually. Then I updated all copyright dates.
* gpt: adjust formatting and rename a parameter: s/supported/max_n/.Jim Meyering2009-03-051-15/+15
| | | | | | * libparted/labels/gpt.c (gpt_get_max_supported_partition_count): Rename parameter: s/supported/max_n/. The latter sounds more like a number, while "supported" sounds boolean at first.
* Properly sync partitions with operating systemJoel Granados Moreno2009-03-0514-20/+227
| | | | | | | | | | | | | | | | | | | | | | | | | | * include/parted/disk.h: Add prototypes for new function. * libparted/disk.c (ped_disk_get_max_supported_partition_count): New function that calls the partition-table-specific function. * libparted/arch/linux.c (_disk_sync_part_table): To sync the table in disk with the kernel, we remove all partitions from the kernel table and then add the ones that are in disk. For this to happen we need to calculate the partition-table-type-specific maximum number of supported partitions. * libparted/labels/gpt.c (gpt_get_max_supported_partition_count): Read the gpt header from disk and calculate the maximum number of partitions it can accommodate. * libparted/labels/aix.c (get_max_supported_partition_count): New function. * libparted/labels/bsd.c: Likewise. * libparted/labels/dasd.c: Likewise. * libparted/labels/dos.c: Likewise. * libparted/labels/dvh.c: Likewise. * libparted/labels/gpt.c: Likewise. * libparted/labels/loop.c: Likewise. * libparted/labels/mac.c: Likewise. * libparted/labels/pc98.c: Likewise. * libparted/labels/rdb.c: Likewise. * libparted/labels/sun.c: Likewise.
* dasd: emit a diagnostic upon probe failureJoel Granados Moreno2009-02-201-4/+4
| | | | | * libparted/labels/dasd.c (dasd_probe): Inform the user when no dasd volumes are present in a device.
* gpt: avoid failed assertion on big-endian systemsPetr Uzel2009-02-201-1/+1
| | | | | | * libparted/labels/gpt.c (_parse_header): Compute last_usable_if_grown not as an LE64 value but as a CPU-format one, since we're about to compare it to another.
* test for the gpt_read failed-assertion fixPetr Uzel2009-02-182-0/+43
| | | | | * tests/t0201-gpt.sh: New file. * tests/Makefile.am (TESTS): Add it.
* avoid failed assertion when creating a GPT partition table...Jim Meyering2009-02-181-3/+8
| | | | | | | | | | | | | | | | | on top of an old one for a larger device * libparted/labels/gpt.c (gpt_read): Don't assert that the location of the alternate LBA is within the current device. It will be beyond its end when the device it was created for was larger. Instead, just return, treating this like any other non-match. Here's the reproducer: dev=file dd of=$dev if=/dev/null seek=4001 parted -s $dev mklabel gpt dd of=$dev if=/dev/null seek=4000 parted -s $dev mklabel gpt
* gpt: add a test: printing a partition table must not modify itJim Meyering2009-02-172-0/+57
| | | | | * tests/t0200-gpt.sh: New file. * tests/Makefile.am (TESTS): Add the new test.
* gpt: do not automatically "correct" a suspicious GPT partition tablePetr Uzel2009-02-171-10/+15
| | | | | | | | | | | | | | | | | | | | Previously, when parted was invoked on a disk with a GPT partition table and the backup GPT was not in the last sector of the disk, and even if the requested operation was just to print the partition table, parted would "repair" this automatically. This behavior is undesirable in the following situation: dm-raid on top of block device. The dm-raid is partitioned with GPT. If the dm-raid starts on the first block of underlying device (AFAIK this is the case with FastTrack controllers) and the user runs parted on the dm-raid, it will identify the physical device as being partitioned with GPT and see the backup GPT table not to be in the last sector of the physical device and thus move it to this location (which may lead to destruction of dm-raid metadata in case they are located at the end of physical device). This patch modifies parted's behavior to ignore fixing of backup GPT position by default.
* tests: use "compare", not "$compare"Jim Meyering2009-02-1617-51/+51
| | | | | * test-lib.sh (compare): Define "compare" as a function, not a variable. * tests/t*.sh: use "compare", not "$compare"
* don't segfault on a device-mapper device with no targetJim Meyering2009-02-131-1/+1
| | | | | | | * libparted/arch/linux.c (_dm_maptype): Don't dereference NULL for a device-mapper device with no target. Use the string "NO-TARGET" instead. Reported by Mike Hwang in http://thread.gmane.org/gmane.comp.gnu.parted.devel/2432
* compile warning-free also with upcoming gcc-4.4Jim Meyering2009-02-081-5/+8
| | | | | | * libparted/fs/fat/fat.c (_gen_new_serial_number): Use a union rather than a warning-provoking cast. Avoids this gcc warning: "dereferencing type-punned pointer will break strict-aliasing rules"
* clearfat: diagnose an invalid device numberJim Meyering2009-02-072-3/+14
| | | | | | * debug/clearfat/clearfat.c: Include <limits.h> and "xstrtol.h". (main): Diagnose an invalid minor device number argument. * bootstrap.conf (gnulib_modules): Add xstrtol.
* maint.mk: sync from coreutilsJim Meyering2009-02-071-25/+35
|
* Revert "don't try to translate 'lib/xstrtol-error.c'"Jim Meyering2009-02-071-0/+1
| | | | | This reverts commit 39adc77de255b7df33e1efb93853c7ccfd4c45f5. Otherwise, "make syntax-check" fails the sc_po_check test.
* don't try to translate 'lib/xstrtol-error.c'Otavio Salvador2009-02-061-1/+0
|
* remove ped_(register|unregister)_disk_type since they were deprecatedOtavio Salvador2009-02-062-30/+0
| | | | | | ped_(register|unregister)_disk_type were remove since they are deprecated since 1.8 releases. The functions ped_disk_type_(register|unregister) are the ones to be used.
* move architecture specific code since they're used in a single placeOtavio Salvador2009-02-067-126/+42
| | | | | | All architecture headers (linux.h, gnu.h and beos.h) are now removed. The required code has beem moved to the C file that required it.
* avoid bootstrap failureJim Meyering2009-01-271-0/+1
| | | | | * bootstrap.conf: Ensure the gnulib-tests/ exists. Reported by Matt Domsch.
* better m4 quotingJim Meyering2009-01-262-75/+75
|
* * parted/ui.c: Include <config.h> before any other file.Jim Meyering2009-01-261-2/+3
|
* maint.mk: sync from coreutilsJim Meyering2009-01-261-228/+152
|
* * po/POTFILES.in: Add lib/xstrtol-error.c.Jim Meyering2009-01-261-1/+2
|
* _disk_sync_part_table: revise yet againJim Meyering2009-01-261-2/+2
| | | | | | | | This fixes a bug whereby parted could leave the kernel with an erroneous view of a partition table. * libparted/arch/linux.c (_disk_sync_part_table): Per analysis in http://thread.gmane.org/gmane.comp.gnu.parted.devel/2297/focus=2307. Patch suggested by Petr Uzel.
* * bootstrap.conf: sync from coreutilsJim Meyering2009-01-261-26/+69
|
* Differentiate between Ext4 and Ext3 file systems.Debarshi Ray2009-01-084-9/+105
| | | | | | | | | | | | | | | | | | Fixes http://parted.alioth.debian.org/cgi-bin/trac.cgi/ticket/188 * libparted/fs/ext2/ext2_fs.h (EXT4_FEATURE_RO_COMPAT_HUGE_FILE, EXT4_FEATURE_RO_COMPAT_DIR_NLINK, EXT4_FEATURE_INCOMPAT_EXTENTS, EXT4_FEATURE_INCOMPAT_64BIT): New constants. * libparted/fs/ext2/interface.c (_ext2_generic_probe): Ext4 file systems will have EXT4_FEATURE_* bits set, while Ext3 will not. (_ext2_probe, _ext3_probe): Pass 2 and 3 respectively, instead of 0 and 1, to _ext2_generic_probe. (_ext4_probe): New function. (_ext4_ops, _ext4_type): New structures. (ped_file_system_ext2_init): Register Ext4 file system type. (ped_file_system_ext2_done): Likewise. * tests/Makefile.am (TESTS): Add t1700-ext-probe.sh. * tests/t1700-ext-probe.sh: New file.
* fix a "make syntax-check" failure (update copyright date)Jim Meyering2009-01-081-2/+2
| | | | * doc/parted.texi: Update copyright dates for 2009.
* avoid "make install" failure with latest GNU makeJim Meyering2008-12-231-4/+2
| | | | | | * doc/C/Makefile.am (dist_man8_MANS): Use per-section variable names, as recommended by automake. (man_MANS): Remove redundant definition.
* sun partition tables: add support for RAID partition typesTom "spot" Callaway2008-12-233-6/+104
| | | | | | | | | | | | | | | | | | | | | This patch enables RAID as a supported partition type on Sun disk layouts, commonly found/used on SPARC hardware. It has been tested on Aurora SPARC Linux (and Fedora SPARC). I have no idea if Solaris supports Software RAID or not... Along with the code change, I wrote a test case that checks if the RAID partition type is supported on sun disk labels. * libparted/labels/sun.c [_SunPartitionData] (is_raid): New member. (sun_read): Initialize the ->is_raid member. (sun_partition_new): Clear is_raid, like all the other members. (sun_partition_duplicate): Propagate the is_raid member. (sun_partition_set_system): Make sun_data->type reflect is_raid. (sun_partition_set_flag): Also initialize ->is_raid. (sun_partition_get_flag): Handle PED_PARTITION_RAID. (sun_partition_is_flag_available): Likewise. * tests/t4000-sun-raid-type.sh: New file. * tests/Makefile.am (TESTS): Add t4000-sun-raid-type.sh.
* Add support for SD/MMC storage cards on LinuxHarald Welte2008-10-104-5/+45
| | | | | | | | | | | | | | This patch adds a new SDMMC device type to represent SD/MMC cards. There is nothing special about handling those devices, they are just standard block devices with different names. They use device major ID 179 and are usually called /dev/mmcblkN (where N is the card number) and the individual partitions /dev/mmcblkNpM (where M is the partition number). This patch was developed as part of an effort to make debian-installer support installation of Debian GNU/Linux on SD/MMC cards, as boot-from-SD is becoming a feature seen in mobile x86 devices.
* Remove obsolete 'i' from parted optstring (--interactive/-i option is not ↵Petr Uzel2008-08-201-1/+1
| | | | supported anymore)
* doc: remove obsolete --interactive (-i) option descriptionsPetr Uzel2008-08-195-18/+0
|
* update build/test infrastructure from coreutilsJim Meyering2008-08-072-30/+66
| | | | | * bootstrap: Update from coreutils. * maint.mk: Likewise.
* add a test for recently introduced loop-dev-based bugSoren Hansen2008-08-072-1/+57
| | | | | | | This also checks for the current behavior when trying to partition a device that may not be partitioned, like loop devices. * tests/Makefile.am (TESTS): Add tests/t8000-loop.sh. * tests/t8000-loop.sh: New file. Test for the above fix.