From c37d4f349aeec27893bd062e40e9f08a290722b4 Mon Sep 17 00:00:00 2001 From: adrian Date: Sat, 22 Jan 2011 23:37:42 +0000 Subject: [PATCH] Patch the athstats code/Makefile to cross-compile correctly. --- tools/tools/ath/athstats/Makefile | 24 +++++++++++------------- tools/tools/ath/athstats/athstats.c | 2 ++ 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/tools/tools/ath/athstats/Makefile b/tools/tools/ath/athstats/Makefile index 1a963e62e19a..b1b976619f8a 100644 --- a/tools/tools/ath/athstats/Makefile +++ b/tools/tools/ath/athstats/Makefile @@ -1,28 +1,26 @@ # $FreeBSD$ +.PATH: ${.CURDIR}/../../../../sys/dev/ath/ath_hal + PROG= athstats -SRCS= main.c statfoo.c athstats.c +SRCS= main.c statfoo.c athstats.c opt_ah.h ah_osdep.h -.include +CLEANFILES+= opt_ah.h -SRCDIR= ${.CURDIR}/../../../.. - -CLEANFILES+= opt_ah.h ah_osdep.h +.include <../Makefile.inc> CFLAGS+=-DATH_SUPPORT_ANI CFLAGS+=-DATH_SUPPORT_TDMA -CFLAGS+=-I${.CURDIR} -CFLAGS+=-I${SRCDIR}/sys/net80211 - -.include <../Makefile.inc> - -athstats.o: opt_ah.h ah_osdep.h - opt_ah.h: - touch opt_ah.h + echo "#define AH_DEBUG 1" > opt_ah.h + echo "#define AH_DEBUG_COUNTRY 1" >> opt_ah.h + echo "#define AH_SUPPORT_AR5416 1" >> opt_ah.h + ah_osdep.h: echo 'typedef void *HAL_SOFTC;' >ah_osdep.h echo 'typedef int HAL_BUS_TAG;' >>ah_osdep.h echo 'typedef void *HAL_BUS_HANDLE;' >>ah_osdep.h + +.include diff --git a/tools/tools/ath/athstats/athstats.c b/tools/tools/ath/athstats/athstats.c index 8bd5ea7e90bb..2c9f131722c0 100644 --- a/tools/tools/ath/athstats/athstats.c +++ b/tools/tools/ath/athstats/athstats.c @@ -29,6 +29,8 @@ * $FreeBSD$ */ +#include "opt_ah.h" + /* * ath statistics class. */