head	1.8;
access;
symbols;
locks; strict;
comment	@# @;


1.8
date	2002.07.09.08.29.19;	author rse;	state dead;
branches;
next	1.7;

1.7
date	2002.07.08.13.45.13;	author rse;	state Exp;
branches;
next	1.6;

1.6
date	2002.07.05.17.30.23;	author rse;	state Exp;
branches;
next	1.5;

1.5
date	2002.07.05.15.32.42;	author rse;	state Exp;
branches;
next	1.4;

1.4
date	2002.07.04.14.51.21;	author rse;	state Exp;
branches;
next	1.3;

1.3
date	2002.07.04.12.30.46;	author rse;	state Exp;
branches;
next	1.2;

1.2
date	2002.07.04.06.16.13;	author rse;	state Exp;
branches;
next	1.1;

1.1
date	2002.07.03.13.25.34;	author rse;	state Exp;
branches;
next	;


desc
@@


1.8
log
@add standard OSSP autoconf/libtool/shtool environment
@
text
@
CC     = /usr/opkg/bin/gcc
CFLAGS = -pipe -O0 -g -ggdb3 \
		 -ansi -pedantic -Wall \
		 -Wmultichar -Wno-system-headers -Wtraditional \
		 -Wshadow -Wpointer-arith \
         -Wbad-function-cast -Wcast-align \
		 -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations \
         -Wredundant-decls -Wnested-externs -Winline \
		 -DDMALLOCx -I/usr/opkg/include
#CFLAGS = -Wundef -W -Wconversion -Wfloat-equal -Wunreachable-code -Wwrite-strings 
LDFLAGS = -L/usr/opkg/lib
LIBS    = # -ldmalloc
AR     = ar
RANLIB = ranlib
RM     = rm -f
BISON  = bison
FLEX   = flex-beta
GDB    = gdb

LIB    = libcfg.a
OBJ    = cfg_buf.o cfg_grid.o cfg_data.o cfg_node.o cfg_fmt.o cfg_syn.o cfg_syn_parse.o cfg_syn_scan.o cfg_util.o
TST    = cfg_test

all: $(LIB) $(TST)

.c.o:
	$(CC) $(CFLAGS) -c $<

cfg_syn.c: cfg_syn.h cfg_syn_parse.h
cfg_syn_scan.o: cfg_syn_scan.c cfg_syn_parse.h
cfg_syn_scan.c: cfg_syn_scan.l
	$(FLEX) -Pcfg_syn_ -s -8 -B -ocfg_syn_scan.c cfg_syn_scan.l
cfg_syn_parse.c cfg_syn_parse.h: cfg_syn_parse.y
	$(BISON) -d -k -pcfg_syn_ -ocfg_syn_parse.c cfg_syn_parse.y

$(LIB): $(OBJ)
	$(AR) rc $(LIB) $(OBJ)
	$(RANLIB) $(LIB)

$(TST): $(TST).o $(LIB)
	$(CC) $(LDFLAGS) -o $(TST) $(TST).o $(LIB) $(LIBS)

clean:
	$(RM) $(LIB)
	$(RM) $(OBJ)
	$(RM) $(TST).o $(TST)
	$(RM) core *.core *.aux *.log
	$(RM) cfg_syn_parse.c cfg_syn_parse.h
	$(RM) cfg_syn_scan.c

check: test
test: $(TST)
	./$(TST) sample.cfg
	./$(TST) sample2.cfg

debug: $(TST)
	$(GDB) $(TST)

@


1.7
log
@add more error checking
@
text
@@


1.6
log
@update
@
text
@d19 1
d56 3
@


1.5
log
@thanks to Dmalloc we can fix the memory holes
@
text
@d54 1
@


1.4
log
@Flush today's work: the library is now able to parse a .cfg file into
an internal node tree and export this again in textual .cfg file format
(including indented blocks).
@
text
@d9 2
a10 1
         -Wredundant-decls -Wnested-externs -Winline
d12 2
d41 1
a41 1
	$(CC) -o $(TST) $(TST).o $(LIB)
@


1.3
log
@activate cfg_buf stuff
@
text
@d3 1
a3 1
CFLAGS = -pipe -O2 -g -ggdb3 \
@


1.2
log
@split out cfg_data_t stuff into seperate object to get better abstraction for this
@
text
@d18 1
a18 1
OBJ    = cfg_grid.o cfg_data.o cfg_node.o cfg_fmt.o cfg_syn.o cfg_syn_parse.o cfg_syn_scan.o cfg_util.o
@


1.1
log
@Add this first cut for the forthcoming OSSP cfg library to CVS.
This is work in progress and still not ready for use anywhere.
@
text
@d18 1
a18 1
OBJ    = cfg_grid.o cfg_node.o cfg_fmt.o cfg_syn.o cfg_syn_parse.o cfg_syn_scan.o cfg_util.o
@

