Mostly compiling

This commit is contained in:
Ryan Dahl 2011-03-28 03:26:00 -07:00
parent 151e2a8f0d
commit 6b0d4fa372
3 changed files with 13 additions and 9 deletions

View File

@ -1,12 +1,15 @@
test/echo-server: test/echo-server.c ol.a
gcc -o test/echo-server test/echo-server.c ol.a
$(CC) -o test/echo-server test/echo-server.c ol.a -lm
ol.a: ol-unix.o
ar rcs ol.a ol-unix.o
ol.a: ol-unix.o ev/ev.o
ar rcs ol.a ol-unix.o ev/ev.o
ol-unix.o: ol-unix.c ol.h ol-unix.h
gcc -c ol-unix.c -o ol-unix.o -lm
$(CC) -c ol-unix.c -o ol-unix.o -lm
ev/libev.a: ol-unix.c ol.h ol-unix.h
gcc -c ol-unix.c -o ol-unix.o -lm
ev/ev.o: ev/config.h ev/ev.c
$(MAKE) -C ev
ev/config.h:
cd ev && ./configure

View File

@ -1,8 +1,8 @@
#include "ol.h"
#define EV_STANDALONE 1
#define EV_MULTIPLICITY 0
#include "ev/ev.c"
#include <stdlib.h>
#include <errno.h>
#include <assert.h>
void ol_tcp_io(EV_P_ ev_io* watcher, int revents);

View File

@ -1,5 +1,6 @@
#include "../ol.h"
#include <stdio.h>
#include <stdlib.h>
#define BUFSIZE 1024