8

I know I can change my wine PATH through regedit, but I actually need to change the PATH just for a single run.

For example, I have my software called frontend.exe, this depends on example/mylib.dll, I need to invoke frontend.exe with example/ on PATH. But I may not set this on the registry be cause this configuration is just for this application, not for every wine application...

9
  • Can you just set it in an environment variable before your run frontend.exe?
    – Gabe
    Aug 30, 2011 at 21:04
  • You mean through a .bat file? Aug 30, 2011 at 21:05
  • 3
    Would be easier if there were a WINEPATH enviroment variable or command line argument because I am calling my wine application from inside a shell script. Aug 30, 2011 at 21:09
  • André, did you manage to solve this (now rather old) problem? Oct 15, 2015 at 21:08
  • @JoachimBreitner Ironically, wine supports the WINEPATH variable. If, in your Unix Shell, you export WINEPATH, once you launch wine it will use this to populate the PATH environment variable inside wine. Oct 16, 2015 at 13:45

1 Answer 1

16

Wine supports the WINEPATH variable. If, in your Unix Shell, you export WINEPATH, once you launch wine it will use this to populate the PATH environment variable inside wine.

Example:

$ WINEPATH=anything\\it//willNotBeParsed wine cmd
Wine CMD Version 5.1.2600 (1.6.2)

C:\>echo %PATH%
anything\it//willNotBeParsed;C:\windows\system32;C:\windows;C:\windows\system32\wbem
2
  • 1
    I know this is old, But I am stuck exporting java jre to wine, I set WINEPATH to /usr/lib/openjdk-8/bin and it went as it is in wine's %PATH% i.e. the unix path not the windows compatible path name. How can I convert it to windows compatible path as environment variable. Jul 30, 2019 at 7:17
  • 1
    @AbhinavKulshreshtha You can use the winepath command line tool, e.g. winepath -w /usr/lib/openjdk-8/bin.
    – s-m-e
    Dec 16, 2019 at 16:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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