[Patch] New Makefile

Technical discussion for those interested in Supermodel development and Model 3 reverse engineering. Prospective contributors welcome.
Forum rules
Keep it classy!

  • No ROM requests or links.
  • Do not ask to be a play tester.
  • Do not ask about release dates.
  • No drama!

Re: [Patch] New Makefile

Postby Kacperas » Thu Sep 28, 2017 1:54 pm

I've updated Harry's makefile, to make it compatible with r666.
Tested under MSYS2 environment running on Windows 10 PRO x64.
Attachments
Makefile.SDL.Win32.GCC.zip
(3.17 KiB) Downloaded 21 times
Kacperas
 
Posts: 40
Joined: Tue Sep 27, 2011 9:35 am

Re: [Patch] New Makefile

Postby Bart » Wed Oct 04, 2017 8:29 am

Kacperas wrote:I've updated Harry's makefile, to make it compatible with r666.
Tested under MSYS2 environment running on Windows 10 PRO x64.


Thanks! I've also in the meantime written a more sane Makefile that has proper dependency tracking. Very tricky but compact and clean. It doesn't require using MSYS2, which has the downside of requiring some things to be tweaked, like SDL path, etc. I'll look at Harry's Makefile again this weekend or next week. I'm thinking that I might be able to use the core of my Makefile as an include for a series of smaller Makefiles for MSYS, command prompt, UNIX, Mac OS. There would be no duplication of the compilation rules and source file lists between these, which should prevent them from getting out of sync whenever I add or rename source files (they would all pull in the same common core Makefile).
User avatar
Bart
Site Admin
 
Posts: 2100
Joined: Thu Sep 01, 2011 2:13 pm
Location: New York City

Re: [Patch] New Makefile

Postby Bart » Wed Oct 04, 2017 7:20 pm

The Makefiles have been replaced. I haven't tested the UNIX or Mac OS X ones yet but they should work. These Makefiles support parallel compilation. I have to add an Msys Makefile but for now, Makefile.Win32 supports gcc from the ordinary command prompt. The top-level OS-dependent Makefiles still need a little bit of editing to set up SDL include paths and the like but they all include the same core Makefile which has saner rules and auto-generation of dependencies. This means parallel compilation is supported:

Code: Select all
make -f Makefiles/Makefile.Win32 -j6


:)

Oh, Ian: I changed Src/Sound/MPEG/audio.c and .h to amp_audio.*.
User avatar
Bart
Site Admin
 
Posts: 2100
Joined: Thu Sep 01, 2011 2:13 pm
Location: New York City

Re: [Patch] New Makefile

Postby Bart » Thu Oct 05, 2017 7:13 am

Some Windows-specific stuff is still in Makefile.inc. I'll fix that tonight.
User avatar
Bart
Site Admin
 
Posts: 2100
Joined: Thu Sep 01, 2011 2:13 pm
Location: New York City

Re: [Patch] New Makefile

Postby Ian » Thu Oct 05, 2017 8:27 am

Bart wrote:Oh, Ian: I changed Src/Sound/MPEG/audio.c and .h to amp_audio.*.


Yeah, I saw :) I'll update the windows build when i have a bit of time
Ian
 
Posts: 1321
Joined: Tue Feb 23, 2016 9:23 am

Re: [Patch] New Makefile

Postby Kacperas » Thu Oct 05, 2017 2:14 pm

Bart wrote:The Makefiles have been replaced. I haven't tested the UNIX or Mac OS X ones yet but they should work. These Makefiles support parallel compilation. I have to add an Msys Makefile but for now, Makefile.Win32 supports gcc from the ordinary command prompt. The top-level OS-dependent Makefiles still need a little bit of editing to set up SDL include paths and the like but they all include the same core Makefile which has saner rules and auto-generation of dependencies.
[...]

I've tested new makefile and I wasn't able to build Supermodel using it... After checking the file, I've noticed, that zlib path wasn't declared, so I've added it to Makefile.Win32 and a proper flag to Makefile.inc.
After these changes, svn build in no time. In any case - big thanks. :)
Kacperas
 
Posts: 40
Joined: Tue Sep 27, 2011 9:35 am

Re: [Patch] New Makefile

Postby Bart » Thu Oct 05, 2017 6:06 pm

Kacperas wrote:
Bart wrote:The Makefiles have been replaced. I haven't tested the UNIX or Mac OS X ones yet but they should work. These Makefiles support parallel compilation. I have to add an Msys Makefile but for now, Makefile.Win32 supports gcc from the ordinary command prompt. The top-level OS-dependent Makefiles still need a little bit of editing to set up SDL include paths and the like but they all include the same core Makefile which has saner rules and auto-generation of dependencies.
[...]

I've tested new makefile and I wasn't able to build Supermodel using it... After checking the file, I've noticed, that zlib path wasn't declared, so I've added it to Makefile.Win32 and a proper flag to Makefile.inc.
After these changes, svn build in no time. In any case - big thanks. :)


Did you add zlib to PLATFORM_CFLAGS and PLATFORM_LDFLAGS? That's probably where any other additions should go but maybe I should add a specific ZLIB_INCLUDE_DIR and ZLIB_LIB_DIR set of variables to make it more obvious? What do you think?
User avatar
Bart
Site Admin
 
Posts: 2100
Joined: Thu Sep 01, 2011 2:13 pm
Location: New York City

Previous

Return to The Dark Room

Who is online

Users browsing this forum: No registered users and 3 guests