All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] netapi: Add recipe for NETAPI module
@ 2015-02-20  3:35 Sam Nelson
  2015-02-24 21:09 ` Denys Dmytriyenko
  0 siblings, 1 reply; 2+ messages in thread
From: Sam Nelson @ 2015-02-20  3:35 UTC (permalink / raw)
  To: meta-ti

- Provide TI user space network library and test code
- Supports k2h, k2k, k2l & k2e devices

Signed-off-by: Sam Nelson <sam.nelson@ti.com>
---
 recipes-ti/netapi/netapi-test_git.bb |   48 ++++++++++++++++++++++++++++++++++
 recipes-ti/netapi/netapi.inc         |   15 +++++++++++
 recipes-ti/netapi/netapi_git.bb      |   35 +++++++++++++++++++++++++
 3 files changed, 98 insertions(+)
 create mode 100644 recipes-ti/netapi/netapi-test_git.bb
 create mode 100644 recipes-ti/netapi/netapi.inc
 create mode 100644 recipes-ti/netapi/netapi_git.bb

diff --git a/recipes-ti/netapi/netapi-test_git.bb b/recipes-ti/netapi/netapi-test_git.bb
new file mode 100644
index 0000000..4107366
--- /dev/null
+++ b/recipes-ti/netapi/netapi-test_git.bb
@@ -0,0 +1,48 @@
+DESCRIPTION = "Provides test and application binaries using NETAPI module"
+COMPATIBLE_MACHINE = "keystone"
+DEPENDS = "netapi ipsecmgr"
+
+include netapi.inc
+
+BASEDIR = "${WORKDIR}/git"
+S = "${BASEDIR}/ti/runtime/netapi"
+
+do_compile () {
+#   Build the netapi binaries
+	for device in ${DEVICELIST}
+	do
+		for choice in ${CHOICELIST}
+		do
+			oe_runmake tests NETAPI_SRC_DIR=${S} NETAPI_INC_DIR=${BASEDIR} \
+				USEDYNAMIC_LIB="$choice" DEVICE="$device"
+		done
+
+#     Now build the netapi appplications
+		cd ${S}/applications/ipsec_offload/ipsecmgr/build
+		make clean app PDK_INSTALL_PATH=${STAGING_INCDIR} NETAPI_SRC_DIR=${S} DEVICE="$device"
+
+		cd ${S}/applications/ipsec_offload/config-app/build
+		make clean app PDK_INSTALL_PATH=${STAGING_INCDIR} DEVICE="$device"
+		cd ${S}
+	done
+}
+
+do_install () {
+	for device in ${DEVICELIST}
+	do
+		oe_runmake installbin INSTALL_INC_BASE_DIR=${D}/${includedir} \
+			INSTALL_LIB_BASE_DIR=${D}${libdir} INSTALL_BIN_BASE_DIR=${D}${bindir} \
+			SYSCONFDIR=${D}${sysconfdir} DEVICE="$device"
+
+		cd ${S}/applications/ipsec_offload/ipsecmgr/build
+		make install PDK_INSTALL_PATH=${STAGING_INCDIR} \
+			INSTALL_BIN_BASE_DIR=${D}${bindir} SYSCONFDIR=${D}${sysconfdir} \
+			DEVICE="$device"
+
+		cd ${S}/applications/ipsec_offload/config-app/build
+		make install PDK_INSTALL_PATH=${STAGING_INCDIR} \
+			INSTALL_BIN_BASE_DIR=${D}${bindir} SYSCONFDIR=${D}${sysconfdir} \
+			DEVICE="$device"
+		cd ${S}
+	done
+}
diff --git a/recipes-ti/netapi/netapi.inc b/recipes-ti/netapi/netapi.inc
new file mode 100644
index 0000000..4bed670
--- /dev/null
+++ b/recipes-ti/netapi/netapi.inc
@@ -0,0 +1,15 @@
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://${WORKDIR}/git/COPYING.txt;md5=f2b4f162358b1ffaf3f2307287ca2074"
+
+BRANCH = "master"
+SRC_URI = "git://git.ti.com/keystone-rtos/netapi.git;protocol=git;branch=${BRANCH}"
+
+# Below Commit ID corresponds to "DEV.NETAPI.01.01.00.04"
+SRCREV= "dc08af268200908d3d8a456ac852c65c53d2fd12"
+PV = "01.01.00.04"
+
+DEVICELIST = "k2h k2k k2l k2e"
+
+CHOICELIST = "yes no"
+
+EXTRA_OEMAKE += "-f makefile_armv7 PDK_INSTALL_PATH=${STAGING_INCDIR}"
diff --git a/recipes-ti/netapi/netapi_git.bb b/recipes-ti/netapi/netapi_git.bb
new file mode 100644
index 0000000..7349c44
--- /dev/null
+++ b/recipes-ti/netapi/netapi_git.bb
@@ -0,0 +1,35 @@
+DESCRIPTION = "Provides NETAPI module: TI user space network library"
+
+COMPATIBLE_MACHINE = "keystone"
+
+DEPENDS = "common-csl-ip rm-lld qmss-lld cppi-lld sa-lld hplib pktlib nwal-lld"
+
+NAME = "netapi"
+
+include netapi.inc
+
+BASEDIR = "${WORKDIR}/git"
+S = "${BASEDIR}/ti/runtime/netapi"
+
+do_compile () {
+#   Now build the netapi
+	for device in ${DEVICELIST}
+	do
+		for choice in ${CHOICELIST}
+		do
+			oe_runmake clean NETAPI_SRC_DIR=${S} NETAPI_INC_DIR=${BASEDIR} \
+				USEDYNAMIC_LIB="$choice" DEVICE="$device"
+			oe_runmake lib NETAPI_SRC_DIR=${S} NETAPI_INC_DIR=${BASEDIR} \
+				USEDYNAMIC_LIB="$choice" DEVICE="$device"
+		done
+	done
+}
+
+do_install () {
+	for device in ${DEVICELIST}
+	do
+		oe_runmake install INSTALL_INC_BASE_DIR=${D}${includedir} \
+			INSTALL_LIB_BASE_DIR=${D}${libdir} INSTALL_BIN_BASE_DIR=${D}${bindir} \
+			SYSCONFDIR=${D}${sysconfdir} DEVICE="$device"
+	done
+}
-- 
1.7.9.5



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] netapi: Add recipe for NETAPI module
  2015-02-20  3:35 [PATCH] netapi: Add recipe for NETAPI module Sam Nelson
@ 2015-02-24 21:09 ` Denys Dmytriyenko
  0 siblings, 0 replies; 2+ messages in thread
