Dwarf Fortress Bug Tracker - Dwarf Fortress
View Issue Details
0007389Dwarf FortressMiscellaneous Crashespublic2014-07-16 12:422016-06-29 18:26
fricy 
lethosor 
normalcrashalways
confirmedopen 
MacOSX10.8+
0.40.03 
 
0007389: freetype missing on OS X; causes crashes when entering fullscreen and/or starting DF
(Removed partial duplicate of 0005260)
Apple stopped distributing X11 with OS X 10.8+, so players with newer versions of OS X have freetype6.dylib missing from their system, and the game crashes with:
dyld: Library not loaded: /usr/X11R6/lib/libfreetype.6.dylib
  Referenced from: /Users/hlavaczech/Downloads/df_osx/libs/SDL_ttf.framework/Versions/A/SDL_ttf
  Reason: image not found

 Install a clean osx 10.8+ and try to run the game.
Solution that seems to work: 0007389:0032194
Fixed in 0.43.05?
related to 0003263resolved Toady One Mac version unable to load up Dwarf Fortress game at all. 
has duplicate 0005580resolved Dwarfu Crash on Startup on Mountain Lion 
has duplicate 0007309resolved lethosor Dwarf Fortress won't open 
has duplicate 0008595resolved Footkerchief mac version won't run 
has duplicate 0003361resolved Logical2u Error upon trying to open game 
has duplicate 0009009resolved lethosor df will NOT start 
has duplicate 0009431resolved lethosor Mac launch script does not launch DF 
related to 0007638acknowledged Dwarfu switching to/from fullscreen crashes [Win7] 
related to 0002624confirmed lethosor Bundled SDL version uses NSQuickDrawView on OS X; deprecated/unavailable in newer versions of OS X 
Issue History
2014-07-16 12:42fricyNew Issue
2014-07-16 12:42fricyTag Attached: Probable Quick Fix
2014-07-16 12:43fricyTag Attached: OSX
2014-07-16 12:57fricyNote Added: 0026661
2014-07-16 12:58fricyNote Edited: 0026661bug_revision_view_page.php?bugnote_id=0026661#r9938
2014-07-16 13:58FootkerchiefRelationship addedrelated to 0003263
2014-07-17 23:15fricyIssue Monitored: fricy
2014-07-25 06:40lethosorNote Added: 0027488
2014-07-25 07:41fricyNote Added: 0027494
2014-07-25 13:44lethosorNote Added: 0027540
2014-07-25 13:44lethosorNote Edited: 0027540bug_revision_view_page.php?bugnote_id=0027540#r10382
2014-07-26 01:46fricyNote Added: 0027579
2014-07-26 02:02fricyNote Added: 0027581
2014-07-26 08:09DwarfuRelationship addedrelated to 0007638
2014-07-30 19:31lethosorSummaryOSX version of DF crashes when fullscreen, missing freetype6.dylib => freetype6.dylib missing on OS X; causes crashes when entering fullscreen and/or starting DF
2014-07-30 19:32lethosorRelationship addedhas duplicate 0005580
2014-07-30 19:34lethosorNote Added: 0027998
2014-07-30 19:34lethosorAssigned To => lethosor
2014-07-30 19:34lethosorStatusnew => acknowledged
2014-07-30 19:35lethosorSeveritymajor => crash
2014-08-15 13:03ToadChildIssue Monitored: ToadChild
2014-08-26 12:25lethosorStatusacknowledged => confirmed
2014-08-26 13:55lsmouraNote Added: 0029680
2014-08-26 14:05lethosorNote Edited: 0027998bug_revision_view_page.php?bugnote_id=0027998#r11455
2014-08-26 14:08lethosorDescription Updatedbug_revision_view_page.php?rev_id=11457#r11457
2014-08-26 14:21lethosorIssue Monitored: Toady One
2014-11-07 14:19ToadChildNote Added: 0030905
2014-11-22 16:57lethosorRelationship addedparent of 0007309
2014-11-23 04:54lethosorRelationship deletedparent of 0007309
2014-11-23 04:55lethosorRelationship addedhas duplicate 0007309
2014-11-23 04:55lethosorIssue Monitored: Android5217
2014-12-02 21:30FootkerchiefRelationship addedhas duplicate 0008595
2014-12-06 07:09lethosorDescription Updatedbug_revision_view_page.php?rev_id=12489#r12489
2014-12-06 07:11lethosorNote Added: 0031283
2014-12-06 07:11lethosorDescription Updatedbug_revision_view_page.php?rev_id=12490#r12490
2014-12-06 07:18lethosorRelationship addedhas duplicate 0003361
2014-12-18 18:12Madd the SaneNote Added: 0031360
2015-02-09 12:22lethosorNote Added: 0032193
2015-02-09 12:22lethosorNote View State: 0032193: private
2015-02-09 12:25lethosorNote Edited: 0032193bug_revision_view_page.php?bugnote_id=0032193#r12904
2015-02-09 12:25lethosorNote Added: 0032194
2015-02-09 18:32lethosorNote Edited: 0032193bug_revision_view_page.php?bugnote_id=0032193#r12905
2015-07-06 07:52lethosorNote Edited: 0032194bug_revision_view_page.php?bugnote_id=0032194#r13173
2015-07-06 07:52lethosorRelationship addedhas duplicate 0009009
2015-07-06 11:22lethosorTag Detached: OSX
2015-07-06 11:23lethosorDescription Updatedbug_revision_view_page.php?rev_id=13174#r13174
2015-07-06 11:25lethosorDescription Updatedbug_revision_view_page.php?rev_id=13175#r13175
2015-07-06 11:25lethosorSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=13177#r13177
2015-10-18 10:50lethosorNote Edited: 0032194bug_revision_view_page.php?bugnote_id=0032194#r13337
2015-10-18 10:50lethosorNote Edited: 0032194bug_revision_view_page.php?bugnote_id=0032194#r13338
2015-10-18 10:54lethosorRelationship addedrelated to 0002624
2015-10-18 10:56lethosorDescription Updatedbug_revision_view_page.php?rev_id=13339#r13339
2015-10-18 10:56lethosorAdditional Information Updatedbug_revision_view_page.php?rev_id=13341#r13341
2015-10-19 14:19lethosorSummaryfreetype6.dylib missing on OS X; causes crashes when entering fullscreen and/or starting DF => freetype missing on OS X; causes crashes when entering fullscreen and/or starting DF
2015-11-27 14:37lethosorNote Deleted: 0032193
2015-12-26 10:22FootkerchiefTag Detached: Probable Quick Fix
2015-12-26 10:59lethosorAdditional Information Updatedbug_revision_view_page.php?rev_id=13778#r13778
2015-12-28 06:44lethosorRelationship addedhas duplicate 0009431
2016-06-26 09:00lethosorNote Edited: 0032194bug_revision_view_page.php?bugnote_id=0032194#r14309
2016-06-29 18:25lethosorTag Attached: Fixed in 0.43.05?
2016-06-29 18:26lethosorNote Added: 0035526
2016-09-05 07:50lethosorNote Edited: 0035526bug_revision_view_page.php?bugnote_id=0035526#r14453

Notes
(0026661)
fricy   
2014-07-16 12:57   
(edited on: 2014-07-16 12:58)
Related to 0003263, but not quite the same.

(0027488)
lethosor   
2014-07-25 06:40   
Reminder sent to: fricy

Does this occur without DFHack?
(0027494)
fricy   
2014-07-25 07:41   
Ok, a small correction is in order: The "wrong mach-o" message happens only with dfhack, pure vanilla opens a pop-up with missing X11 and instructs you to read this page: http://support.apple.com/kb/HT5293 [^]
If I copy freetype6 to df/libs both versions launch without complain.
Further: Xquartz is 68 mega, freetype is about 1 mega.

I only noticed this problem with dfhack-r5, because freetype was bundled with stonesense in r3, and dfhack/deplibs was refered in the startup script. Relevant conversation: http://goo.gl/RLdA65 [^]

The SDL fullscreen bug is present in both version, df does not CTD, but stops responding with the music playing in the background.

This is on an unmodified 10.9.3, no patches, hotfixes, etc.
(0027540)
lethosor   
2014-07-25 13:44   
Ah, so DFHack blocks the "Download XQuartz" dialog, but the problem occurs either way. For me, the library is located in /usr/X11R6/lib/libfreetype.6.dylib - does copying it into libs/ fix it for you? (Interestingly enough, Freetype is mentioned on the "About DF" screen, so it may be an accidental omission.)

The fullscreen bug is a different, already-reported bug.

(0027579)
fricy   
2014-07-26 01:46   
Freetype is included as a .dll in windows, so I'm sure it's intended to be bundled. Perhaps in pre 10.8 Toady felt that it's already in OSX, so no need to bundle it. This has changed, and that is my point.
About your question: Yes, there is a freetype.6 included default in Mavericks in /usr/X11/lib. No, it does not work if copied into df/libs. The problem is with the dylib, not the path.

This file comes with 10.9.3:

ls -l libfreetype_maverick.6.dylib
-rwxr-xr-x@ 1 fricy staff 25968 Júl 16 20:05 libfreetype_maverick.6.dylib

otool -L libfreetype_maverick.6.dylib
    /usr/X11/lib/libfreetype.6.dylib (compatibility version 15.0.0, current version 15.1.0)
    /usr/X11/lib/libxstub.dylib (compatibility version 1.0.0, current version 1.0.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)

And this is the working one from XQuartz:
ls -l libfreetype.6.dylib
-rwxr-xr-x 1 fricy staff 1089968 Feb 16 2012 libfreetype.6.dylib

otool -L libfreetype.6.dylib
    /usr/X11/lib/libfreetype.6.dylib (compatibility version 14.0.0, current version 14.2.0)
    /usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.5)
    /usr/lib/libbz2.1.0.dylib (compatibility version 1.0.0, current version 1.0.5)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 159.1.0)

I don't know why is it only 25kb, I don't know Apple's reason for this change. I only know that the game from Toady's download page does not work out of the box for newbies, and it's a simple fix.
(0027581)
fricy   
2014-07-26 02:02   
Sorry, the tracker doesn't let me edit the post:
1. This problem goes back 2 years, see: 5580
2. Can't find the bugreport you mentioned above about SDL. Can you help me out?
(0027998)
lethosor   
2014-07-30 19:34   
(edited on: 2014-08-26 14:05)
0005260 is the fullscreen bug. It appears that DF crashes on startup on OS X 10.6 without freetype - copying /usr/X11/lib/libfreetype.6.dylib to DF/libs/libfreetype.6.dylib fixes this problem as well.

Edit: This also eliminates the X11/XQuartz dependency, according to http://www.bay12forums.com/smf/index.php?topic=142925.0 [^]

(0029680)
lsmoura   
2014-08-26 13:55   
Problem still exists on 0.40.10. (tested on OS X 10.9 and 10.10 beta).

Adding libfreetype.6.dylib and replacing SDL.framework to 1.2.15 on the libs folder solves the issue.
(0030905)
ToadChild   
2014-11-07 14:19   
Encountered this with OS X 10.10 (yosemite) and 0.40.15.

This was my first time running DF since my OS upgrade. I have XQuartz installed since before the OS upgrade.

I resolved my issue by copying /opt/X11/lib/libfreetype.6.dylib into the DF directory, as per lethosor's comment. (Note that the source path has changed)
(0031283)
lethosor   
2014-12-06 07:11   
I changed the error message in the description to the one from 0008595. The previous message referenced DFHack, but this isn't DFHack-specific.
(0031360)
Madd the Sane   
2014-12-18 18:12   
Note that you may have to re-install XQuartz if you've upgraded your OS. I had to do this myself.
(0032194)
lethosor   
2015-02-09 12:25   
(edited on: 2016-06-26 09:00)
According to a discussion on Reddit ( http://www.reddit.com/r/dwarffortress/comments/2va09g/help_with_running_df_in_console_on_os_x/cog6wng [^] ), including updated SDL libraries (or at least SDL_ttf from https://www.libsdl.org/projects/SDL_ttf/release/SDL_ttf-2.0.11.dmg [^] , which includes freetype) should fix this. (Despite the version number being "2.0.11", that SDL_ttf build does work with DF, as well as its included freetype library. SDL2_ttf, on the other hand, is only compatible with SDL 2 and will not work with DF.)

To clarify: Download and open https://www.libsdl.org/projects/SDL_ttf/release/SDL_ttf-2.0.11.dmg, [^] and replace the SDL_ttf framework in the "libs" folder in the DF folder with the downloaded copy.

Note: Users who want to try this on OS X 10.5 might need SDL_ttf 2.0.10 instead (thanks to jecowa for researching this).

(0035526)
lethosor   
2016-06-29 18:26   
(edited on: 2016-09-05 07:50)
May be fixed in 0.43.05 - Toady is working on getting a newer SDL_ttf working.

Edit: appears fixed in the 64-bit build, but not in the 32-bit one.