WineHQ
Wine Forums

Board index » WineHQ » Wine Help




 Page 1 of 1 [ 5 posts ] 



 
Author Message
 Post Posted: Fri Jul 22, 2011 9:25 am 
Offline
Newbie
Newbie
User avatar

Joined: Sun Dec 27, 2009 2:05 am
Posts: 2
Location: Melbourne, Australia
I've been trying to figure this one out for some time now without success and can't find anyone else with this exact problem, so hopefully there's a guru around here that might be able to point me in the right direction.

I've got a copy of Dark Reign I want to play on my netbook. The problem is that I only have a USB CD drive which I don't normally connect, but can for a once-off install. This is one of those weird multi-track CDs where the first track is data and the remaining tracks are normal CD audio... and I want audio in my game. So I ripped the whole image to bin format using AcetoneISO, and can mount that on the loopback (/dev/loop0) fine.
Code:
fdisk -l /dev/loop0
reports the expected size (658Mb) so I don't think there's any issue with the way the image was ripped or looped.

So I've got:
Code:
$ sudo losetup /dev/loop0 dark_reign.bin
$ sudo mount /dev/loop0 /media/loop0


and I configured d: device in winecfg to be type CD-ROM or Autodetect. Either will be sufficient to get the game to run. However, I just can't get CD audio tracks (the background music) working. It does work fine if I insert the disc, let it automount and change the path in winecfg to where it automounted, but as stated I don't always have the drive with me. There must be some way to get wine to recognise these tracks on a loopback device.

I've tried setting various system link configurations under dosdevices based on hints I found via Google. eg:
Code:
c: -> ../drive_c
cdrom0 -> /dev/loop0
d: -> /media/loop0/
d:: -> /dev/loop0
z: -> /

Nothing works.

How do I get Wine or the Linux kernel to make /dev/loop0 appear as a real CD-ROM device so I can hear the audio tracks? Or maybe I'm going about this all wrong?


Top 
 Post subject:
 Post Posted: Fri Jul 22, 2011 12:32 pm 
Offline
Level 8
Level 8

Joined: Wed Oct 29, 2008 4:53 pm
Posts: 1099
Location: Amsterdam, Netherlands
I'm not sure about it, but perhaps the mount command just can't tell if a bin has audio tracks or not? Considering a bin file is still different from an actual CD...


Top 
 Post subject:
 Post Posted: Fri Jul 22, 2011 1:58 pm 
Offline
Level 5
Level 5

Joined: Mon Nov 24, 2008 8:10 am
Posts: 336
I'm not sure if this can work properly using loopback. I would try to use cdemu which emulates a proper fake cd drive.


Top 
 Post Posted: Sat Jul 23, 2011 6:57 am 
Offline
Newbie
Newbie
User avatar

Joined: Sun Dec 27, 2009 2:05 am
Posts: 2
Location: Melbourne, Australia
Thunderbird wrote:
I'm not sure if this can work properly using loopback. I would try to use cdemu which emulates a proper fake cd drive.


Perfect! CDemu was the answer. I'd never heard of it before, and it was a PITA to get it going (no Debian build, multiple packages, various compile errors, a bit of learning how to use it, etc.)... but now it works exactly as it should. Thanks guys!


Top 
 Post subject:
 Post Posted: Tue Jul 26, 2011 1:10 pm 
Offline
Level 5
Level 5
User avatar

Joined: Sun Feb 06, 2011 5:57 am
Posts: 272
Yep. Y'all correct. I go into more detail here: http://forum.winehq.org/viewtopic.php?p=63474&highlight=#63474, which itself has a link to further detail.
Though, Boltronics, I seriously wonder how you managed to compile CDemu from source. Maybe you can pm me?
The reason why audio tracks don't work with the loopback device is because the loopback mounter only mounts a single filesystem. Audio tracks have no filesystem. They contain no files, only almost raw audio data. When you insert an audio CD into Linux, Mac OS X, or Windows, each operating system has its own unique attempt to make it appear as though there are audio files on the CD, but they are all spoofs.
And you can only mount one filesystem by itself with this method per mount. Floppy images are just a single partition formatted to a filesystem without anything else - no mbr, no "track0", nothing else, so they can be mounted directly with the sudo mount command. Iso images work out the same way. With hard drive images, you can only mount one partition in that image with this method (per mount), and you must offset to where the partition begins. BTW, qemu-nbd is a great tool for mounting hard drive images as a block device when the mount command doesn't cut it.

Cheers,
Jake


Top 
Display posts from previous:  Sort by  
 
 Page 1 of 1 [ 5 posts ] 




Board index » WineHQ » Wine Help


Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 8 guests

 
 

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: