blob: 3a23125c2449eb5349ac4aeb999966a326d522ca [file] [log] [blame]
# Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
# Distributed under the terms of the GNU General Public License v2
EAPI=4
CROS_WORKON_PROJECT="chromiumos/third_party/gdmwimax"
inherit cros-workon
DESCRIPTION="GCT GDM7205 WiMAX SDK"
HOMEPAGE="http://www.gctsemi.com/"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~*"
IUSE="-asan"
RDEPEND="!net-wireless/gdmwimax-private"
DEPEND="${RDEPEND}"
src_configure() {
# Create build configuration file.
cat > .config <<-EOF
CONFIG_DM_INTERFACE=y
CONFIG_DM_NET_DEVICE=eth0
CONFIG_LOG_FILE_BUF_SIZE=0x80000
CONFIG_ENABLE_BW_SWITCHING_FOR_KT=n
CONFIG_ENABLE_SERVICE_FLOW=n
CONFIG_WIMAX2=n
EOF
# Do not fortify source. See crosbug.com/p/10133 for details.
append-flags -U_FORTIFY_SOURCE
tc-export AR CC
asan-setup-env
cros-workon_src_configure
}
src_compile() {
emake -C sdk
emake -C cm
}
src_install() {
# Install SDK library.
dolib sdk/libgdmwimax.a
# Install SDK headers.
insinto /usr/include/gct
doins sdk/{gctapi.h,gcttype.h,WiMaxType.h}
# Install connection manager executable and configuration file.
exeinto /opt/gct
doexe cm/cm
insinto /opt/gct
doins cm/cm.conf
# Install firmware.
insinto /lib/firmware/gdm72xx
doins firmware/gdmuimg.bin
}