2007-01-01 13:25:09 +08:00
|
|
|
#
|
|
|
|
# Copyright (C) 2006 OpenWrt.org
|
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
# $Id$
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=npe-ucode
|
2007-05-02 20:03:43 +08:00
|
|
|
PKG_VERSION:=2.4
|
2007-01-01 13:25:09 +08:00
|
|
|
PKG_RELEASE:=1
|
|
|
|
|
|
|
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
2007-05-02 20:03:43 +08:00
|
|
|
PKG_SOURCE:=IPL_ixp400NpeLibrary-2_4.zip
|
2007-01-01 13:25:09 +08:00
|
|
|
|
2007-04-02 20:05:57 +08:00
|
|
|
include $(INCLUDE_DIR)/package.mk
|
2007-01-01 13:25:09 +08:00
|
|
|
|
2007-04-02 20:05:57 +08:00
|
|
|
define Build/Prepare
|
|
|
|
rm -rf $(PKG_BUILD_DIR)
|
|
|
|
mkdir -p $(PKG_BUILD_DIR)
|
|
|
|
unzip -d $(PKG_BUILD_DIR)/ $(DL_DIR)/$(PKG_SOURCE)
|
2007-01-01 13:25:09 +08:00
|
|
|
mv $(PKG_BUILD_DIR)/ixp400_xscale_sw/src/npeDl/IxNpeMicrocode.c $(PKG_BUILD_DIR)/
|
|
|
|
rm -rf $(PKG_BUILD_DIR)/ixp400_xscale_sw
|
|
|
|
$(CP) ./src/* $(PKG_BUILD_DIR)/
|
2007-04-02 20:05:57 +08:00
|
|
|
endef
|
2007-01-01 13:25:09 +08:00
|
|
|
|
2007-04-02 20:05:57 +08:00
|
|
|
define Build/Compile
|
|
|
|
(cd $(PKG_BUILD_DIR); \
|
|
|
|
$(HOSTCC) -Wall IxNpeMicrocode.c -o IxNpeMicrocode; \
|
|
|
|
./IxNpeMicrocode -be \
|
|
|
|
)
|
|
|
|
endef
|
2007-01-01 13:25:09 +08:00
|
|
|
|
2007-04-02 20:05:57 +08:00
|
|
|
define Build/InstallDev
|
2007-01-01 13:25:09 +08:00
|
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/NPE-B $(TARGET)/
|
2007-04-02 20:05:57 +08:00
|
|
|
endef
|
2007-01-01 13:25:09 +08:00
|
|
|
|
2007-04-02 20:05:57 +08:00
|
|
|
$(eval $(call Build/DefaultTargets))
|