• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

mguiddy

Recruit
23 Badges
Aug 30, 2013
1
0
  • Crusader Kings II
  • Knights of Pen and Paper +1 Edition
  • Magicka
  • The Showdown Effect
  • Pillars of Eternity
  • Prison Architect
  • Cities in Motion 2
  • Shadowrun: Hong Kong
  • Shadowrun: Dragonfall
  • Shadowrun Returns
  • Age of Wonders III
  • Tyranny: Archon Edition
  • Crusader Kings II: Horse Lords
  • Magicka 2
  • Mount & Blade: Warband
  • Magicka: Wizard Wars Founder Wizard
  • Warlock: Master of the Arcane
  • Teleglitch: Die More Edition
  • Lead and Gold
  • Dungeonland
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
Hello all,

I've been wanting to try this game out for a while but it wasn't in my budget until today with the Humble Sale.
I found one bug in the game that a lot of games on linux seem to suffer from that will become more apparent when/if 64-bit inodes become standard. I tried searching a bit but didn't find this posted already, if it was, feel free to crucify me. :)

TL;DR
Crusader Kings II cannot see/write to drives that use 64-bit inodes.
Because of this the game crashes with "terminate called after throwing an instance of 'CFileException'"
Work around is to move the "$HOME/Documents/Paradox Interactive" directory to a drive that uses 32-bit inodes and create a sym-link to the above path.

Anywho, the long version:

I redeemed the game on Steam and installed.
Tried launching, nothing happened.
Tried launching through the terminal, saw that the game was crashing with the above error.
Googled, found the error to be connected to filename case with mods.
Found that the game is supposed to create a log file in the above directory, but mine was empty.
As I've encountered this issue with 64-bit inodes in several games, I had a hunch that it might be the issue.
Tested the work around and found that it was the issue.

I just wanted to post this here to help anyone else out that might have the same issue.
 

Jeltz

Major
50 Badges
Oct 21, 2012
728
1
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Pre-order
  • Crusader Kings II
  • Europa Universalis IV: Res Publica
  • Knights of Pen and Paper +1 Edition
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Europa Universalis IV: Art of War
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Third Rome
  • Stellaris: Synthetic Dawn
  • Tyranny - Tales from the Tiers
  • Europa Universalis IV: Cradle of Civilization
  • Crusader Kings II: Jade Dragon
  • Stellaris: Lithoids
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris - Path to Destruction bundle
  • Crusader Kings II: Monks and Mystics
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Tyranny: Archon Edition
  • Europa Universalis IV: Rights of Man
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Stellaris
  • Crusader Kings II: Conclave
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: El Dorado
  • 500k Club
EDIT: Actually it seems trivial to fix. Just define _FILE_OFFSET_BITS to 64 and then check for compiler warnings if you used int where you should have used another type like off_t or ino_t.

http://en.wikipedia.org/wiki/Stat_(system_call)

This should also fix it for Mac if they at some point start using 64-bit inodes. I have not tested if this works anywhere since I do not have a 32-bit build environment installed.

OLD STUFF:

Wouldn't fixing this mean replacing all calls to of stat(), fstat(), lstat() with stat64(), fstat64(), lstat64()? Even in third party libraries like PhysicsFS. I guess it is necessary to do to be future proof since soon we will probably see more and more uses of 64bit inodes.

If I get off my lazy ass I might write a patch for PhysicsFS for this, but then I have to investigate which platforms stat64 is available on or learn how detecting language features in CMake works.
 
Last edited: