More progress on Parallels

Thanks to Christian Brunschen and the other kind folks at UK-nextstep-users, I’ve got quite a bit further with my OPENSTEP installation. Christian pointed me to a NE-2000 driver which works without issue on the Parallels-installed OPENSTEP system.

Applying Apple’s patches was a little more involved – my first approach was to download them on a Mac, create an ISO image (Apple’s tools can do this:

hdiutil makehybrid -iso -o OS42patches.iso OS4patches

rather nicely) then put the ISO in the virtual CD-ROM drive. While the tarballs unpacked correctly, the package they contained was corrupt. So I downloaded the patch (OS42MachUserPatch4 being the latest one, containing the SVGA driver and the y2k fixes) to a Solaris box, then used FTP to get it over to the OS4.2 PC (now that we’ve got network). This was more successful, and the patch could be installed.

So, now we’re fully patched, pull out the “Default VGA” driver and put in the VBE (VESA local bus) one, using Configure.app. Let’s choose a low resolution for the first boot, just in case; reading Apple’s notes, we should be able to check which modes are available and change at boot time anyway. So I’ve gone for 640x480x8 (i.e. 256 colours) for the first boot… and it hangs here.

This is actually after I typed “VBE Check”=Yes at the boot prompt, and it didn’t show a list of modes…so something’s not quite right with the VESA driver. I’ll leave it overnight in case it decides suddenly to boot, but I think that reverting to Default VGA is, for the moment, the order of the day.

Edit 2006-04-10 17:36 GMT – some history revision, correcting a spelling mistake and therefore pretending I’ve never heard of visual basic for apps :-)

Posted in whatevs | 7 Comments

About NSMailDelivery and Message.framework

I’ve been asked a few times about the NSMailDelivery class by a few people, probably either through a mailing list post I made, or iSendMail. Well, let’s look through iSendMail to see what happens.

Firstly, the iSendMail target includes Message.framework, which is where NSMailDelivery is defined. Now, some clips from the iSendMail.m file:

if([NSMailDelivery hasDeliveryClassBeenConfigured]==NO)
{
//can't send mail...
NSLog(@"Cannot send mail!n");
[pool release];
exit(EXIT_FAILURE);
}

Before I even try to send mails out, I check whether NSMailDelivery is going to work. The clincher is straightforward: if Mail.app can send an email, NSMailDelivery can send an email. There’s no way to configure e.g. a SMTP server programatically (unless you want to delve into Mail.app’s configuration, that is); if you want to do this, consider using PantoMIME which is a more complete message framework. NSMailDelivery is just a convenience class for accessing Mail.app’s message sending capabilities, nothing more. Launch Mail, open a new message, put a To address in and hit Cmd-Shift-D. If it goes, then you can use NSMailDelivery.

NSMutableDictionary *headers=[NSMutableDictionary dictionary];

while((argch=getopt(argc,argv,"f:t:s:"))!=-1)
{
switch(argch)
{
case 'f':
[headers setObject:[NSString stringWithCString:optarg] forKey:@"From"];
break;
case 't':
[headers setObject:[NSString stringWithCString:optarg] forKey:@"To"];
break;
case 's':
[headers setObject:[NSString stringWithCString:optarg] forKey:@"Subject"];
break;
case '?':
default:
usage();
}
}

Headers are defined in a dictionary. Obviously a To header is a requirement, you could probably get away without a Subject. If I wanted to use Mail’s default email address I wouldn’t supply a From header (but I’d use a different delivery method, see below); and if I wanted custom X-Mailer: or whatever, I’d do it here too. Any header which appears here will make it into the resultant mail, and any header not listed here will not be inserted for you.

NSAttributedString *attrMsg;
NSMutableString *msg=[[NSMutableString alloc] init];

//...

attrMsg=[[NSAttributedString alloc] initWithString:msg];

The message must be an attributed string, whether or not you actually use any attributes. But unless you choose a send a MIME message, any attribute you do use will be lost, read on…

mailSent=[NSMailDelivery deliverMessage:attrMsg headers:headers format:NSASCIIMailFormat protocol:nil];

if(mailSent==YES)
{
NSLog(@"Mail sent successfully.n");
}
else
{
NSLog(@"Mail delivery failed!n");
}

a few things to note about the delivery line. Firstly, observe that all of these methods we’re using are class methods, not instance methods; I never instantiate anything from Message.framework. If I hadn’t set a From address I could have used +deliverMessage:subject:to: but then could only send an ASCII message (which is all iSendMail does, anyway) and would have had to accept whatever From address was default in Mail.app. If your message atributed string contains formatting information (or MIME attachments :-)) then use NSMIMEMailFormat. protocol may as well always be nil, as your choices are that (which uses the preferred transport protocol, which is SMTP at the moment on Mac OS X) or NSSMTPDeliveryProtocol, which is also SMTP.

Posted in whatevs | 2 Comments

So, here’s the full system:

Networking is the biggest current issue, and replacing the default VGA display with something better would be useful, too. But it works :-)

Oh, and images of the driver disks are available from Apple.

Posted in whatevs | 3 Comments

We’re in! The WindowServer has no graphics glitches that I can see, and it’s time to configure the devices.

Graphics: default VGA. Play it safe :-). We may be able to do something more fancy, but I’d rather check with Parallels before b0rking my install.

Network: ah. The emulated card is a Realtek 8029(AS), and OpenStep doesn’t claim to have support for that. Apparently it’s compatible with the NE-2000, but OpenStep doesn’t have a driver for that either :-(. I need to ask someone with more Intel-version-of-NeXT noodle than I about that…

Sound: we ignored this for the moment.

SCSI: Nope.

So now we’re at the ‘installing additional packages’ stage, I won’t post a screenshot until we’re into the OS.

Posted in whatevs | 1 Comment

And now, the reboot:

it’s been sat there for a while now… :-/

Posted in whatevs | Leave a comment

And now the console is up: a few graphics gremlins but the ATAPI CD-ROM driver is doing its business.

Posted in whatevs | Leave a comment

Wooo! New blog. For the first few posts, this is going to be about my attempts to get OpenStep 4.2 running under parallels VM for Mac. So far, I’ve set up the VM and am wading through the release notes and installation guide. I’ve found that it should be installed without the (virtual) network cable connected, so that’s what we do.

Worryingly, the install notes say that we require a SCSI CD-ROM, but Parallels only provides an IDE one. I don’t know how that will pan out, I definitely remember one version of NeXTSTEP coming with an IDE CD-ROM driver. Let’s see.

OK, so I’ve got the OpenStep boot floppy up and running (via some failures of NeXTSTEP to provide the necessary device file to dd, and with tremendous thanks to Simon Cozens for lending use of his /dev/fd0), the compatibility BIOS isn’t an issue and the installer dutifully loads:

Now to find the drivers disk…

Posted in whatevs | Leave a comment