| 1 | NAME = libnet |
|---|
| 2 | VERSION = 1.1.5 |
|---|
| 3 | CATEGORIES = lib |
|---|
| 4 | |
|---|
| 5 | DESCRIPTION = The libnet packet construction library |
|---|
| 6 | define BLURB |
|---|
| 7 | Libnet is a high-level API (toolkit) allowing the application programmer to |
|---|
| 8 | construct and inject network packets. It provides a portable and simplified |
|---|
| 9 | interface for low-level network packet shaping, handling and injection. |
|---|
| 10 | Libnet hides much of the tedium of packet creation from the application |
|---|
| 11 | programmer such as multiplexing, buffer management, arcane packet header |
|---|
| 12 | information, byte-ordering, OS-dependent issues, and much more. |
|---|
| 13 | Libnet features portable packet creation interfaces at both the IP-layer |
|---|
| 14 | and link-layer, as well as a host of supplementary and complementary |
|---|
| 15 | functionality. |
|---|
| 16 | endef |
|---|
| 17 | |
|---|
| 18 | SF_PROJ = libnet-dev |
|---|
| 19 | MASTER_SITES = $(SF_MIRROR) |
|---|
| 20 | DISTFILES = $(NAME)-$(VERSION).tar.gz |
|---|
| 21 | DISTFILES += libnet.so.1.0.2.i |
|---|
| 22 | DISTFILES += libnet.so.1.0.2.s |
|---|
| 23 | PATCHFILES = 0001-Fix-missing-uint-instead-of-u_int.patch |
|---|
| 24 | |
|---|
| 25 | LICENSE = doc/COPYING |
|---|
| 26 | |
|---|
| 27 | VENDOR_URL = http://github.com/sam-github/libnet |
|---|
| 28 | |
|---|
| 29 | PACKAGES += CSWlibnet |
|---|
| 30 | SPKG_DESC_CSWlibnet = Libnet package construction library (legacy), libnet.so |
|---|
| 31 | SPKG_VERSION_CSWlibnet = 1.0.2a |
|---|
| 32 | PKGFILES_CSWlibnet += $(libdir)/libnet.so |
|---|
| 33 | PKGFILES_CSWlibnet += $(libdir)/libnet.so.1.0.2 |
|---|
| 34 | |
|---|
| 35 | # These overrides are for the legacy library which should just |
|---|
| 36 | # stay the way it is. |
|---|
| 37 | CHECKPKG_OVERRIDES_CSWlibnet += shared-lib-package-contains-so-symlink|file=/opt/csw/lib/libnet.so |
|---|
| 38 | CHECKPKG_OVERRIDES_CSWlibnet += bad-rpath-entry |
|---|
| 39 | CHECKPKG_OVERRIDES_CSWlibnet += shared-lib-pkgname-mismatch|file=opt/csw/lib/libnet.so.1.0.2|soname=libnet.so.1.0.2|pkgname=CSWlibnet|expected=CSWlibnet1-0-2 |
|---|
| 40 | CHECKPKG_OVERRIDES_CSWlibnet += shared-lib-package-contains-so-symlink|file=/opt/csw/lib/libnet.so |
|---|
| 41 | |
|---|
| 42 | PACKAGES += CSWlibnet1 |
|---|
| 43 | SPKG_DESC_CSWlibnet1 = Libnet package construction library, libnet.so.1 |
|---|
| 44 | # Explicitly do *not* include libnet.so.1.0.2 |
|---|
| 45 | PKGFILES_CSWlibnet1 = $(call baseisadirs,$(libdir),libnet\.so\.1) |
|---|
| 46 | PKGFILES_CSWlibnet1 += $(call baseisadirs,$(libdir),libnet\.so\.1\.6(\.\d+)*) |
|---|
| 47 | |
|---|
| 48 | PACKAGES += CSWlibnet-dev |
|---|
| 49 | SPKG_DESC_CSWlibnet-dev = Development files for libnet.so.1 |
|---|
| 50 | # PKGFILES is catchall |
|---|
| 51 | # The general layout of CSWlibnet-dev is non-standard. Please see here for a rationale: |
|---|
| 52 | # http://wiki.opencsw.org/project-libnet |
|---|
| 53 | RUNTIME_DEP_PKGS_CSWlibnet-dev += CSWlibnet1 |
|---|
| 54 | OBSOLETED_BY_CSWlibnet-dev += CSWlibnetdevel |
|---|
| 55 | CATALOGNAME_CSWlibnetdevel = libnet_devel_stub |
|---|
| 56 | |
|---|
| 57 | BUILD64 = 1 |
|---|
| 58 | |
|---|
| 59 | EXTRA_CONFIGURE_ARGS-32 += LIBNET_CONFIG_LIBS=-L$(libdir)/libnet-new |
|---|
| 60 | EXTRA_CONFIGURE_ARGS-64 += LIBNET_CONFIG_LIBS=-L$(libdir) |
|---|
| 61 | EXTRA_CONFIGURE_ARGS += $(EXTRA_CONFIGURE_ARGS-$(MEMORYMODEL)) |
|---|
| 62 | |
|---|
| 63 | include gar/category.mk |
|---|
| 64 | |
|---|
| 65 | post-install-isa-sparcv8: |
|---|
| 66 | ginstall -d $(DESTDIR)$(libdir) |
|---|
| 67 | cp $(WORKDIR)/libnet.so.1.0.2.s $(DESTDIR)$(libdir)/libnet.so.1.0.2 |
|---|
| 68 | rm $(DESTDIR)$(libdir)/libnet.so |
|---|
| 69 | ln -s libnet.so.1.0.2 $(DESTDIR)$(libdir)/libnet.so |
|---|
| 70 | mkdir $(DESTDIR)$(libdir)/libnet-new |
|---|
| 71 | ln -s ../libnet.so.1 $(DESTDIR)$(libdir)/libnet-new/libnet.so |
|---|
| 72 | @$(MAKECOOKIE) |
|---|
| 73 | |
|---|
| 74 | post-install-isa-i386: |
|---|
| 75 | ginstall -d $(DESTDIR)$(libdir) |
|---|
| 76 | cp $(WORKDIR)/libnet.so.1.0.2.i $(DESTDIR)$(libdir)/libnet.so.1.0.2 |
|---|
| 77 | rm $(DESTDIR)$(libdir)/libnet.so |
|---|
| 78 | ln -s libnet.so.1.0.2 $(DESTDIR)$(libdir)/libnet.so |
|---|
| 79 | mkdir $(DESTDIR)$(libdir)/libnet-new |
|---|
| 80 | ln -s ../libnet.so.1 $(DESTDIR)$(libdir)/libnet-new/libnet.so |
|---|
| 81 | @$(MAKECOOKIE) |
|---|