Thread overview | ||||||||
---|---|---|---|---|---|---|---|---|
|
November 20, 2004 Makefile Syntax | ||||
---|---|---|---|---|
| ||||
What is the Syntax of makefiles in D ?? I bet similiar as in C++ but I would really like to c some examples or a tutorial regards, Oliver Kania |
November 20, 2004 Re: Makefile Syntax | ||||
---|---|---|---|---|
| ||||
Posted in reply to Oliver Kania | "Oliver Kania" <Oliver_member@pathlink.com> a écrit dans le message de news: cnoepb$1s8p$1@digitaldaemon.com... > What is the Syntax of makefiles in D ?? > I bet similiar as in C++ but I would really like to c some examples > or a tutorial For exemple, for an OpenGL demo that displays flying birds, with files demo.d and birds.d : MAIN=demo OBJS=birds.obj LIBS=opengl32.lib glu32.lib glut32.lib DFLAGS=-g DC=c:\dmd\bin\dmd $(MAIN).exe: $(MAIN).obj $(OBJS) $(DC) $(MAIN).obj $(OBJS) $(LIBS) .d.obj: $(DC) $(DFLAGS) -c $< all: $(MAIN).exe test: $(MAIN).exe clean: del *.obj *.map In my editor (SciTE) I bind the 'build' command to 'make' and the 'go' command to 'make run'. |
November 21, 2004 Re: Makefile Syntax | ||||
---|---|---|---|---|
| ||||
Posted in reply to Valéry Croizier | Thx Valery ! I have more questions concerning the environment varialbles and will start a new thread 4 this. Is there an official makefile documentation ? Regards, Oliver In article <cnogl4$1v89$1@digitaldaemon.com>, Valéry Croizier says... > >"Oliver Kania" <Oliver_member@pathlink.com> a écrit dans le message de news: cnoepb$1s8p$1@digitaldaemon.com... >> What is the Syntax of makefiles in D ?? >> I bet similiar as in C++ but I would really like to c some examples >> or a tutorial > >For exemple, for an OpenGL demo that displays flying birds, with files demo.d and birds.d : > >MAIN=demo >OBJS=birds.obj >LIBS=opengl32.lib glu32.lib glut32.lib >DFLAGS=-g >DC=c:\dmd\bin\dmd > >$(MAIN).exe: $(MAIN).obj $(OBJS) > $(DC) $(MAIN).obj $(OBJS) $(LIBS) > >.d.obj: > $(DC) $(DFLAGS) -c $< > >all: $(MAIN).exe > >test: > $(MAIN).exe > >clean: > del *.obj *.map > >In my editor (SciTE) I bind the 'build' command to 'make' and the 'go' >command to 'make run'. > > |
November 21, 2004 Re: Makefile Syntax | ||||
---|---|---|---|---|
| ||||
Posted in reply to Valéry Croizier | Hi ! Looking closer I do not understand the following passage : >.d.obj: > $(DC) $(DFLAGS) -c $< Is this a general rule to make Objects ? Where are the names of the sourcefiles ? (I have some esp. with C++ makefiles under Linux but this seems different) Regards, Oliver In article <cnogl4$1v89$1@digitaldaemon.com>, Valéry Croizier says... > >"Oliver Kania" <Oliver_member@pathlink.com> a écrit dans le message de news: cnoepb$1s8p$1@digitaldaemon.com... >> What is the Syntax of makefiles in D ?? >> I bet similiar as in C++ but I would really like to c some examples >> or a tutorial > >For exemple, for an OpenGL demo that displays flying birds, with files demo.d and birds.d : > >MAIN=demo >OBJS=birds.obj >LIBS=opengl32.lib glu32.lib glut32.lib >DFLAGS=-g >DC=c:\dmd\bin\dmd > >$(MAIN).exe: $(MAIN).obj $(OBJS) > $(DC) $(MAIN).obj $(OBJS) $(LIBS) > >.d.obj: > $(DC) $(DFLAGS) -c $< > >all: $(MAIN).exe > >test: > $(MAIN).exe > >clean: > del *.obj *.map > >In my editor (SciTE) I bind the 'build' command to 'make' and the 'go' >command to 'make run'. > > |
November 21, 2004 Re: Makefile Syntax | ||||
---|---|---|---|---|
| ||||
Posted in reply to Oliver Kania | Oliver Kania wrote: > Is there an official makefile documentation ? You mean this? http://www.digitalmars.com/ctg/make.html -- Justin (a/k/a jcc7) http://jcc_7.tripod.com/d/ |
November 21, 2004 Re: Makefile Syntax | ||||
---|---|---|---|---|
| ||||
Posted in reply to J C Calvarese | I see that the DMD make is limited in capabilities when compared to gnu make. For some advanced commands, I use following win32 port of gnu make. Its pretty powerful, I like it. http://unxutils.sourceforge.net/ Good luck Sai |
Copyright © 1999-2021 by the D Language Foundation