blob: ce8ee22842976ebb840ba0902dc35f50e9abf88d [file] [log] [blame]
Dave Barach61efa142016-01-22 08:23:09 -05001# Temporary until Cavium upstreams their work
2
3cavium-dpdk_configure = \
4 src_dir=$(call find_source_fn,$(PACKAGE_SOURCE)) ; \
5 dst_dir=$(PACKAGE_BUILD_DIR) ; \
6 tar -C $${src_dir} -cf - . | tar -C $${dst_dir} -xf - ; \
7 cd $${dst_dir} ; \
8 : colossal hemorrhoid to configure headroom ; \
9 if [ x$($(PACKAGE)_configure_args_$(PLATFORM)) = "x" ] ; then \
10 HR=256 ; \
11 else \
12 dpdk_configure_args=$($(PACKAGE)_configure_args_$(PLATFORM)) ; \
13 if [ $$dpdk_configure_args = "--with-headroom=256" ] ; then \
14 HR=256 ; \
15 elif [ $$dpdk_configure_args = "--with-headroom=384" ] ; then \
16 HR=384 ; \
17 else \
18 HR=256 ; \
19 fi ; \
20 fi ; \
21 env HR=$$HR \
22 spp -o \
23 $(PACKAGE_BUILD_DIR)/config/common_linuxapp \
24 $(PACKAGE_BUILD_DIR)/config/common_linuxapp.spp \
25 ; \
26 env $(CONFIGURE_ENV) \
27 make config T=arm64-thunderx-linuxapp-gcc RTE_ARCH=arm64 \
28 CC=aarch64-thunderx-linux-gnu-gcc V=0 \
29 RTE_SDK=$(PACKAGE_BUILD_DIR) \
30 RTE_TARGET=arm-default-linuxapp-gcc
31
32# Note: add e.g. "-O0" to EXTRA_CFLAGS if desired: EXTRA_CFLAGS='-g -O0'
33
34cavium-dpdk_make_args = install T=arm64-thunderx-linuxapp-gcc RTE_ARCH=arm64 \
35 CC=aarch64-thunderx-linux-gnu-gcc V=0 \
36 RTE_SDK=$(PACKAGE_BUILD_DIR) \
37 RTE_TARGET=arm-default-linuxapp-gcc
38
39cavium-dpdk_install = \
40 src_dir=$(PACKAGE_BUILD_DIR) ; \
41 dst_dir=$(PACKAGE_INSTALL_DIR) ; \
42 tar -h -C $${src_dir}/arm64-thunderx-linuxapp-gcc -cf - . \
43 | tar -C $${dst_dir} -xf -
44
45# dpdk libraries end up in .../lib not .../lib64. Fix it.
46cavium-dpdk_post_install = \
47 if [ "$(arch_lib_dir)" != "lib" ] ; then \
48 mkdir -p $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir) ; \
49 cd $(PACKAGE_INSTALL_DIR)/lib ; \
50 tar cf - . | ( cd $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir); tar xf - ) ; \
51 fi
52
53# nothing to install, all static libraries
54cavium-dpdk_image_include = echo
55