Comment 8 for bug 279003

Revision history for this message
Colin Watson (cjwatson) wrote :

Thanks for this. Detailed comments follow.

Directly patching anything in the d-i directory in ubiquity is wrong wrong wrong. Don't do it; you'll regret it later. That entire directory is maintained automatically by fetching packages from the corresponding archive, so a Debian build should change d-i/sources.list and run 'debian/rules update'. However, you will immediately run into the fact that several necessary patches to d-i aren't in Debian; for instance, the manual partitioner will be completely broken. Fixing that and other similar problems will need sustained and careful work with the Debian d-i team that I'm afraid is likely to be post-Lenny at this point. Conversely, if you don't sync with Debian, then you'll be using underlying Ubuntu installer code to install Debian, which neither team is likely to be very interested in supporting. The real solution here is a concerted effort from our end (the Ubuntu installer team) to merge Ubuntu changes back into Debian d-i; I intend to have time for that towards the end of this calendar year.

The patch to localechooser is definitely incorrect, as previously described. Those really are supposed to be separate arguments. I believe you that something is broken, but you need to find a different solution as this is not a sensible way to use db_subst.

The patch to console-setup.postinst is probably better done by syncing with Debian's console-setup, as described above.

- if not misc.execute('cp', '-a', log_file, target_log_file):
- syslog.syslog(syslog.LOG_ERR,
- 'Failed to copy installation log file')
- os.chmod(target_log_file, stat.S_IRUSR | stat.S_IWUSR)
+ if os.path.isfile(target_log_file):
+ if not misc.execute('cp', '-a', log_file, target_log_file):
+ syslog.syslog(syslog.LOG_ERR,
+ 'Failed to copy installation log file')
+ os.chmod(target_log_file, stat.S_IRUSR | stat.S_IWUSR)

That's bizarre. Copy the log file only if the *target* exists? I suspect you meant to check os.path.isfile(log_file), which I've applied.

The device mounting stuff is syntactically incorrect ("if not misc.execute('mount', dev, mountpoint)" with no terminating colon) - did you test this? With that fixed, although I'm not sure I understand the need for the losetup stuff, I don't think it'll cause a problem, so I've applied it.

Reconfiguring splashy makes sense, and I've applied that.

xserver-xorg shouldn't be reconfigured here; this should be dealt with by a ubiquity hook in live-initramfs instead to copy the (presumably working) X configuration from the live system. See ubiquity-hooks/20xconfig in Ubuntu's casper package.

initramfs-tools should be dealt with by reconfiguring linux-image-*. If it isn't, I think you should investigate why rather than papering over it here.