Mercurial > hg > index.cgi
annotate src/Makefile @ 10:36c4cda4b6c4
Add extension support with the PINGPONG extension
Add extension support. There are two ways to add extensions:
1. as a shared object which will be loaded with ext=<filename> as a
parameter to lwwire. See the lwwire_pingpong.c file for details.
2. By doing basically the same thing as a shared object but linking it into
the main binary and calling lwwire_register_extension() appropriately.
author | William Astle <lost@l-w.ca> |
---|---|
date | Sat, 30 Jul 2016 13:16:39 -0600 |
parents | bef2801ac83e |
children | f8226a33698d |
rev | line source |
---|---|
0
bef2801ac83e
Initial checkin with reference implementation of core protocol
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
1 CFLAGS += -Wall |
10
36c4cda4b6c4
Add extension support with the PINGPONG extension
William Astle <lost@l-w.ca>
parents:
0
diff
changeset
|
2 LDLIBS += -ldl -rdynamic |
0
bef2801ac83e
Initial checkin with reference implementation of core protocol
William Astle <lost@l-w.ca>
parents:
diff
changeset
|
3 |
10
36c4cda4b6c4
Add extension support with the PINGPONG extension
William Astle <lost@l-w.ca>
parents:
0
diff
changeset
|
4 all: lwwire lwwire-serial lwwire-pingpong.so |
36c4cda4b6c4
Add extension support with the PINGPONG extension
William Astle <lost@l-w.ca>
parents:
0
diff
changeset
|
5 |
36c4cda4b6c4
Add extension support with the PINGPONG extension
William Astle <lost@l-w.ca>
parents:
0
diff
changeset
|
6 %.so: %.c |
36c4cda4b6c4
Add extension support with the PINGPONG extension
William Astle <lost@l-w.ca>
parents:
0
diff
changeset
|
7 $(CC) $(CPPFLAGS) $(CFLAGS) -fPIC -shared -o $@ $< |