• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

SPECS/H05-Apr-2020-3525

benchmark/H05-Apr-2020-318186

debian/H07-May-2022-7554

sljit/H05-Apr-2020-2113

src/H05-Apr-2020-2,5711,798

test/H05-Apr-2020-4,4923,033

.gitignoreH A D05-Apr-2020311 3528

.travis.ymlH A D05-Apr-20201,012 2017

GNUmakefileH A D05-Apr-2020652 2720

LICENCEH A D05-Apr-20201.3 KiB2723

MakefileH A D05-Apr-202091 53

README.mdH A D05-Apr-20201.3 KiB6136

TODOH A D05-Apr-202035 21

README.md

1Just-in-Time Compilation for Berkeley Packet Filter
2===================================================
3
4[![Build Status](https://travis-ci.org/alnsn/bpfjit.svg?branch=master)](https://travis-ci.org/alnsn/bpfjit)
5
6Prerequisites
7-------------
8
9You need sljit (http://sljit.sourceforge.net/) and mk-configure
10(http://sourceforge.net/projects/mk-configure/) to build bpfjit.
11
12It is recommended to use pkgsrc and install devel/mk-configure.
13The pkgsrc guide is available at http://www.netbsd.org/docs/pkgsrc/.
14
15The sljit code must be at revision r313 or newer:
16
17	$ svn co https://svn.code.sf.net/p/sljit/code@r313 sljit
18
19	$ tar cf sljit-r313.tar sljit/
20
21Building
22--------
23
24Extract sljit tarball to sljit/ subdirectory. Make sure you pass
25--keep-old-files (-k) option to tar to keep Makefiles from bpfjit.
26
27	$ cd sljit/
28
29	$ tar kxf /path/to/sljit-r313.tar
30
31Then you can build bpfjit with this command
32
33	$ mkcmake
34
35and install:
36
37	$ export DESTDIR=/path/of/your/choice
38
39	$ env PREFIX=/ mkcmake install
40
41Testing
42-------
43
44	$ export LD_LIBRARY_PATH=${DESTDIR}/lib
45
46	$ cd ${DESTDIR}
47
48	$ ./bin/bpfjit_test
49
50	$ echo $?
51
52You should see zero exit status.
53
54Packages
55--------
56
57Just build the package, install it and link the library using the
58`-lbpfjit` flag.
59* RPM (tested on RHEL/CentOS 7): `make rpm`
60* DEB (tested on Debian 9): `make deb`
61