Final 0.6.11 version; only trivial changes
This commit is contained in:
9
NEWS
9
NEWS
@@ -1,5 +1,10 @@
|
|||||||
0.6.11 (??/??/2010):
|
0.6.11 (9/25/2010):
|
||||||
--------------------
|
-------------------
|
||||||
|
|
||||||
|
- Added -F (--first-aligned-in-largest) option to sgdisk. This option is a
|
||||||
|
variant on -f (--first-in-largest); it returns the number of the first
|
||||||
|
sector that will be used in the largest free area, given the current
|
||||||
|
alignment value (set via -a/--set-alignment).
|
||||||
|
|
||||||
- Streamlined GUID code entry in gdisk; it no longer offers the option
|
- Streamlined GUID code entry in gdisk; it no longer offers the option
|
||||||
to enter GUIDs in separate segments.
|
to enter GUIDs in separate segments.
|
||||||
|
|||||||
@@ -180,8 +180,8 @@ bool Attributes::OperateOnAttributes(const uint32_t partNum, const string& attri
|
|||||||
|
|
||||||
// display a single attribute
|
// display a single attribute
|
||||||
case ao_get: {
|
case ao_get: {
|
||||||
cout << partNum+1 << ":" << bitNum << ":" <<
|
cout << partNum+1 << ":" << bitNum << ":"
|
||||||
bool (attributeBitMask & attributes) << endl;
|
<< bool (attributeBitMask & attributes) << endl;
|
||||||
break;
|
break;
|
||||||
} // case ao_get
|
} // case ao_get
|
||||||
|
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
Summary: An fdisk-like partitioning tool for GPT disks
|
Summary: An fdisk-like partitioning tool for GPT disks
|
||||||
Name: gdisk
|
Name: gdisk
|
||||||
Version: 0.6.10
|
Version: 0.6.11
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
License: GPLv2
|
License: GPLv2
|
||||||
URL: http://www.rodsbooks.com/gdisk
|
URL: http://www.rodsbooks.com/gdisk
|
||||||
Group: Applications/System
|
Group: Applications/System
|
||||||
Source: http://www.rodsbooks.com/gdisk/gdisk-0.6.10.tgz
|
Source: http://www.rodsbooks.com/gdisk/gdisk-0.6.11.tgz
|
||||||
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
|
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -40,5 +40,5 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%doc %{_mandir}/man8*
|
%doc %{_mandir}/man8*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Sun Aug 22 2010 R Smith <rodsmith@rodsbooks.com> - 0.6.10
|
* Sat Sep 25 2010 R Smith <rodsmith@rodsbooks.com> - 0.6.11
|
||||||
- Created spec file for 0.6.10 release
|
- Created spec file for 0.6.11 release
|
||||||
|
|||||||
2
gdisk.8
2
gdisk.8
@@ -1,6 +1,6 @@
|
|||||||
.\" Copyright 2010 Roderick W. Smith (rodsmith@rodsbooks.com)
|
.\" Copyright 2010 Roderick W. Smith (rodsmith@rodsbooks.com)
|
||||||
.\" May be distributed under the GNU General Public License
|
.\" May be distributed under the GNU General Public License
|
||||||
.TH "GDISK" "8" "0.6.10" "Roderick W. Smith" "GPT fdisk Manual"
|
.TH "GDISK" "8" "0.6.11" "Roderick W. Smith" "GPT fdisk Manual"
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
gdisk \- Interactive GUID partition table (GPT) manipulator
|
gdisk \- Interactive GUID partition table (GPT) manipulator
|
||||||
.SH "SYNOPSIS"
|
.SH "SYNOPSIS"
|
||||||
|
|||||||
4
gdisk.cc
4
gdisk.cc
@@ -44,7 +44,7 @@ int main(int argc, char* argv[]) {
|
|||||||
device = new char[255];
|
device = new char[255];
|
||||||
junk = fgets(device, 255, stdin);
|
junk = fgets(device, 255, stdin);
|
||||||
if (device[0] != '\n') {
|
if (device[0] != '\n') {
|
||||||
i = strlen(device);
|
i = (int) strlen(device);
|
||||||
if (i > 0)
|
if (i > 0)
|
||||||
if (device[i - 1] == '\n')
|
if (device[i - 1] == '\n')
|
||||||
device[i - 1] = '\0';
|
device[i - 1] = '\0';
|
||||||
@@ -412,7 +412,7 @@ void ExpertsMenu(string filename, GPTDataTextUI* theGPT) {
|
|||||||
device = new char[255];
|
device = new char[255];
|
||||||
junk = fgets(device, 255, stdin);
|
junk = fgets(device, 255, stdin);
|
||||||
if (device[0] != '\n') {
|
if (device[0] != '\n') {
|
||||||
i = strlen(device);
|
i = (int) strlen(device);
|
||||||
if (i > 0)
|
if (i > 0)
|
||||||
if (device[i - 1] == '\n')
|
if (device[i - 1] == '\n')
|
||||||
device[i - 1] = '\0';
|
device[i - 1] = '\0';
|
||||||
|
|||||||
2
gpt.cc
2
gpt.cc
@@ -2191,7 +2191,7 @@ void GPTData::SetAlignment(uint32_t n) {
|
|||||||
// Returns the computed alignment value.
|
// Returns the computed alignment value.
|
||||||
uint32_t GPTData::ComputeAlignment(void) {
|
uint32_t GPTData::ComputeAlignment(void) {
|
||||||
uint32_t i = 0, found, exponent = 31;
|
uint32_t i = 0, found, exponent = 31;
|
||||||
uint64_t align = DEFAULT_ALIGNMENT;
|
uint32_t align = DEFAULT_ALIGNMENT;
|
||||||
|
|
||||||
exponent = (uint32_t) log2(DEFAULT_ALIGNMENT);
|
exponent = (uint32_t) log2(DEFAULT_ALIGNMENT);
|
||||||
for (i = 0; i < numParts; i++) {
|
for (i = 0; i < numParts; i++) {
|
||||||
|
|||||||
2
gpt.h
2
gpt.h
@@ -16,7 +16,7 @@
|
|||||||
#ifndef __GPTSTRUCTS
|
#ifndef __GPTSTRUCTS
|
||||||
#define __GPTSTRUCTS
|
#define __GPTSTRUCTS
|
||||||
|
|
||||||
#define GPTFDISK_VERSION "0.6.11-pre3"
|
#define GPTFDISK_VERSION "0.6.11"
|
||||||
|
|
||||||
// Constants used by GPTData::PartsToMBR(). MBR_EMPTY must be the lowest-
|
// Constants used by GPTData::PartsToMBR(). MBR_EMPTY must be the lowest-
|
||||||
// numbered value to refer to partition numbers. (Most will be 0 or positive,
|
// numbered value to refer to partition numbers. (Most will be 0 or positive,
|
||||||
|
|||||||
@@ -106,7 +106,7 @@ void GPTPart::SetName(const string & theName) {
|
|||||||
junk = fgets(newName, NAME_SIZE / 2, stdin);
|
junk = fgets(newName, NAME_SIZE / 2, stdin);
|
||||||
|
|
||||||
// Input is likely to include a newline, so remove it....
|
// Input is likely to include a newline, so remove it....
|
||||||
i = strlen(newName);
|
i = (int) strlen(newName);
|
||||||
if ((i > 0) && (i <= NAME_SIZE))
|
if ((i > 0) && (i <= NAME_SIZE))
|
||||||
if (newName[i - 1] == '\n')
|
if (newName[i - 1] == '\n')
|
||||||
newName[i - 1] = '\0';
|
newName[i - 1] = '\0';
|
||||||
|
|||||||
2
guid.cc
2
guid.cc
@@ -24,7 +24,7 @@
|
|||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
GUIDData::GUIDData(void) {
|
GUIDData::GUIDData(void) {
|
||||||
srand(time(0));
|
srand((unsigned int) time(0));
|
||||||
Zero();
|
Zero();
|
||||||
} // constructor
|
} // constructor
|
||||||
|
|
||||||
|
|||||||
14
sgdisk.8
14
sgdisk.8
@@ -1,6 +1,6 @@
|
|||||||
.\" Copyright 2010 Roderick W. Smith (rodsmith@rodsbooks.com)
|
.\" Copyright 2010 Roderick W. Smith (rodsmith@rodsbooks.com)
|
||||||
.\" May be distributed under the GNU General Public License
|
.\" May be distributed under the GNU General Public License
|
||||||
.TH "SGDISK" "8" "0.6.10" "Roderick W. Smith" "GPT fdisk Manual"
|
.TH "SGDISK" "8" "0.6.11" "Roderick W. Smith" "GPT fdisk Manual"
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
sgdisk \- Command\-line GUID partition table (GPT) manipulator for Linux and Unix
|
sgdisk \- Command\-line GUID partition table (GPT) manipulator for Linux and Unix
|
||||||
.SH "SYNOPSIS"
|
.SH "SYNOPSIS"
|
||||||
@@ -235,7 +235,17 @@ sectors are available, this function returns the value 0.
|
|||||||
Displays the sector number of the start of the largest available block of
|
Displays the sector number of the start of the largest available block of
|
||||||
sectors on the disk. A script may store this value and pass it back as
|
sectors on the disk. A script may store this value and pass it back as
|
||||||
part of \fI\-n\fR's option to create a partition. If no unallocated
|
part of \fI\-n\fR's option to create a partition. If no unallocated
|
||||||
sectors are available, this function returns the value 0.
|
sectors are available, this function returns the value 0. Note that this
|
||||||
|
parameter is blind to partition alignment; when you actually create a
|
||||||
|
partition, its start point might be changed from this value.
|
||||||
|
|
||||||
|
.TP
|
||||||
|
.B \-F, \-\-first\-aligned\-in\-largest
|
||||||
|
Similar to \fI\-f\fR (\fI\-\-first\-in\-largest\fR), except returns the
|
||||||
|
sector number with the current alignment correction applied. Use this
|
||||||
|
function if you need to compute the actual partition start point rather
|
||||||
|
than a theoretical start point or the actual start point if you set the
|
||||||
|
alignment value to 1.
|
||||||
|
|
||||||
.TP
|
.TP
|
||||||
.B \-g, \-\-mbrtogpt
|
.B \-g, \-\-mbrtogpt
|
||||||
|
|||||||
@@ -251,10 +251,10 @@ uint64_t GetInt(const string & argument, int itemNum) {
|
|||||||
|
|
||||||
while (itemNum-- > 0) {
|
while (itemNum-- > 0) {
|
||||||
startPos = endPos + 1;
|
startPos = endPos + 1;
|
||||||
endPos = argument.find(':', startPos);
|
endPos = (int) argument.find(':', startPos);
|
||||||
}
|
}
|
||||||
if (endPos == (int) string::npos)
|
if (endPos == (int) string::npos)
|
||||||
endPos = argument.length();
|
endPos = (int) argument.length();
|
||||||
endPos--;
|
endPos--;
|
||||||
|
|
||||||
istringstream inString(argument.substr(startPos, endPos - startPos + 1));
|
istringstream inString(argument.substr(startPos, endPos - startPos + 1));
|
||||||
@@ -268,10 +268,10 @@ string GetString(const string & argument, int itemNum) {
|
|||||||
|
|
||||||
while (itemNum-- > 0) {
|
while (itemNum-- > 0) {
|
||||||
startPos = endPos + 1;
|
startPos = endPos + 1;
|
||||||
endPos = argument.find(':', startPos);
|
endPos = (int) argument.find(':', startPos);
|
||||||
}
|
}
|
||||||
if (endPos == (int) string::npos)
|
if (endPos == (int) string::npos)
|
||||||
endPos = argument.length();
|
endPos = (int) argument.length();
|
||||||
endPos--;
|
endPos--;
|
||||||
|
|
||||||
return argument.substr(startPos, endPos - startPos + 1);
|
return argument.substr(startPos, endPos - startPos + 1);
|
||||||
|
|||||||
Reference in New Issue
Block a user