Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make tool #69

Open
andrewbird opened this issue Feb 7, 2019 · 5 comments
Open

Make tool #69

andrewbird opened this issue Feb 7, 2019 · 5 comments

Comments

@andrewbird
Copy link
Contributor

andrewbird commented Feb 7, 2019

I did some experiments a few weeks ago in a test branch with Gnu Make. I find the make currently used on the project somewhat basic, particularly around escaping of the dollar sign. Anyway some good reductions in makefile duplication can be made, the necessity to build files like _x,sys then rename them in DOS to $x.sys can be removed and there are macros for text string manipulation etc. But this does come at a price:

  • I see the build is noticeably slower (rough guess half speed)
  • Since the copy of Gnu Make I have is built with DJGPP it means you need DPMI support on the build platform. So if you don't have that, you'd probably need to load cwsdmpi once after each boot.

For a good comparison of roughly 1/3 code
see the Gmake version
https://github.com/andrewbird/pcmos386/blob/build03/SOURCES/src/jim/term.gmk
and the NDmake version
https://github.com/andrewbird/pcmos386/blob/build03/SOURCES/src/jim/MAKETERM.MAK

What do people think about switching make, it doesn't necessarily have to be Gnu make, perhaps MS nmake or Borland's could be used instead?

Note: please ignore the fact the build is done in the 'jim' directory, and that it isn't rebased off the current master git version.

Edited: formatting

@the-grue
Copy link
Collaborator

the-grue commented Feb 7, 2019

I could get behind that. I also wouldn't mind eventually boiling everything down to one compiler and one assembler. It looks like @galazwoj put some effort into removing Borland C as a requirement. I don't see that any effort has been put into that fork since 2017 though.

The stuff that builds with Borland C may be easy to port or drop altogether as I am finding some of it is specific to v4 (install/hd_setup) and isn't really valid anymore. Effort put into converting it to another compiler and making the changes for v5 and onward might take longer than a rewrite.

For now, I am keeping my copies of Borland and MS documentation handy!

@galazwoj
Copy link

galazwoj commented Feb 7, 2019 via email

@andrewbird
Copy link
Contributor Author

@galazwoj it's good to hear that. I'm not sure about priorities myself, though I believe @the-grue fixed the 2012 date bug, so that's a major success.

@the-grue , you mention MS docs. Do you have documentation for the DOS version of their 'link', as personally I've been struggling with the command line argument object/library/mapfile placements? Searching with Google etc, is difficult as the results seem to be wholly for modern Windows versions.

@galazwoj
Copy link

galazwoj commented Feb 8, 2019 via email

@andrewbird
Copy link
Contributor Author

Oh yes I did use your .lnk files for reference, but I got a little confused regarding comma placement. I think just the single line from your link should help:

LINK objfiles [, [exefile] [, [mapfile] [, [libraries] [, [deffile] ] ] ] ][;]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants