wghost / UPKUtils

Set of utilities to work with UPK files
GNU General Public License v2.0
58 stars 29 forks source link

Silently fails under OSX #1

Closed roryk closed 9 years ago

roryk commented 10 years ago

I built this under OSX and it seems to successfully compile, when I run PatchUPK it looks like it isn't doing anything:

~/cache/UPKUtils/build/PatchUPK Commander\'s\ Choice\ -\ LW.txt /Users/rory/Library/Application\ Support/Steam/SteamApps/common/XCom-Enemy-Unknown/XCOMData/XEW/XComGame/CookedPCConsole/xcomstrategygame.upk
PatchUPK
Installing mod:

Do you have any tips? Thanks!

wghost commented 10 years ago

Path to upk should not include upk name, only path, like XEW/XComGame/CookedPCConsole

Also try using simple file and path names, like PatchUPK mod.txt very/simple/path/no-unicode/no-spaces

roryk commented 10 years ago

Hi @wghost,

Thanks for the reply and for all of your work.

./PatchUPK commander.txt mod/

gives a similar result, as does using the full path. Do you have any other suggestions?

Thanks!

wghost commented 10 years ago

Rename Commander's Choice - LW.txt to something like mod.txt. Copy both PatchUPK and mod.txt to your real existing path-to-xcom/XEW/XComGame/CookedPCConsole folder. Run

./PatchUPK mod.txt

roryk commented 10 years ago

Hi @wghost,

Thanks-- still no love:

pwd -P
/Volumes/Clotho/Users/rory/Library/Application Support/Steam/SteamApps/common/XCom-Enemy-Unknown/XCOMData/XEW/XComGame/CookedPCConsole
./PatchUPK commander.txt
PatchUPK
Installing mod:

I put up a gist, the commander.txt looks well-formed:

https://gist.github.com/roryk/16b3240c12f09d6c9619

roryk commented 10 years ago

Let me know if you have an idea in the code where it might not be working, I can poke around, you have a lot on your plate. If I can get it working I'll help maintain OSX support.

wghost commented 10 years ago

Problem is, I have no idea why it's not giving you even one error message. There are tons of checks and corresponding error messages. For example, wrong path in you first attempt should have resulted in error message "Can't open upk!", but for whatever reason it didn't.

I'm sure I had a message from one of the Mac users about things working perfectly for him. It was about one of the earlier versions, though. The fact, that you see "Installing mod:" message says that mod file and upk file were opened successfully (although, upk file in your first attempt couldn't be opened that's for sure). Probably, some problems with streams and error states. What compiler do you use?

roryk commented 9 years ago

Hi @wghost,

Sorry for the delay; you were right. It compiles fine with clang, but fails silently. Switching to gcc-4.9 worked like a charm. Thanks so much.