wb1j+@andrew.cmu.edu (William M. Bumgarner) (07/12/89)
Yes, once again, I am having difficulties with writing makefiles to my liking. Only this time, I have complicated things a bit. The environment: MPW, MacAPP, and a program involving not only MacAPP OOP, but also C and TCP/IP code. What I want: I want the MacAPP OOP to stay in one folder all by itself; fine this works. I would like the C code to live in a seperate folder. The big problem is that I want a MABuild mamake file that can deal with this. Why I can't do it: Ok, the OOP is happy enough sitting in the directory that I have it (with the mamake file). But, I have yet to find a way to reference the C-Code as a dependency... ipglue.c.o f ipglue.c # this doesn't work because the c code is not in the same folder with the make file ipglue.c.o f {CSrcDir}ipglue.c # this references the file fine, but doesn't use the MacAPP build stuff to compile the C-Code; it subsequently falls through and tells me it can't find ipglue.c.o I have tried a multitude of other things, including folder dependencies, and other archaic things with no luck. Help me! I'm going insane with this one. BTW: the fact that TCP/IP code is used doesn't really matter BBTW: We are using MPW v3.0 and MacAPP v2.0b9... b.bum wb1j+@andrew.cmu.edu
tim@hoptoad.uucp (Tim Maroney) (07/12/89)
In article <4YialCi00UhW00uEYE@andrew.cmu.edu> wb1j+@andrew.cmu.edu (William M. Bumgarner) writes: >Yes, once again, I am having difficulties with writing makefiles to my >liking. Only this time, I have complicated things a bit. > >What I want: I want the MacAPP OOP to stay in one folder all by itself; >fine this works. I would like the C code to live in a seperate folder. >The big problem is that I want a MABuild mamake file that can deal with >this. > >ipglue.c.o f ipglue.c # this doesn't work because the c code is not in >the same folder with the make file > >ipglue.c.o f {CSrcDir}ipglue.c # this references the file fine, but >doesn't use the MacAPP build stuff to compile the C-Code; it >subsequently falls through and tells me it can't find ipglue.c.o > >I have tried a multitude of other things, including folder dependencies, >and other archaic things with no luck. o = :obj: csrc = ':C source files:' {o}ipglue.c.o f {csrc}ipglue.c {cc} {csrc}ipglue.c -o {o}ipglue.c.o Any chance that this is a TCP/IP implementation I'm familiar with? -- Tim Maroney, Mac Software Consultant, sun!hoptoad!tim, tim@toad.com Postal: 424 Tehama, SF CA 94103; Phone: (415) 495-2934 "A book is the product of a contract with the Devil that inverts the Faustian contract, he'd told Allie. Dr Faustus sacrificed eternity in return for two dozen years of power; the writer agrees to the ruination of his life, and gains (but only if he's lucky) maybe not eternity, but posterity, at least. Either way (this was Jumpy's point) it's the Devil who wins." -- Salman Rushdie, THE SATANIC VERSES
cjp@Apple.COM (Chris Plummer) (07/12/89)
In article <4YialCi00UhW00uEYE@andrew.cmu.edu> wb1j+@andrew.cmu.edu (William M. Bumgarner) writes: >Yes, once again, I am having difficulties with writing makefiles to my >liking. Only this time, I have complicated things a bit. > >The environment: MPW, MacAPP, and a program involving not only MacAPP >OOP, but also C and TCP/IP code. > >What I want: I want the MacAPP OOP to stay in one folder all by itself; >fine this works. I would like the C code to live in a seperate folder. >The big problem is that I want a MABuild mamake file that can deal with >this. > >Why I can't do it: Ok, the OOP is happy enough sitting in the directory >that I have it (with the mamake file). But, I have yet to find a way to >reference the C-Code as a dependency... > >ipglue.c.o f ipglue.c # this doesn't work because the c code is not in >the same folder with the make file > >ipglue.c.o f {CSrcDir}ipglue.c # this references the file fine, but >doesn't use the MacAPP build stuff to compile the C-Code; it >subsequently falls through and tells me it can't find ipglue.c.o > >I have tried a multitude of other things, including folder dependencies, >and other archaic things with no luck. >Help me! I'm going insane with this one. I have a situation similar to yours and I finally managed to get the project set up as follows: projDir: # contains the macapp source and makefile projDir:Obj: # contains the object for the macapp source projDir:cSource: # contains the c source code projDir:cObj: # contains the c object code Make sure you list all objects in "cObj" when setting OtherLinkFiles in the make file. Make sure your pascal object dependencies look as follows: "projDir:Obj:UFoo.p.o" f UFoo.p Make sure you c object dependencies look as follows: "projDir:cObj:cme.c.o" f "projDir:cSource:cme.c" --Chris Plummer