EgoMooseOldProjects / Rbx_CustomFont

A custom font management system for Roblox
MIT License
21 stars 17 forks source link

Font Builder Crash on Startup #7

Closed Gskartwii closed 8 years ago

Gskartwii commented 8 years ago

This is what it outputs:

Unhandled Exception: System.TypeInitializationException: The type initializer for 'RbxFontBuilder.Program' threw an exception. ---> System.BadImageFormatException: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)
   at SharpFont.FT.FT_Init_FreeType(IntPtr& alibrary)
   at SharpFont.Library..ctor()
   at RbxFontBuilder.Program..cctor()
   --- End of inner exception stack trace ---
   at RbxFontBuilder.Program.Main(String[] args)

I'm trying to run it on 64-bit Windows 10. I looked the error up online and apparently it appears when an application has been explicitly built for 32-bit systems.

EgoMoose commented 8 years ago

Seems that freetype needs a patch of some sort to work on 64-bit machines. I updated and rebuilt the program with a binary that is said to have the patch already added. If that doesn't work I'll have to look into building freetype with the patch myself.

Gskartwii commented 8 years ago

This time I was able to enter all the data (width, height, size, charset, fonts) but ran into the same error.

Also I recommend you add the "execute" permission to the binaries in the tools directory, so I don't have to do it myself every time I git pull.

EgoMoose commented 8 years ago

Sorry this is a bit of trial and error, but I can't seem to get the same error you're getting. I tried forcing it to run as a 32 bit application try it again and cross your fingers!

Gskartwii commented 8 years ago

It's all right, I'm not in rush.

It's still the same error though. To me it actually looks like a problem with the freetype DLL.

EgoMoose commented 8 years ago

I managed to apply the patch file, but I'm having issues with the makefile. I tried building it using GNU make which is what the freetype's website said to do.

I can honestly say that I put a solid 3 hours into trying to run that f**king program successfully. My conclusion has come to the point that my family and friends have successfully hidden the fact that I'm retarded for years, or windows is being a dip (unfortunately, I think it's just me). Either way I can't seem to build the damn thing and I have only a hobbyist's background in anything CS making some of the conversations on stack overflow incomprehensible.

As is I'm at a bit of a standstill, but I'll keep this issue open well I hopefully figure it out.

Gskartwii commented 8 years ago

I've had my own experiences with compiling programs on Windows and I can definitely tell it's the operating system's fault. I, too, have put hours into trying to build Atom and OpenResty and other stuff to work on Windows, and it turned out unsuccessful. Roblox is actually the only reason I even use Windows anymore.

Anyways, I'll look into it myself.

Gskartwii commented 8 years ago

I managed to build the newest version of FreeType (2.6). I set the PATH to only include MinGW-provided binaries. Older versions didn't work though.

Binary file available on transfer.sh

EgoMoose commented 8 years ago

Awesome! Thanks for the help I'll put you in the credits.