blob: 8eb0795b335afb26fd700b3da9cb26c01b7336e7 [file] [log] [blame]
Michael Clark4504df72007-03-13 08:26:20 +00001Building on Unix with gcc and autotools
2
Jehiah Czebotarc096f5a2011-01-14 18:02:00 +00003If checking out from SVN (http://svn.metaparadigm.com/svn/json-c/trunk) or Git (https://github.com/jehiah/json-c):
Michael Clark4504df72007-03-13 08:26:20 +00004
Jehiah Czebotarc096f5a2011-01-14 18:02:00 +00005 $ sh autogen.sh
Michael Clark4504df72007-03-13 08:26:20 +00006
Jehiah Czebotarc096f5a2011-01-14 18:02:00 +00007Then
Michael Clark4504df72007-03-13 08:26:20 +00008
Jehiah Czebotarc096f5a2011-01-14 18:02:00 +00009 $ ./configure
10 $ make
11 $ make install
Michael Clark4504df72007-03-13 08:26:20 +000012
Jehiah Czebotarc096f5a2011-01-14 18:02:00 +000013To build and run the test programs run
Michael Clark4504df72007-03-13 08:26:20 +000014
Jehiah Czebotarc096f5a2011-01-14 18:02:00 +000015 $ make check
Michael Clark4504df72007-03-13 08:26:20 +000016
17Linking to libjson
18
19If your system has pkgconfig then you can just add this to your makefile
20
21CFLAGS += $(shell pkg-config --cflags json)
22LDFLAGS += $(shell pkg-config --libs json)