summaryrefslogtreecommitdiff
path: root/package/ubsec_ssb/Makefile
blob: 6a14e2a9107e164f90de99edc790a9dd6211bf31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#
# Copyright (C) 2008 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#

include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk

PKG_NAME:=ubsec-ssb
PKG_VERSION:=2009-02-21
PKG_RELEASE:=1

CRYPTO_MENU:=OCF Configuration

include $(INCLUDE_DIR)/package.mk

define KernelPackage/ocf-ubsec-ssb
  SUBMENU:=$(CRYPTO_MENU)
  DEPENDS:=@TARGET_brcm47xx +@OPENSSL_ENGINE +kmod-crypto-core +kmod-crypto-ocf
  TITLE:=BCM5365P IPSec Core driver
  FILES:=$(PKG_BUILD_DIR)/src/ubsec_ssb.$(LINUX_KMOD_SUFFIX)
  AUTOLOAD:=$(call AutoLoad,09,ubsec_ssb)
endef

define KernelPackage/ocf-ubsec-ssb/description
	This package contains the OCF driver for the BCM5365p IPSec Core
endef

define Build/Prepare
	mkdir -p $(PKG_BUILD_DIR)
	$(CP) -r ./src $(PKG_BUILD_DIR)/
endef

LINUX_PATCHLEVEL:=$(shell echo "$(LINUX_VERSION)" | cut -d. -f2)

define Build/Compile
	$(MAKE) -C $(LINUX_DIR) \
		ARCH="$(LINUX_KARCH)" \
		CROSS_COMPILE="$(TARGET_CROSS)" \
		PATCHLEVEL="$(LINUX_PATCHLEVEL)" \
		KERNDIR="$(LINUX_DIR)" \
		SUBDIRS="$(PKG_BUILD_DIR)/src" \
		modules
endef

$(eval $(call KernelPackage,ocf-ubsec-ssb))