2 # Copyright (C) 2014 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
10 include $(INCLUDE_DIR
)/kernel.mk
12 PKG_NAME
:=cryptodev-linux
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
17 PKG_SOURCE_URL
:=http
://download.gna.org
/cryptodev-linux
/
18 PKG_MD5SUM
:=eade38998313c25fd7934719cdf8a2ea
20 PKG_BUILD_DIR
:=$(KERNEL_BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
22 include $(INCLUDE_DIR
)/package.mk
24 CRYPTODEV_AUTOLOAD
:= \
27 define KernelPackage
/cryptodev
28 SUBMENU
:=Cryptographic API modules
30 TITLE
:=Driver for cryptographic acceleration
31 URL
:=http
://cryptodev-linux.org
/
32 MAINTAINER
:=Nikos Mavrogiannopoulos
<n.mavrogiannopoulos@gmail.com
>
33 VERSION
:=$(LINUX_VERSION
)+$(PKG_VERSION
)-$(BOARD
)-$(PKG_RELEASE
)
34 DEPENDS
:=+kmod-crypto-core
+kmod-crypto-authenc
+kmod-crypto-hash
36 $(PKG_BUILD_DIR
)/cryptodev.
$(LINUX_KMOD_SUFFIX
)
37 AUTOLOAD
:=$(call AutoLoad
,50,$(CRYPTODEV_AUTOLOAD
))
40 define KernelPackage
/cryptodev
/description
41 This is a driver for that allows to use the Linux kernel supported
42 hardware ciphers by user-space applications.
45 CRYPTODEV_MAKEOPTS
= -C
$(PKG_BUILD_DIR
) \
46 PATH
="$(TARGET_PATH)" \
47 ARCH
="$(LINUX_KARCH)" \
48 CROSS_COMPILE
="$(TARGET_CROSS)" \
49 TOOLPREFIX
="$(KERNEL_CROSS)" \
50 TOOLPATH
="$(KERNEL_CROSS)" \
51 KERNEL_DIR
="$(LINUX_DIR)" \
55 define Build
/Compile
/cryptodev
56 $(MAKE
) $(CRYPTODEV_MAKEOPTS
)
60 $(call Build
/Compile
/cryptodev
)
63 define Build
/InstallDev
64 $(INSTALL_DIR
) $(STAGING_DIR
)/usr
/include/crypto
65 $(CP
) $(PKG_BUILD_DIR
)/crypto
/cryptodev.h
$(STAGING_DIR
)/usr
/include/crypto
/
68 define KernelPackage
/cryptodev
/install
69 $(INSTALL_DIR
) $(1)/etc
/modules.d
70 $(INSTALL_DATA
) .
/files
/cryptodev.modules
$(1)/etc
/modules.d
/80-cryptodev
71 $(INSTALL_DIR
) $(1)/lib
/modules
/$(LINUX_VERSION
)
72 $(INSTALL_DIR
) $(1)/usr
/sbin
75 $(eval
$(call KernelPackage
,cryptodev
))