From: Denys Dmytriyenko @ 2015-02-24 21:09 UTC (permalink / raw)
  To: Sam Nelson; +Cc: meta-ti

Any way you can use oe_runmake instead of make and extract common make 
variables to EXTRA_OEMAKE?


On Thu, Feb 19, 2015 at 10:35:55PM -0500, Sam Nelson wrote:
> - Provide TI user space network library and test code
> - Supports k2h, k2k, k2l & k2e devices
> 
> Signed-off-by: Sam Nelson <sam.nelson@ti.com>
> ---
>  recipes-ti/netapi/netapi-test_git.bb |   48 ++++++++++++++++++++++++++++++++++
>  recipes-ti/netapi/netapi.inc         |   15 +++++++++++
>  recipes-ti/netapi/netapi_git.bb      |   35 +++++++++++++++++++++++++
>  3 files changed, 98 insertions(+)
>  create mode 100644 recipes-ti/netapi/netapi-test_git.bb
>  create mode 100644 recipes-ti/netapi/netapi.inc
>  create mode 100644 recipes-ti/netapi/netapi_git.bb
> 
> diff --git a/recipes-ti/netapi/netapi-test_git.bb b/recipes-ti/netapi/netapi-test_git.bb
> new file mode 100644
> index 0000000..4107366
> --- /dev/null
> +++ b/recipes-ti/netapi/netapi-test_git.bb
> @@ -0,0 +1,48 @@
> +DESCRIPTION = "Provides test and application binaries using NETAPI module"
> +COMPATIBLE_MACHINE = "keystone"
> +DEPENDS = "netapi ipsecmgr"
> +
> +include netapi.inc
> +
> +BASEDIR = "${WORKDIR}/git"
> +S = "${BASEDIR}/ti/runtime/netapi"
> +
> +do_compile () {
> +#   Build the netapi binaries
> +	for device in ${DEVICELIST}
> +	do
> +		for choice in ${CHOICELIST}
> +		do
> +			oe_runmake tests NETAPI_SRC_DIR=${S} NETAPI_INC_DIR=${BASEDIR} \
> +				USEDYNAMIC_LIB="$choice" DEVICE="$device"
> +		done
> +
> +#     Now build the netapi appplications
> +		cd ${S}/applications/ipsec_offload/ipsecmgr/build
> +		make clean app PDK_INSTALL_PATH=${STAGING_INCDIR} NETAPI_SRC_DIR=${S} DEVICE="$device"
> +
> +		cd ${S}/applications/ipsec_offload/config-app/build
> +		make clean app PDK_INSTALL_PATH=${STAGING_INCDIR} DEVICE="$device"
> +		cd ${S}
> +	done
> +}
> +
> +do_install () {
> +	for device in ${DEVICELIST}
> +	do
> +		oe_runmake installbin INSTALL_INC_BASE_DIR=${D}/${includedir} \
> +			INSTALL_LIB_BASE_DIR=${D}${libdir} INSTALL_BIN_BASE_DIR=${D}${bindir} \
> +			SYSCONFDIR=${D}${sysconfdir} DEVICE="$device"
> +
> +		cd ${S}/applications/ipsec_offload/ipsecmgr/build
> +		make install PDK_INSTALL_PATH=${STAGING_INCDIR} \
> +			INSTALL_BIN_BASE_DIR=${D}${bindir} SYSCONFDIR=${D}${sysconfdir} \
> +			DEVICE="$device"
> +
> +		cd ${S}/applications/ipsec_offload/config-app/build
> +		make install PDK_INSTALL_PATH=${STAGING_INCDIR} \
> +			INSTALL_BIN_BASE_DIR=${D}${bindir} SYSCONFDIR=${D}${sysconfdir} \
> +			DEVICE="$device"
> +		cd ${S}
> +	done
> +}
> diff --git a/recipes-ti/netapi/netapi.inc b/recipes-ti/netapi/netapi.inc
> new file mode 100644
> index 0000000..4bed670
> --- /dev/null
> +++ b/recipes-ti/netapi/netapi.inc
> @@ -0,0 +1,15 @@
> +LICENSE = "BSD-3-Clause"
> +LIC_FILES_CHKSUM = "file://${WORKDIR}/git/COPYING.txt;md5=f2b4f162358b1ffaf3f2307287ca2074"
> +
> +BRANCH = "master"
> +SRC_URI = "git://git.ti.com/keystone-rtos/netapi.git;protocol=git;branch=${BRANCH}"
> +
> +# Below Commit ID corresponds to "DEV.NETAPI.01.01.00.04"
> +SRCREV= "dc08af268200908d3d8a456ac852c65c53d2fd12"
> +PV = "01.01.00.04"
> +
> +DEVICELIST = "k2h k2k k2l k2e"
> +
> +CHOICELIST = "yes no"
> +
> +EXTRA_OEMAKE += "-f makefile_armv7 PDK_INSTALL_PATH=${STAGING_INCDIR}"
> diff --git a/recipes-ti/netapi/netapi_git.bb b/recipes-ti/netapi/netapi_git.bb
> new file mode 100644
> index 0000000..7349c44
> --- /dev/null
> +++ b/recipes-ti/netapi/netapi_git.bb
> @@ -0,0 +1,35 @@
> +DESCRIPTION = "Provides NETAPI module: TI user space network library"
> +
> +COMPATIBLE_MACHINE = "keystone"
> +
> +DEPENDS = "common-csl-ip rm-lld qmss-lld cppi-lld sa-lld hplib pktlib nwal-lld"
> +
> +NAME = "netapi"
> +
> +include netapi.inc
> +
> +BASEDIR = "${WORKDIR}/git"
> +S = "${BASEDIR}/ti/runtime/netapi"
> +
> +do_compile () {
> +#   Now build the netapi
> +	for device in ${DEVICELIST}
> +	do
> +		for choice in ${CHOICELIST}
> +		do
> +			oe_runmake clean NETAPI_SRC_DIR=${S} NETAPI_INC_DIR=${BASEDIR} \
> +				USEDYNAMIC_LIB="$choice" DEVICE="$device"
> +			oe_runmake lib NETAPI_SRC_DIR=${S} NETAPI_INC_DIR=${BASEDIR} \
> +				USEDYNAMIC_LIB="$choice" DEVICE="$device"
> +		done
> +	done
> +}
> +
> +do_install () {
> +	for device in ${DEVICELIST}
> +	do
> +		oe_runmake install INSTALL_INC_BASE_DIR=${D}${includedir} \
> +			INSTALL_LIB_BASE_DIR=${D}${libdir} INSTALL_BIN_BASE_DIR=${D}${bindir} \
> +			SYSCONFDIR=${D}${sysconfdir} DEVICE="$device"
> +	done
> +}
> -- 
> 1.7.9.5
> 
> -- 
> _______________________________________________
> meta-ti mailing list
> meta-ti@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/meta-ti


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-02-24 21:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-20  3:35 [PATCH] netapi: Add recipe for NETAPI module Sam Nelson
2015-02-24 21:09 ` Denys Dmytriyenko

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.