1 include $(TOPDIR
)/rules.mk
6 PKG_MD5SUM
:=56ce3f8cbf5966a0d531c21813320423
8 PKG_SOURCE_URL
:=http
://v6web.litech.org
/radvd
/dist
9 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
10 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
12 PKG_IPK
:=$(PACKAGE_DIR
)/$(PKG_NAME
)_
$(PKG_VERSION
)-$(PKG_RELEASE
)_
$(ARCH
).ipk
13 PKG_IPK_DIR
:=$(PKG_BUILD_DIR
)/ipkg
15 $(DL_DIR
)/$(PKG_SOURCE
):
16 $(SCRIPT_DIR
)/download.pl
$(DL_DIR
) $(PKG_SOURCE
) $(PKG_MD5SUM
) $(PKG_SOURCE_URL
)
18 $(PKG_BUILD_DIR
)/.patched
: $(DL_DIR
)/$(PKG_SOURCE
)
19 $(PKG_CAT
) $(DL_DIR
)/$(PKG_SOURCE
) |
tar -C
$(BUILD_DIR
) $(TAR_OPTIONS
) -
20 $(PATCH
) $(PKG_BUILD_DIR
) .
/patches
21 touch
$(PKG_BUILD_DIR
)/.patched
23 $(PKG_BUILD_DIR
)/.configured
: $(PKG_BUILD_DIR
)/.patched
24 (cd
$(PKG_BUILD_DIR
); rm -rf config.cache
; \
25 $(TARGET_CONFIGURE_OPTS
) \
26 CFLAGS
="$(TARGET_CFLAGS)" \
28 --target
=$(GNU_TARGET_NAME
) \
29 --host
=$(GNU_TARGET_NAME
) \
30 --build
=$(GNU_HOST_NAME
) \
32 --with-logfile
=/tmp
/radvd.log \
33 --with-pidfile
=/tmp
/run
/radvd.pid \
34 --with-configfile
=/etc
/radvd.conf \
36 touch
$(PKG_BUILD_DIR
)/.configured
38 $(PKG_BUILD_DIR
)/$(PKG_NAME
): $(PKG_BUILD_DIR
)/.configured
39 $(MAKE
) $(TARGET_CONFIGURE_OPTS
) LD
=$(TARGET_CC
) LDFLAGS
=-L
$(PKG_BUILD_DIR
) -C
$(PKG_BUILD_DIR
) radvd_LDADD
=""
41 $(PKG_IPK
): $(PKG_BUILD_DIR
)/$(PKG_NAME
)
42 $(SCRIPT_DIR
)/make-ipkg-dir.sh
$(PKG_IPK_DIR
) $(PKG_NAME
).control
$(PKG_VERSION
)-$(PKG_RELEASE
) $(ARCH
)
43 mkdir
-p
$(PKG_IPK_DIR
)/usr
/sbin
$(PKG_IPK_DIR
)/etc
/init.d
44 install -m
755 $(PKG_BUILD_DIR
)/radvd
$(PKG_IPK_DIR
)/usr
/sbin
/
45 install -m
755 $(PKG_BUILD_DIR
)/radvdump
$(PKG_IPK_DIR
)/usr
/sbin
/
46 install -m
755 .
/files
/S51radvd
$(PKG_IPK_DIR
)/etc
/init.d
/
47 install -m
644 .
/files
/radvd.conf.example
$(PKG_IPK_DIR
)/etc
/
48 $(STRIP
) $(PKG_IPK_DIR
)/usr
/sbin
/*
49 mkdir
-p
$(PACKAGE_DIR
)
50 $(IPKG_BUILD
) $(PKG_IPK_DIR
) $(PACKAGE_DIR
)
52 $(IPKG_STATE_DIR
)/info/$(PKG_NAME
).list
: $(PKG_IPK
)
53 $(IPKG
) install $(PKG_IPK
)
55 source
: $(DL_DIR
)/$(PKG_SOURCE
)
56 prepare
: $(PKG_BUILD_DIR
)/.patched
58 install: $(IPKG_STATE_DIR
)/info/$(PKG_NAME
).list
61 rm -rf
$(PKG_BUILD_DIR
)