« Wuhan Direct | Main | The view from the solder station »

Convert .bin + .cue -> .iso on Mac OSX

I had a need recently to convert a .bin/.cue CD Image pair to .iso for mounting on OSX. I was considering writing a quick utility to handle the task, but in the process of researching the file formats, I found BinChunker, a GPL-licensed piece of code that does exactly what I need, simply and directly. The official site has the source code and RedHat RPM's, but if you are on OSX, I did a quick compile of the latest version which you can download here.

Once you download the utility, issue this command from a shell prompt in the directory where you downloaded the file:

sudo cp bchunk /usr/bin/

This will copy the file into a location where the system can find it at will (a.k.a. the path). Then, to convert a .bin/.cue pair to a .iso, you can issue this command:

bchunk myinputfile.bin myinputfile.cue myoutputfile

Short, sweet, and simple — and lightweight too, weighing in at only 20k.

UPDATE: As commenter Frederik has pointed out, this can give a permission denied error if your user account does not have execute permissions on the file. Execute this command after copying the file to /usr/bin/ to solve this problem:

sudo chmod a+x /usr/bin/bchunk

If you are getting a not found error, make sure that /usr/bin/ is in your path. To check this, type echo $PATH and look for /usr/bin/ in the result. If it isn't there, type sudo nano /etc/profile and add /usr/bin; to the PATH=... line. Then press CTRL+x followed by Y to confirm and the enter key to verify the filename to save and exit nano. Then execute source /etc/profile to refresh the path.

TrackBack

TrackBack URL for this entry:
http://jamesnsears.com/mt-tb.cgi/89

Comments (7)

Fredrik:

Wow, that's really great! One problem though; whenever I try to run the command I get a permission denied error, and if I try adding sudo in front my Terminal tells me it can't find bchunk... Any leads?

JC:

Your download link does not work ... opens up a file in the browser with a bunch of junk. Can you zip up the compiled file so it is easier to download.

Gwen:

Thanks for doing this. I'm still dufus when it comes to command line, so it took me a while to figure out the problem when it said 'file not found'. It was because the default directory inside the terminal was not my desktop. Being primarily a GUI user, that's where the files were sitting. I dredged up my old memories of dos (the last time I really used a command line), and was able to change the directory. I don't actually know what the desktop directory is called in OSX, so I type cd /applications/, and moved the files in there. Once I did that, everything went perfectly. Thanks again!

aaron:

I've got all the files into usr/bin now, but when i try the conversion line it says
"-bash: /usr/bin/bchunk: Bad CPU type in executable"

i'm not real sure what bash is, but as far as i can tell i followed the directions

Iluvatar:

This looks like a great utility. It's running now, let's hope it works.

For any non-terminal people, a quick primer on navigation:

The main level of your harddrive is "/"

Your home directory (where your terminal will probably start) is "/Users/YourUserName/"

Your desktop is "/Users/YourUserName/Desktop"

To get to your desktop, just type "cd /Users/YourUserName/Desktop"

Yo make sure that you're in the correct folder, type "ls" to show the contents of the folder you in.

Hope that helps, and it looks like my iso is done.

Thanks for this.. very handy (used it to convert bin/cue to iso so vmware can mount it.. woop)

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)

Verification (needed to reduce spam):

Music

Where am I?

Recent Photos

Powered by
Movable Type 3.35