392 615 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
#
# Add the relocatable flag to indicate whether the lba_low field must
# be respected (0) or whether the image is "position independent" (1).
#
use strict;
use libdb;

sub DoUpdate($$$)
{
    my ($dbhandle, $dbname, $version) = @_;

    if (!DBSlotExists("images", "relocatable")) {
	DBQueryFatal("ALTER TABLE images ADD ".
		     "`relocatable` tinyint(1) NOT NULL default '0' ".
		     "   AFTER lba_size");

	DBQueryFatal("REPLACE INTO table_regex VALUES ".
		     "('images','relocatable','text','redirect',".
		     "'default:boolean',0,0,NULL)");
    }
    return 0;
}

# Local Variables:
# mode:perl
# End: