View Issue Details

IDProjectCategoryView StatusLast Update
0005260Dwarf FortressTechnical -- Generalpublic2016-07-05 17:49
Reporterpeterb Assigned ToToady One  
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
PlatformMacOSMac OS XOS Version10.7.3
Product Version0.34.02 
Fixed in Version0.43.05 
Summary0005260: Can't play fullscreen on Mac OS X Lion (bug in outdated SDL)
DescriptionWhen you try to take DF fullscreen from the prompt, the following error appears:

Feb 18 10:12:05 smaug.local dwarfort.exe[2246] <Warning>: CGDisplayBaseAddress is obsolete and returning NULL for display 0x42801c0
Steps To Reproduce(1) Set init.txt to PROMPT mode for windows/fullscreen
(2) Start df
(3) Answer "YES" to the fullscreen prompt.
Additional InformationManager's note: Suggested fix: update SDL to SDL 1.2.15
1. Download SDL-1.2.15.dmg from https://www.libsdl.org/download-1.2.php (under Mac OS X). Direct link as of May 2016: https://www.libsdl.org/release/SDL-1.2.15.dmg
2. Open the downloaded .dmg file
3. Replace SDL.framework (possibly displayed as "SDL") in the libs folder in your DF folder with the downloaded version of SDL.framework
TagsFixed in 0.43.05?, SDL

Relationships

related to 0002624 confirmedlethosor Bundled SDL version uses NSQuickDrawView on OS X; deprecated/unavailable in newer versions of OS X 
has duplicate 0006177 resolveduser1294 Fullscreen mode unsupported 
has duplicate 0007822 resolveduser6 Fullscreen is inoperable on Mac 
related to 0007778 acknowledgedlethosor Keyboard input stops working after fullscreen/window toggle (F11) 
related to 0009680 resolvedlethosor Cannot open the df executable. 

Activities

user6

2012-02-18 10:10

  ~0020053

Try changing the PRINT_MODE in init.txt (to STANDARD or whatever).

Necromunger

2012-03-06 14:22

reporter   ~0021187

Does not help at all to change the PRINT_MODE to standard.

The only way i can play is windowed with massive resolution to come close to my screen size.

But making windowed mode exactly my screen sizes crashes the game.

I get an error every time about SDL using the QuickDraw library which is completely depreciated in Mac OS X Lion, it should be using QuartzCore.

This would explain earlier Macs being about to run the game properly, because QuickDraw has not been fully Depreciated on those machines.

philomory

2012-05-27 23:12

reporter   ~0022753

Last edited: 2015-08-15 14:45

I can verify that this can be fixed by using SDL 1.2.15. I was able to substitute the 1.2.15 SDL.framework by placing it into the <DF_ROOT>/libs/ directory in place of the old one, opening terminal to <DF_ROOT>/libs/SDL.framework/Versions/A/, and running `install_name_tool -id @executable_path/../Frameworks/SDL.framework/Versions/A/SDL SDL` After that, Dwarf Fortress could be run in fullscreen without crashing, or indeed without any issues at all.

If toady can compile the next DF release against SDL 1.2.15, that should fix the problem. In the mean time, enterprising users can apply the same fix I did (note that install_name_tool comes with the XCode command line tools package).

(Manager's note: The install_name_tool step may not be necessary.)

peterb

2012-06-08 17:24

reporter   ~0022926

I can confirm that philomory's hack works. It would be great if SDL 1.2.15 was included in the next official MacOS build.

darchitect

2014-07-10 19:02

reporter   ~0025643

This bug still exists in v0.40.02 for OS 10.7.5.

ToadChild

2014-11-07 14:25

reporter   ~0030906

Issue still exists with DF 0.40.15 and OS X 10.10 (Yosemite). The fix from philomory still works.

matthew49

2015-03-09 16:10

reporter   ~0032358

Could someone help me with philomory's trick?

I successfully switched the SDL.framework, put in the terminal line (which I assume had an extra "SDL" at the end), got this:

Usage: /Library/Developer/CommandLineTools/usr/bin/install_name_tool [-change old new] ... [-rpath old new] ... [-add_rpath new] ... [-delete_rpath old] ... [-id name] input


but the problem is still happening. Mar 9 19:08:30 Matthews-MacBook-Pro.local dwarfort.exe[23390] <Warning>: CGDisplayBaseAddress is obsolete and returning NULL for display 0x4280800

I am most likely making a stupid mistake right now as I am new to all of this stuff.

lethosor

2015-03-09 16:30

manager   ~0032361

Last edited: 2015-08-15 14:45

I think it should work without the install_name_tool step (i.e. just replacing SDL.framework should work). Can you provide the command you used?

Edit: There was not an extra "SDL" at the end of the command; it was intentional (but you don't need to run it, as far as I can tell).

ToadChild

2016-03-26 12:32

reporter   ~0034924

I downloaded Dwarf Fortress 0.42.06 (most recent at time of writing) and the game would not even start unless I applied philomory's fix.

Mac OS X 10.11.3 "El Capitan".

Please update to the latest version of SDL (1.2.15, released in 2012!) when building the Mac version in the future.

lethosor

2016-06-29 18:24

manager   ~0035524

May be fixed in 0.43.05, since Toady reports that he is using SDL 1.2.15 now.

lethosor

2016-07-05 17:49

manager   ~0035566

This looks like it's working in 0.43.05 for me. Please PM me on the forums to reopen this report if not.

Issue History

Date Modified Username Field Change
2012-02-18 07:14 peterb New Issue
2012-02-18 10:10 user6 Note Added: 0020053
2012-03-06 14:22 Necromunger Note Added: 0021187
2012-05-27 23:12 philomory Note Added: 0022753
2012-06-08 17:24 peterb Note Added: 0022926
2013-01-03 02:44 user1294 Relationship added has duplicate 0006177
2014-07-10 19:02 darchitect Note Added: 0025643
2014-07-28 17:44 lethosor Tag Attached: SDL
2014-07-28 17:44 lethosor Assigned To => lethosor
2014-07-28 17:44 lethosor Status new => acknowledged
2014-07-28 17:44 lethosor Status acknowledged => confirmed
2014-07-30 19:29 lethosor Summary Can't play fullscreen on Mac OS X Lion => Can't play fullscreen on Mac OS X Lion (bug in outdated SDL)
2014-08-01 05:22 user11 Relationship added related to 0007778
2014-08-04 14:55 user6 Relationship added has duplicate 0007822
2014-11-07 14:25 ToadChild Note Added: 0030906
2015-03-09 16:10 matthew49 Note Added: 0032358
2015-03-09 16:30 lethosor Note Added: 0032361
2015-08-15 14:45 lethosor Note Edited: 0032361
2015-08-15 14:45 lethosor Note Edited: 0022753
2015-10-18 10:54 lethosor Relationship added related to 0002624
2016-03-26 12:32 ToadChild Note Added: 0034924
2016-04-05 10:06 lethosor Relationship added related to 0009680
2016-05-17 16:49 lethosor Additional Information Updated
2016-06-29 18:23 lethosor Tag Attached: Fixed in 0.43.05?
2016-06-29 18:24 lethosor Note Added: 0035524
2016-07-05 17:49 lethosor Note Added: 0035566
2016-07-05 17:49 lethosor Status confirmed => resolved
2016-07-05 17:49 lethosor Fixed in Version => 0.43.05
2016-07-05 17:49 lethosor Resolution open => fixed
2016-07-05 17:49 lethosor Assigned To lethosor => Toady One