asterisk: add image with asterisk support enabled
This commit is contained in:
parent
022af256eb
commit
93fc1a484c
|
|
@ -0,0 +1 @@
|
||||||
|
PACKAGECONFIG_append = " dahdi tonezone gsm"
|
||||||
|
|
@ -0,0 +1,80 @@
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index 37674a4..5e53b4c 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -14,7 +14,7 @@ JUNK = *~ *.bak DEADJOE
|
||||||
|
|
||||||
|
KVER ?= $(shell uname -r)
|
||||||
|
KNAME ?= $(shell uname -s)
|
||||||
|
-KDIR =/lib/modules/$(shell uname -r)/build
|
||||||
|
+KERNEL_SRC ?=/lib/modules/$(shell uname -r)/build
|
||||||
|
KVERBOSE=0
|
||||||
|
MODTYPE=ko
|
||||||
|
|
||||||
|
@@ -22,14 +22,14 @@ VERBOSE =0
|
||||||
|
AUSB_DIR =$(PWD)
|
||||||
|
SRC_DIR =$(PWD)/firmware
|
||||||
|
MOD_DIR =$(PWD)/driver
|
||||||
|
-INCLUDE_DIR =$(PWD)/include
|
||||||
|
+INCLUDE_DIR =$(PWD)/include
|
||||||
|
OS_DIR =$(PWD)/include/os
|
||||||
|
|
||||||
|
TARGETS=compile_amf_mod compile_amf_firmware
|
||||||
|
CLEANTARGETS=clean_amf_mod clean_amf_firmware
|
||||||
|
INSTALLTARGETS=install_amf_mod
|
||||||
|
|
||||||
|
-EXTRA_CFLAGS=$(GLOBAL_CFLAGS) -I$(KDIR)/include/linux -I$(INCLUDE_DIR) -I$(SRC_DIR) -I$(OS_DIR)
|
||||||
|
+EXTRA_CFLAGS=$(GLOBAL_CFLAGS) -I$(KERNEL_SRC)/include/linux -I$(INCLUDE_DIR) -I$(SRC_DIR) -I$(OS_DIR)
|
||||||
|
|
||||||
|
DEBFLAGS = -O
|
||||||
|
ifeq ($(DEBUG),y)
|
||||||
|
@@ -57,16 +57,16 @@ EXTRA_CFLAGS += $(TESTFLAGS)
|
||||||
|
|
||||||
|
EXTRA_UTIL_FLAGS=$(GLOBAL_CFLAGS)
|
||||||
|
|
||||||
|
-all: check-dahdi check-kernel $(TARGETS)
|
||||||
|
+all: $(TARGETS)
|
||||||
|
|
||||||
|
compile_amf_mod:
|
||||||
|
- $(MAKE) KBUILD_VERBOSE=$(KVERBOSE) -C $(KDIR) SUBDIRS=$(MOD_DIR) EXTRA_FLAGS="$(EXTRA_CFLAGS)" modules
|
||||||
|
+ $(MAKE) KBUILD_VERBOSE=$(KVERBOSE) -C $(KERNEL_SRC) SUBDIRS=$(MOD_DIR) EXTRA_FLAGS="$(EXTRA_CFLAGS)" modules
|
||||||
|
|
||||||
|
compile_amf_firmware:
|
||||||
|
$(MAKE) -C $(SRC_DIR) EXTRA_FLAGS="EXTRA_UTIL_FLAGS"
|
||||||
|
|
||||||
|
clean_amf_mod:
|
||||||
|
- $(MAKE) -C $(KDIR) SUBDIRS=$(MOD_DIR) clean
|
||||||
|
+ $(MAKE) -C $(KERNEL_SRC) SUBDIRS=$(MOD_DIR) clean
|
||||||
|
|
||||||
|
clean_amf_firmware:
|
||||||
|
$(MAKE) -C $(SRC_DIR) clean
|
||||||
|
@@ -78,22 +78,22 @@ install: $(INSTALLTARGETS)
|
||||||
|
$(shell depmod -a)
|
||||||
|
|
||||||
|
install_amf_mod:
|
||||||
|
- $(MAKE) -C $(KDIR) SUBDIRS=$(MOD_DIR) modules_install
|
||||||
|
+ $(MAKE) -C $(KERNEL_SRC) SUBDIRS=$(MOD_DIR) modules_install
|
||||||
|
|
||||||
|
#Check for linux headers
|
||||||
|
check-kernel:
|
||||||
|
- @if [ ! -e $(KDIR) ]; then \
|
||||||
|
- echo " Error linux headers/source not found: $(KDIR) !"; \
|
||||||
|
+ @if [ ! -e $(KERNEL_SRC) ]; then \
|
||||||
|
+ echo " Error linux headers/source not found: $(KERNEL_SRC) !"; \
|
||||||
|
echo ; \
|
||||||
|
exit 1; \
|
||||||
|
fi
|
||||||
|
- @if [ ! -e $(KDIR)/.config ]; then \
|
||||||
|
- echo " Error linux headers/source not configured: missing $(KDIR)/.config !"; \
|
||||||
|
+ @if [ ! -e $(KERNEL_SRC)/.config ]; then \
|
||||||
|
+ echo " Error linux headers/source not configured: missing $(KERNEL_SRC)/.config !"; \
|
||||||
|
echo ; \
|
||||||
|
exit 1; \
|
||||||
|
fi
|
||||||
|
- @if [ ! -e $(KDIR)/include ]; then \
|
||||||
|
- echo " Error linux headers/source incomplete: missing $(KDIR)/include dir !"; \
|
||||||
|
+ @if [ ! -e $(KERNEL_SRC)/include ]; then \
|
||||||
|
+ echo " Error linux headers/source incomplete: missing $(KERNEL_SRC)/include dir !"; \
|
||||||
|
echo ; \
|
||||||
|
exit 1; \
|
||||||
|
fi
|
||||||
Binary file not shown.
|
|
@ -0,0 +1,28 @@
|
||||||
|
DESCRIPTION = "A kernel module for the amfeltec usb fxs adapter"
|
||||||
|
HOMEPAGE = "http://www.netmodule.com/"
|
||||||
|
LICENSE = "GPLv2"
|
||||||
|
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
|
||||||
|
PROVIDES = "amfeltec-usb"
|
||||||
|
|
||||||
|
inherit module
|
||||||
|
DEPENDS = "dahdi-linux"
|
||||||
|
RDEPENDS_${PN} = "dahdi-linux"
|
||||||
|
|
||||||
|
S = "${WORKDIR}/amfeltec_usb_${PV}"
|
||||||
|
|
||||||
|
SRC_URI = " \
|
||||||
|
file://amfeltec_usb_${PV}.tgz \
|
||||||
|
file://001_makefile.patch \
|
||||||
|
"
|
||||||
|
|
||||||
|
GLOBAL_CFLAGS = "-I${STAGING_INCDIR} -DDAHDI_VERSION=29"
|
||||||
|
|
||||||
|
do_compile_prepend() {
|
||||||
|
export GLOBAL_CFLAGS="${GLOBAL_CFLAGS}"
|
||||||
|
|
||||||
|
cat ${STAGING_DIR_TARGET}/usr/share/dahdi-linux/Module.symvers ${STAGING_KERNEL_BUILDDIR}/Module.symvers > ${S}/driver/Module.symvers
|
||||||
|
}
|
||||||
|
|
||||||
|
do_install() {
|
||||||
|
oe_runmake INSTALL_MOD_PATH=${D} install
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
FILES_${PN}-dev_append = " \
|
||||||
|
/usr/share/dahdi-linux/Module.symvers \
|
||||||
|
"
|
||||||
|
|
||||||
|
do_install_append() {
|
||||||
|
mkdir -p ${D}/usr/share/dahdi-linux/
|
||||||
|
cp drivers/dahdi/Module.symvers ${D}/usr/share/dahdi-linux/
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -37,5 +37,14 @@ do_install_append(){
|
||||||
if [ "${KERNEL_IMAGETYPE}" = "uImage" ]; then
|
if [ "${KERNEL_IMAGETYPE}" = "uImage" ]; then
|
||||||
ln -s ${KERNEL_IMAGETYPE}-${KERNEL_VERSION} ${D}/${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}
|
ln -s ${KERNEL_IMAGETYPE}-${KERNEL_VERSION} ${D}/${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Module.symvers gets updated during the
|
||||||
|
# building of the kernel modules. We need to
|
||||||
|
# update this in the shared workdir since some
|
||||||
|
# external kernel modules has a dependency on
|
||||||
|
# other kernel modules and will look at this
|
||||||
|
# file to do symbol lookups
|
||||||
|
# THIS WILL BE FIXED IN FUTURE VERSIONS!
|
||||||
|
cp Module.symvers ${STAGING_KERNEL_BUILDDIR}/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue