add some hardware info for soekris net4801
[openwrt.git] / openwrt / package / libnet / Makefile
1 # $Id$
2
3 include $(TOPDIR)/rules.mk
4
5 PKG_NAME:=libnet
6 PKG_VERSION:=1.0.2a
7 PKG_RELEASE:=7
8 PKG_MD5SUM:=ddf53f0f484184390e8c2a1bd0853667
9
10 PKG_SOURCE_URL:=http://www.packetfactory.net/libnet/dist/deprecated/
11 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
12 PKG_CAT:=zcat
13
14 PKG_BUILD_DIR:=$(BUILD_DIR)/Libnet-$(PKG_VERSION)
15 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
16
17 include $(TOPDIR)/package/rules.mk
18
19 $(eval $(call PKG_template,LIBNET,libnet,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
20
21 $(PKG_BUILD_DIR)/.configured:
22 (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
23 touch configure.in; \
24 touch include.m4; \
25 touch aclocal.m4; \
26 touch Makefile.in; \
27 touch configure; \
28 $(TARGET_CONFIGURE_OPTS) \
29 CFLAGS="$(TARGET_CFLAGS)" \
30 CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
31 LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
32 ac_libnet_have_pf_packet=yes \
33 ac_cv_lbl_unaligned_fail=no \
34 ac_cv_libnet_endianess=lil \
35 ./configure \
36 --target=$(GNU_TARGET_NAME) \
37 --host=$(GNU_TARGET_NAME) \
38 --build=$(GNU_HOST_NAME) \
39 --program-prefix="" \
40 --program-suffix="" \
41 --prefix=/usr \
42 --exec-prefix=/usr \
43 --bindir=/usr/bin \
44 --datadir=/usr/share \
45 --includedir=/usr/include \
46 --infodir=/usr/share/info \
47 --libdir=/usr/lib \
48 --libexecdir=/usr/lib \
49 --localstatedir=/var \
50 --mandir=/usr/share/man \
51 --sbindir=/usr/sbin \
52 --sysconfdir=/etc \
53 $(DISABLE_NLS) \
54 $(DISABLE_LARGEFILE) \
55 --enable-shared \
56 --enable-static \
57 --with-pf_packet=yes \
58 );
59 touch $@
60
61 $(PKG_BUILD_DIR)/.built:
62 rm -rf $(PKG_INSTALL_DIR)
63 mkdir -p $(PKG_INSTALL_DIR)
64 $(MAKE) -C $(PKG_BUILD_DIR) \
65 $(TARGET_CONFIGURE_OPTS) \
66 CFLAGS="$(TARGET_CFLAGS)" \
67 DESTDIR="$(PKG_INSTALL_DIR)" \
68 all install
69 touch $@
70
71 $(IPKG_LIBNET):
72 install -m0755 -d $(IDIR_LIBNET)/usr/lib
73 cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libnet.so.* $(IDIR_LIBNET)/usr/lib/
74 $(RSTRIP) $(IDIR_LIBNET)
75 $(IPKG_BUILD) $(IDIR_LIBNET) $(PACKAGE_DIR)
76
77 $(STAGING_DIR)/usr/lib/libnet.so: $(PKG_BUILD_DIR)/.built
78 mkdir -p $(STAGING_DIR)/usr/bin
79 cp -fpR $(PKG_INSTALL_DIR)/usr/bin/libnet-config $(STAGING_DIR)/usr/bin/
80 mkdir -p $(STAGING_DIR)/usr/include
81 cp -fpR $(PKG_INSTALL_DIR)/usr/include/libnet* $(STAGING_DIR)/usr/include/
82 mkdir -p $(STAGING_DIR)/usr/lib
83 cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libnet.{a,so*} $(STAGING_DIR)/usr/lib/
84 touch $@
85
86 install-dev: $(STAGING_DIR)/usr/lib/libnet.so
87
88 uninstall-dev:
89 rm -rf \
90 $(STAGING_DIR)/usr/bin/libnet-config \
91 $(STAGING_DIR)/usr/include/libnet* \
92 $(STAGING_DIR)/usr/lib/libnet.{a,so*} \
93
94 compile: install-dev
95 clean: uninstall-dev
This page took 0.046582 seconds and 5 git commands to generate.