![]() |
| | #1 |
| Guest
Posts: n/a
| BSD make and GNU make problem I'm working on a FreeBSD platform, but I'd like to use GNU make. I know that CFLAGS works on BSD make, but how do I specify gcc flags in GNU make? Thanks /Skarr |
|
| | #2 |
| Registered User Join Date: Aug 2001
Posts: 202
| I've got the GNU make manual in front of me, and it lists CFLAGS as one of the variables used in built in rules. Not that I've personally used this feature, but you might be able to use it the same way as your BSD version. starX www.axisoftime.com |
| starX is offline | |
| | #3 |
| Guest
Posts: n/a
| Hmm, doesn't work for me. |
|
| | #4 |
| Registered User Join Date: Jul 2002
Posts: 29
| Could you post a simple Makefile where it works with gmake?
__________________ I like traffic lights. I like traffic lights. I like traffic lights, but only when they're green. |
| Skarr is offline | |
| | #5 |
| Registered User Join Date: Aug 2001
Posts: 202
| This from page 101 of the manual: Code: foo : foo.o bar.o
cc -o foo foo.o bar.o $(CFLAGS) $(LDFLAGS)
Code: CFLAGS = $(include_dirs) -0 include_dirs = -Ifoo -Ibar starX www.axisoftime.com |
| starX is offline | |
![]() |
| Thread Tools | |
| Display Modes | |
|
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Help me understand GNU Make please | yougene | C Programming | 6 | 06-14-2009 07:36 PM |
| Establishing 'make clean' with GNU make | Jesdisciple | C Programming | 9 | 04-11-2009 09:10 AM |
| GNU make - generating dynamic dependencies | OriginalCopy | Linux Programming | 0 | 05-15-2008 10:41 AM |
| how gnu make tells if file's been changed? | thinhare | C Programming | 2 | 03-19-2008 03:10 AM |
| How to make console Mode apps like 'GNU less'? | gibsosmat | C Programming | 4 | 10-31-2007 07:33 AM |