freebsd-ports/devel/cocktail/files/patch-cg-m2c-Makefile
Edwin Groothuis 8937ed4066 [PORT UPGRADE] devel/cocktail corrected for 64bits compilation
The orignal port only ran on i386, since there were some
	64bit conversion problems. The included tar file replaces
	the compete devel/cocktail tree currently in the ports tree.

(lots of patches!)

PR:		ports/71940
Submitted by:	Willem Jan Withagen <wjw@withagen.nl>
2004-12-15 04:05:34 +00:00

95 lines
2.2 KiB
Text

--- /usr/ports/devel/cocktail/work/cocktail-9309//./cg/m2c/Makefile Tue Feb 15 14:21:05 1994
+++ ./cg/m2c/Makefile Thu Aug 5 18:48:42 2004
@@ -1,46 +1,38 @@
-BIN = $(HOME)/bin
-LIB = $(HOME)/lib
-OPT = -O
-CC = cc
- # C library (reuse)
-REUSE = ../../reuse/m2c
+.include "../../Makefile.inc"
- # C libraries
-CLIBS = $(REUSE)/libreuse.a
-
- # options for C compiler
-CFLAGS = -w -I$(REUSE) $(OPT)
-
-M2FLAGS = -c -d../../reuse/src
-
-
-all : cg
-
-install: cg cg.sh lpp $(LIB)/cg
- if test $(LIB) = $(BIN); then echo error: BIN = LIB; false; else true; fi
- sed "s;LIB;$(LIB);g" < cg.sh > $(BIN)/cg
- cp $(BIN)/cg $(BIN)/ag
- cp $(BIN)/cg $(BIN)/ast
- chmod a+rx $(BIN)/cg $(BIN)/ast $(BIN)/ag
- install -c -m 755 gmdcpp $(BIN)
- install -c -m 755 gmdupd $(BIN)
- install -c -m 755 gmdrm $(BIN)
- install -c -s -m 755 cg $(LIB)/cg
- install -c -m 644 TypeTab.c $(LIB)/cg
- install -c -m 644 TypeTab.m $(LIB)/cg
- install -c -s -m 755 lpp $(BIN)
+ROOTDIR = ../..
+CFLAGS += -I$(INCDIR)
+CLIBS += $(REUSELIB)
+
+all : cg lpp
+
+install: cg cg.sh lpp $(DESTLIB)/cg
+ if test $(DESTLIB) = $(DESTBIN); then echo error: DESTBIN = DESTLIB; false; else true; fi
+ $(SED) "s;LIB;$(DESTLIB);g" < cg.sh > $(DESTBIN)/cg
+ cp $(DESTBIN)/cg $(DESTBIN)/ag
+ cp $(DESTBIN)/cg $(DESTBIN)/ast
+ chmod a+rx $(DESTBIN)/cg $(DESTBIN)/ast $(DESTBIN)/ag
+ install -c -m 755 gmdcpp $(DESTBIN)
+ install -c -m 755 gmdupd $(DESTBIN)
+ install -c -m 755 gmdrm $(DESTBIN)
+ install -c -s -m 755 cg $(DESTLIB)/cg
+ install -c -m 644 TypeTab.c $(DESTLIB)/cg
+ install -c -m 644 TypeTab.m $(DESTLIB)/cg
+ install -c -s -m 755 lpp $(DESTBIN)
# installation directories
-$(LIB)/cg: $(LIB)
- sh -c "if test ! -d $(LIB)/cg; then mkdir -p $(LIB)/cg; else true; fi"
+$(DESTLIB)/cg: $(DESTLIB)
+ sh -c "if test ! -d $(DESTLIB)/cg; then mkdir -p $(DESTLIB)/cg; else true; fi"
-# SYSTEM_ = SYSTEM_.o
+clean:
+ -rm -f $(STDCLEAN)
+ -rm -f *.o
+ -rm -f cg lpp
lint:
- lint -I$(REUSE) *.c
-
+ lint -I$(INCDIR) *.c
# HEAD
@@ -431,18 +423,3 @@
Tree.o \
$(CLIBS)
-# TAIL
-
-clean :
- rm -f core *.o
-
-.SUFFIXES: .md .mi .h .c .o
-
-.mi.c:
- mtc2 $(M2FLAGS) $*.mi;
-
-.md.h:
- mtc2 $(M2FLAGS) $*.md;
-
-.c.o:
- $(CC) $(CFLAGS) -c $*.c