Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have eclipse plug-in that was written under windows and uses "C:\" a lot. is there any way to map "C:\" to any chosen dir?

P.S. I do know I can run it under wine, but that is not what I want.

share|improve this question
    
Just out of curiosity, what plugin? –  hbdgaf Apr 9 '12 at 23:25
add comment

2 Answers 2

Assuming that Eclipse has a knowable current directory (maybe where it was launched?), you can just create a directory/soft-link/bind-mount there that is named "C:", and that will solve the first problem.

The next problem is that '\' is not a directory separator on Linux. If you're very lucky there may be translation layer somewhere in Eclipse that fixes that for you, but otherwise, you can just create files with very long file names that look like Windows pathnames. (e.g. C:\WINDOWS\whatever.txt is a perfectly valid filename on Linux.)

Really though, the best thing would be to give the author of the plugin a good beating with a clue bat (ok, submit a bug) - I mean, this won't even work nice on all Windows machines.

If all else fails, edit the plugin with a binary editor, just remember to leave the strings the same length (and hope that nothing does a check-sum).

share|improve this answer
add comment

You may create a file like "C:\boot.ini" on linux in the root directory with root permission, which is not recommendet, but maybe fine on a single user machine.

However, to use the plugin, a file "C:\boot.ini" is searched in the local directory, so you would need symbolic link or copy in every directory from where you try to use the file, since "C:\" is not recognized as a partition.

If there is a directory with multiple files, there is no practical way to use it - get the source of the plugin, if possible, or inform the author.

Absolute paths are a no go for compatible, transferable software. A typical mistake from windows-only-guys.

share|improve this answer
    
How does it work to add /C:\/ to the path? –  Jo-Erlend Schinstad Nov 21 '11 at 15:15
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.