Running a second program inside a proton prefix.

Sorry for replying to such an old comment, but I needed to A) thank you for leading me to the eventual solution to my own problem, and B) leave my solution here for anyone else who stumbles on this thread as I did.

My issue is getting TrackIR to work in MSFS 2020 (Steam Version).

(There is no hard dependency on the GE proton, you could probably do this with the official protons in Steam. Just listing what I'm using for completeness.)

The problem is like OP said: MSFS only detects TrackIR if TrackIR is running before MSFS launches, but Proton won't launch MSFS if anything else (eg. TrackIR) is running already. So you can't just manually launch TrackIR and then MSFS.

The solution is to essentially intercept Steam's launch command and replace it with your own, that way you can launch as much as you like and you're doing it after Proton has already completed its check to make sure nothing else is running in that prefix.

Solution as follows:

Step 1: Create a .bat file in your Flight Simulator install dir

/path/to/Steam/steamapps/common/MicrosoftFlightSimulator/FlightSimulator.bat:

pushd "C:\Program Files (x86)\Linuxtrack"
start Controller.exe
popd
start cmd
.\FlightSimulator.exe -FastLaunch %*  

pushd changed directory and working directory, and lets you return to where you were easily with popd afterwards

running cmd gives you a command line window where you can re-launch MSFS if (when) it crashes without having to relaunch from steam. Just remove that line if you don't want it. The relaunch command is "FlightSimulator.exe -FastLaunch"

Step 2: Use Steamtinkerlauncher to change the launch command from FlightSimulator.exe to FlightSimulator.bat

Set the compatibility layer for MSFS in Steam to Steamtinkerlaunch and launch the game

Click Main Menu, then when it appears click Game Settings

Enable "Use custom command" and point it at FlightSimulator.bat instead of .exe

Save.

Now whenever you want to play MSFS it's just two steps:

  1. Launch "ltr_gui" from your linux shell and start tracking
  2. Launch MSFS from Steam

If all goes well you should see the "Controller.exe" window pop up, your TrackIR lights should be on, and then MSFS should launch after it.

Holy jesus fuck it took me way too long to arrive at this solution, so if I save even one person this truckload of time I will be happy.

The biggest issue with this approach is just that building Linuxtrack kind of sucks because of the qt4 dependency.

/r/linux_gaming Thread Parent