2015-04-21 14:54:49 +02:00
|
|
|
BUILD=8
|
2015-03-31 16:39:17 +02:00
|
|
|
VERSION=$(shell date +%Y%m%d%H%M)-$(BUILD)
|
2015-03-26 20:15:21 +01:00
|
|
|
CPUS=4
|
2015-05-12 11:27:26 +02:00
|
|
|
CURDIR=$(shell pwd)
|
2015-03-28 09:36:07 +01:00
|
|
|
STLINUX=/opt/STM/STLinux-2.4
|
|
|
|
TOOLPATH=$(STLINUX)/host/bin
|
|
|
|
TOOLCHAIN=$(STLINUX)/devkit/sh4
|
2015-05-12 11:27:26 +02:00
|
|
|
TOOLCHAIN_KERNEL=$(CURDIR)/toolchain/4.5.3-99/opt/STM/STLinux-2.4/devkit/sh4
|
2015-04-03 13:20:23 +02:00
|
|
|
HOST_ARCH=$(shell uname -m)
|
2015-03-26 20:15:21 +01:00
|
|
|
|
2015-03-28 20:33:17 +01:00
|
|
|
EXTRA_AXE_MODULES_DIR=firmware/initramfs/root/modules_idl4k_7108_ST40HOST_LINUX_32BITS
|
|
|
|
EXTRA_AXE_MODULES=axe_dmx.ko axe_dmxts.ko axe_fe.ko axe_fp.ko axe_i2c.ko \
|
2015-04-14 10:14:19 +02:00
|
|
|
stapi_core_stripped.ko stapi_ioctl_stripped.ko stsys_ioctl.ko
|
2015-03-28 20:33:17 +01:00
|
|
|
|
2015-04-14 10:14:19 +02:00
|
|
|
ORIG_FILES=main_axe.out
|
2015-03-28 20:33:17 +01:00
|
|
|
|
2015-04-08 17:30:03 +02:00
|
|
|
KMODULES = drivers/usb/serial/cp210x.ko \
|
|
|
|
drivers/usb/serial/pl2303.ko \
|
|
|
|
drivers/usb/serial/spcp8x5.ko \
|
|
|
|
drivers/usb/serial/io_ti.ko \
|
|
|
|
drivers/usb/serial/ti_usb_3410_5052.ko \
|
|
|
|
drivers/usb/serial/io_edgeport.ko \
|
|
|
|
drivers/usb/serial/ftdi_sio.ko \
|
|
|
|
drivers/usb/serial/oti6858.ko
|
|
|
|
|
2015-04-10 15:08:02 +02:00
|
|
|
MINISATIP_COMMIT=54df9348e7bd7e6075f54f1b93ec4ad36429abe0
|
|
|
|
|
2015-04-08 13:54:26 +02:00
|
|
|
BUSYBOX=busybox-1.23.2
|
|
|
|
|
2015-03-28 20:33:17 +01:00
|
|
|
DROPBEAR=dropbear-2015.67
|
|
|
|
DROPBEAR_SBIN_FILES=dropbear
|
|
|
|
DROPBEAR_BIN_FILES=dbclient dropbearconvert dropbearkey scp
|
|
|
|
|
2015-04-20 15:43:32 +02:00
|
|
|
ETHTOOL=ethtool-3.18
|
|
|
|
|
2015-04-21 14:54:49 +02:00
|
|
|
LIBTIRPC_VERSION=0.2.5
|
|
|
|
LIBTIRPC=libtirpc-$(LIBTIRPC_VERSION)
|
|
|
|
|
|
|
|
RPCBIND_VERSION=0.2.2
|
|
|
|
RPCBIND=rpcbind-$(RPCBIND_VERSION)
|
|
|
|
RPCBIND_SBIN_FILES=rpcbind rpcinfo
|
|
|
|
|
|
|
|
NFSUTILS_VERSION=1.3.2
|
|
|
|
NFSUTILS=nfs-utils-$(NFSUTILS_VERSION)
|
|
|
|
NFSUTILS_SBIN_FILES=utils/showmount/showmount \
|
|
|
|
utils/exportfs/exportfs \
|
|
|
|
utils/nfsstat/nfsstat \
|
|
|
|
utils/mountd/mountd \
|
|
|
|
utils/statd/start-statd \
|
|
|
|
utils/statd/sm-notify \
|
|
|
|
utils/statd/statd \
|
|
|
|
utils/nfsd/nfsd
|
|
|
|
|
2015-05-22 21:48:07 +02:00
|
|
|
NANO_VERSION=2.4.1
|
|
|
|
NANO=nano-$(NANO_VERSION)
|
|
|
|
NANO_FILENAME=$(NANO).tar.gz
|
|
|
|
NANO_DOWNLOAD=http://www.nano-editor.org/dist/v2.4/$(NANO_FILENAME)
|
|
|
|
|
2015-05-12 11:27:26 +02:00
|
|
|
TVHEADEND_COMMIT=master
|
|
|
|
|
2015-04-08 17:30:03 +02:00
|
|
|
# 10087?
|
|
|
|
OSCAM_REV=10619
|
|
|
|
|
2015-03-28 09:36:07 +01:00
|
|
|
define GIT_CLONE
|
|
|
|
@mkdir -p apps/
|
|
|
|
git clone $(1) apps/$(2)
|
2015-04-10 15:08:02 +02:00
|
|
|
cd apps/$(2) && git checkout -b axe $(3)
|
2015-03-28 09:36:07 +01:00
|
|
|
endef
|
|
|
|
|
2015-03-28 20:33:17 +01:00
|
|
|
define WGET
|
|
|
|
@mkdir -p apps/
|
|
|
|
wget --no-verbose -O $(2) $(1)
|
|
|
|
endef
|
2015-03-28 09:36:07 +01:00
|
|
|
|
2015-03-26 20:55:54 +01:00
|
|
|
#
|
|
|
|
# all
|
|
|
|
#
|
|
|
|
|
|
|
|
.PHONY: all
|
|
|
|
all: kernel-axe-modules kernel
|
|
|
|
|
2015-03-31 16:39:17 +02:00
|
|
|
.PHONY: release
|
2015-03-31 18:50:27 +02:00
|
|
|
release: kernel-axe-modules out/idl4k.scr out/idl4k.recovery
|
2015-03-31 16:39:17 +02:00
|
|
|
-ls -la out
|
|
|
|
|
2015-03-31 18:50:27 +02:00
|
|
|
.PHONY: dist
|
|
|
|
dist:
|
|
|
|
-mkdir -p dist
|
|
|
|
cp out/*.fw out/*.usb out/*.flash dist
|
|
|
|
|
2015-03-26 20:55:54 +01:00
|
|
|
#
|
|
|
|
# create CPIO
|
|
|
|
#
|
|
|
|
|
2015-05-22 21:48:07 +02:00
|
|
|
CPIO_SRCS = kernel-modules
|
|
|
|
CPIO_SRCS += busybox
|
|
|
|
CPIO_SRCS += dropbear
|
|
|
|
CPIO_SRCS += ethtool
|
|
|
|
CPIO_SRCS += minisatip
|
|
|
|
CPIO_SRCS += oscam
|
|
|
|
CPIO_SRCS += tools/axehelper
|
|
|
|
CPIO_SRCS += nfsutils
|
|
|
|
CPIO_SRCS += nano
|
|
|
|
|
|
|
|
fs.cpio: $(CPIO_SRCS)
|
2015-03-27 21:55:18 +01:00
|
|
|
fakeroot tools/do_min_fs.py \
|
2015-03-31 16:39:17 +02:00
|
|
|
-r "$(VERSION)" \
|
|
|
|
-b "bash strace" \
|
2015-04-09 20:33:19 +02:00
|
|
|
$(foreach m,$(EXTRA_AXE_MODULES), -e "$(EXTRA_AXE_MODULES_DIR)/$(m):lib/modules/axe/$(m)") \
|
|
|
|
$(foreach m,$(ORIG_FILES), -e "$(EXTRA_AXE_MODULES_DIR)/../$(m):lib/modules/axe/$(m)") \
|
2015-04-20 15:43:32 +02:00
|
|
|
-e "tools/i2c_mangle.ko:lib/modules/axe/i2c_mangle.ko" \
|
2015-04-08 17:30:03 +02:00
|
|
|
$(foreach m,$(KMODULES), -e "kernel/$(m):lib/modules/$(m)") \
|
2015-04-10 15:08:02 +02:00
|
|
|
-e "tools/axehelper:sbin/axehelper" \
|
2015-04-08 13:54:26 +02:00
|
|
|
-e "apps/$(BUSYBOX)/busybox:bin/busybox" \
|
2015-03-28 20:33:17 +01:00
|
|
|
$(foreach f,$(DROPBEAR_SBIN_FILES), -e "apps/$(DROPBEAR)/$(f):sbin/$(f)") \
|
|
|
|
$(foreach f,$(DROPBEAR_BIN_FILES), -e "apps/$(DROPBEAR)/$(f):usr/bin/$(f)") \
|
2015-04-20 15:43:32 +02:00
|
|
|
-e "apps/$(ETHTOOL)/ethtool:sbin/ethtool" \
|
2015-04-21 14:54:49 +02:00
|
|
|
$(foreach f,$(RPCBIND_SBIN_FILES), -e "apps/$(RPCBIND)/$(f):usr/sbin/$(f)") \
|
|
|
|
$(foreach f,$(NFSUTILS_SBIN_FILES), -e "apps/$(NFSUTILS)/$(f):usr/sbin/$(notdir $(f))") \
|
2015-03-31 16:39:17 +02:00
|
|
|
-e "apps/minisatip/minisatip:sbin/minisatip" \
|
|
|
|
-e "apps/minisatip/icons/lr.jpg:usr/share/minisatip/icons/lr.jpg" \
|
|
|
|
-e "apps/minisatip/icons/lr.png:usr/share/minisatip/icons/lr.png" \
|
|
|
|
-e "apps/minisatip/icons/sm.jpg:usr/share/minisatip/icons/sm.jpg" \
|
2015-04-08 17:30:03 +02:00
|
|
|
-e "apps/minisatip/icons/sm.png:usr/share/minisatip/icons/sm.png" \
|
2015-05-22 21:48:07 +02:00
|
|
|
-e "apps/$(NANO)/src/nano:usr/bin/nano" \
|
2015-04-08 17:30:03 +02:00
|
|
|
-e "apps/oscam-svn/Distribution/oscam-1.20-unstable_svn$(OSCAM_REV)-sh4-linux:sbin/oscamd"
|
2015-03-27 21:55:18 +01:00
|
|
|
|
|
|
|
.PHONY: fs-list
|
|
|
|
fs-list:
|
|
|
|
cpio -itv < kernel/rootfs-idl4k.cpio
|
2015-03-31 16:39:17 +02:00
|
|
|
|
|
|
|
#
|
|
|
|
# uboot
|
|
|
|
#
|
|
|
|
|
2015-03-31 18:50:27 +02:00
|
|
|
out/idl4k.recovery: patches/uboot-recovery.script
|
|
|
|
$(TOOLPATH)/mkimage -T script -C none \
|
|
|
|
-n 'Restore original idl4k fw' \
|
|
|
|
-d patches/uboot-recovery.script out/idl4k.recovery
|
|
|
|
|
|
|
|
out/idl4k.scr: patches/uboot.script patches/uboot-flash.script out/satip-axe-$(VERSION).fw
|
|
|
|
rm -f out/*.scr out/*.usb out/*.flash out/*.recovery
|
2015-03-31 16:39:17 +02:00
|
|
|
sed -e 's/@VERSION@/$(VERSION)/g' \
|
|
|
|
< patches/uboot.script > out/uboot.script
|
2015-03-31 18:50:27 +02:00
|
|
|
sed -e 's/@VERSION@/$(VERSION)/g' \
|
|
|
|
< patches/uboot-flash.script > out/uboot-flash.script
|
|
|
|
$(TOOLPATH)/mkimage -T script -C none \
|
|
|
|
-n 'SAT>IP AXE fw v$(VERSION)' \
|
|
|
|
-d out/uboot.script out/satip-axe-$(VERSION).usb
|
2015-03-31 16:39:17 +02:00
|
|
|
$(TOOLPATH)/mkimage -T script -C none \
|
|
|
|
-n 'SAT>IP AXE fw v$(VERSION)' \
|
2015-03-31 18:50:27 +02:00
|
|
|
-d out/uboot-flash.script out/satip-axe-$(VERSION).flash
|
|
|
|
ln -sf satip-axe-$(VERSION).usb out/idl4k.scr
|
|
|
|
rm out/uboot.script out/uboot-flash.script
|
2015-03-31 16:39:17 +02:00
|
|
|
|
|
|
|
out/satip-axe-$(VERSION).fw: kernel/arch/sh/boot/uImage.gz
|
|
|
|
mkdir -p out
|
|
|
|
rm -f out/*.fw
|
|
|
|
cp -av kernel/arch/sh/boot/uImage.gz out/satip-axe-$(VERSION).fw
|
|
|
|
|
2015-03-26 20:15:21 +01:00
|
|
|
#
|
|
|
|
# kernel
|
|
|
|
#
|
|
|
|
|
|
|
|
kernel/.config: toolchain/4.5.3-99/opt/STM/STLinux-2.4/devkit/sh4/bin/sh4-linux-gcc-4.5.3
|
2015-04-08 17:30:03 +02:00
|
|
|
cp patches/kernel.config ./kernel/arch/sh/configs/idl4k_defconfig
|
2015-03-26 20:15:21 +01:00
|
|
|
make -C kernel -j $(CPUS) ARCH=sh CROSS_COMPILE=$(TOOLCHAIN_KERNEL)/bin/sh4-linux- idl4k_defconfig
|
|
|
|
|
2015-04-08 17:30:03 +02:00
|
|
|
kernel/drivers/usb/serial/cp210x.ko: toolchain/4.5.3-99/opt/STM/STLinux-2.4/devkit/sh4/bin/sh4-linux-gcc-4.5.3 kernel/.config
|
2015-03-26 20:15:21 +01:00
|
|
|
make -C kernel -j $(CPUS) ARCH=sh CROSS_COMPILE=$(TOOLCHAIN_KERNEL)/bin/sh4-linux- modules
|
2015-04-08 17:30:03 +02:00
|
|
|
|
|
|
|
kernel/arch/sh/boot/uImage.gz: kernel/drivers/usb/serial/cp210x.ko fs.cpio
|
|
|
|
mv fs.cpio kernel/rootfs-idl4k.cpio
|
2015-03-26 20:55:54 +01:00
|
|
|
make -C kernel -j ${CPUS} PATH="$(PATH):$(TOOLPATH)" \
|
|
|
|
ARCH=sh CROSS_COMPILE=$(TOOLCHAIN_KERNEL)/bin/sh4-linux- uImage.gz
|
2015-03-26 20:15:21 +01:00
|
|
|
|
2015-04-20 15:43:32 +02:00
|
|
|
tools/i2c_mangle.ko: tools/i2c_mangle.c
|
|
|
|
make -C tools ARCH=sh CROSS_COMPILE=$(TOOLCHAIN_KERNEL)/bin/sh4-linux- all
|
|
|
|
|
|
|
|
.PHONY: kernel-modules tools/i2c_mangle.ko
|
2015-04-08 17:30:03 +02:00
|
|
|
kernel-modules: kernel/drivers/usb/serial/cp210x.ko
|
|
|
|
|
2015-03-31 16:39:17 +02:00
|
|
|
.PHONY: kernel
|
|
|
|
kernel: kernel/arch/sh/boot/uImage.gz
|
|
|
|
|
2015-03-26 20:15:21 +01:00
|
|
|
.PHONY: kernel-mrproper
|
|
|
|
kernel-mrproper:
|
2015-04-21 14:54:49 +02:00
|
|
|
make -C kernel -j ${CPUS} ARCH=sh CROSS_COMPILE=$(TOOLCHAIN_KERNEL)/bin/sh4-linux- mrproper
|
2015-03-26 20:15:21 +01:00
|
|
|
|
|
|
|
define RPM_UNPACK
|
|
|
|
@mkdir -p $(1)
|
|
|
|
cd $(1) ; rpm2cpio ../$(2) | cpio -idv
|
|
|
|
endef
|
|
|
|
|
|
|
|
toolchain/4.5.3-99/opt/STM/STLinux-2.4/devkit/sh4/bin/sh4-linux-gcc-4.5.3:
|
|
|
|
$(call RPM_UNPACK,toolchain/4.5.3-99,stlinux24-cross-sh4-binutils-2.24.51.0.3-76.i386.rpm)
|
|
|
|
$(call RPM_UNPACK,toolchain/4.5.3-99,stlinux24-cross-sh4-cpp-4.5.3-99.i386.rpm)
|
|
|
|
$(call RPM_UNPACK,toolchain/4.5.3-99,stlinux24-cross-sh4-gcc-4.5.3-99.i386.rpm)
|
|
|
|
|
|
|
|
#
|
|
|
|
# extract kernel modules from firmware
|
|
|
|
#
|
|
|
|
|
|
|
|
.PHONY: kernel-axe-modules
|
|
|
|
kernel-axe-modules: firmware/initramfs/root/modules_idl4k_7108_ST40HOST_LINUX_32BITS/axe_dmx.ko
|
|
|
|
|
|
|
|
firmware/initramfs/root/modules_idl4k_7108_ST40HOST_LINUX_32BITS/axe_dmx.ko:
|
|
|
|
cd firmware ; ../tools/cpio-idl4k-bin.sh extract
|
|
|
|
chmod -R u+rw firmware/initramfs
|
|
|
|
|
2015-04-02 21:42:21 +02:00
|
|
|
#
|
|
|
|
# syscall dump
|
|
|
|
#
|
|
|
|
|
2015-04-10 15:08:02 +02:00
|
|
|
tools/axehelper: tools/axehelper.c
|
|
|
|
$(TOOLCHAIN)/bin/sh4-linux-gcc -o tools/axehelper -Wall -lrt tools/axehelper.c
|
|
|
|
|
2015-04-15 18:05:21 +02:00
|
|
|
tools/axehelper.$(HOST_ARCH): tools/axehelper.c
|
|
|
|
gcc -o tools/axehelper.$(HOST_ARCH) -Wall -lrt tools/axehelper.c
|
|
|
|
|
2015-04-03 13:20:23 +02:00
|
|
|
tools/syscall-dump.so: tools/syscall-dump.c
|
|
|
|
$(TOOLCHAIN)/bin/sh4-linux-gcc -o tools/syscall-dump.o -c -fPIC -Wall tools/syscall-dump.c
|
|
|
|
$(TOOLCHAIN)/bin/sh4-linux-gcc -o tools/syscall-dump.so -shared -rdynamic tools/syscall-dump.o -ldl
|
|
|
|
|
|
|
|
tools/syscall-dump.so.$(HOST_ARCH): tools/syscall-dump.c
|
|
|
|
gcc -o tools/syscall-dump.o.$(HOST_ARCH) -c -fPIC -Wall tools/syscall-dump.c
|
|
|
|
gcc -o tools/syscall-dump.so.$(HOST_ARCH) -shared -rdynamic tools/syscall-dump.o.$(HOST_ARCH) -ldl
|
|
|
|
|
|
|
|
.PHONY: s2i_dump
|
|
|
|
s2i_dump: tools/syscall-dump.so
|
|
|
|
if test -z "$(SATIP_HOST)"; then echo "Define SATIP_HOST variable"; exit 1; fi
|
2015-04-09 19:49:35 +02:00
|
|
|
cd firmware/initramfs && tar cvzf ../fw.tgz --owner=root --group=root *
|
|
|
|
scp tools/syscall-dump.so tools/s2i-dump.sh firmware/fw.tgz \
|
2015-04-03 21:10:51 +02:00
|
|
|
root@$(SATIP_HOST):/root
|
2015-04-02 21:42:21 +02:00
|
|
|
|
2015-03-28 09:36:07 +01:00
|
|
|
#
|
|
|
|
# minisatip
|
|
|
|
#
|
|
|
|
|
2015-03-29 21:31:38 +02:00
|
|
|
apps/minisatip/axe.h:
|
2015-04-10 15:08:02 +02:00
|
|
|
$(call GIT_CLONE,https://github.com/catalinii/minisatip.git,minisatip,$(MINISATIP_COMMIT))
|
2015-03-29 21:31:38 +02:00
|
|
|
cd apps/minisatip; patch -p1 < ../../patches/minisatip-axe.patch
|
2015-03-28 09:36:07 +01:00
|
|
|
|
2015-03-29 21:31:38 +02:00
|
|
|
apps/minisatip/minisatip: apps/minisatip/axe.h
|
2015-03-28 09:36:07 +01:00
|
|
|
make -C apps/minisatip \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
2015-05-12 11:27:26 +02:00
|
|
|
CFLAGS="-O2 -DAXE=1 -DSYS_DVBT2=16 -I$(CURDIR)/kernel/include"
|
2015-03-28 09:36:07 +01:00
|
|
|
|
2015-03-28 20:33:17 +01:00
|
|
|
.PHONY: minisatip
|
|
|
|
minisatip: apps/minisatip/minisatip
|
|
|
|
|
2015-03-29 21:31:38 +02:00
|
|
|
.PHONY: minisatip-clean
|
|
|
|
minisatip-clean:
|
|
|
|
rm -rf apps/minisatip
|
|
|
|
|
2015-04-08 13:54:26 +02:00
|
|
|
#
|
|
|
|
# busybox
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(BUSYBOX)/Makefile:
|
|
|
|
$(call WGET,http://busybox.net/downloads/$(BUSYBOX).tar.bz2,apps/$(BUSYBOX).tar.bz2)
|
|
|
|
tar -C apps -xjf apps/$(BUSYBOX).tar.bz2
|
|
|
|
|
|
|
|
apps/$(BUSYBOX)/busybox: apps/$(BUSYBOX)/Makefile
|
|
|
|
make -C apps/$(BUSYBOX) CROSS_COMPILE=$(TOOLCHAIN)/bin/sh4-linux- defconfig
|
|
|
|
make -C apps/$(BUSYBOX) CROSS_COMPILE=$(TOOLCHAIN)/bin/sh4-linux-
|
|
|
|
#make -C apps/$(DROPBEAR) PROGRAMS="dropbear dbclient dropbearkey dropbearconvert scp"
|
|
|
|
|
|
|
|
.PHONY: busybox
|
|
|
|
busybox: apps/$(BUSYBOX)/busybox
|
|
|
|
|
2015-03-28 20:33:17 +01:00
|
|
|
#
|
|
|
|
# dropbear
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(DROPBEAR)/configure:
|
|
|
|
$(call WGET,https://matt.ucc.asn.au/dropbear/$(DROPBEAR).tar.bz2,apps/$(DROPBEAR).tar.bz2)
|
|
|
|
tar -C apps -xjf apps/$(DROPBEAR).tar.bz2
|
|
|
|
|
|
|
|
apps/$(DROPBEAR)/dropbear: apps/$(DROPBEAR)/configure
|
|
|
|
cd apps/$(DROPBEAR) && \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
./configure \
|
|
|
|
--host=sh4-linux \
|
|
|
|
--prefix=/ \
|
|
|
|
--disable-lastlog \
|
|
|
|
--disable-utmp \
|
|
|
|
--disable-utmpx \
|
|
|
|
--disable-wtmp \
|
|
|
|
--disable-wtmpx
|
2015-04-08 13:54:26 +02:00
|
|
|
sed -e 's/DEFAULT_PATH \"\/usr\/bin:\/bin\"/DEFAULT_PATH \"\/sbin:\/usr\/sbin:\/bin:\/usr\/bin:\/usr\/local\/bin\"/g' \
|
|
|
|
< apps/$(DROPBEAR)/options.h > apps/$(DROPBEAR)/options.h.2
|
|
|
|
mv apps/$(DROPBEAR)/options.h.2 apps/$(DROPBEAR)/options.h
|
2015-03-28 20:33:17 +01:00
|
|
|
make -C apps/$(DROPBEAR) PROGRAMS="dropbear dbclient dropbearkey dropbearconvert scp"
|
|
|
|
|
|
|
|
.PHONY: dropbear
|
|
|
|
dropbear: apps/$(DROPBEAR)/dropbear
|
|
|
|
|
2015-04-20 15:43:32 +02:00
|
|
|
#
|
|
|
|
# ethtool
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(ETHTOOL)/configure:
|
|
|
|
$(call WGET,https://www.kernel.org/pub/software/network/ethtool/$(ETHTOOL).tar.gz,apps/$(ETHTOOL).tar.gz)
|
|
|
|
tar -C apps -xzf apps/$(ETHTOOL).tar.gz
|
|
|
|
|
|
|
|
apps/$(ETHTOOL)/ethtool: apps/$(ETHTOOL)/configure
|
|
|
|
cd apps/$(ETHTOOL) && \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
CFLAGS="-O2" \
|
|
|
|
./configure \
|
|
|
|
--host=sh4-linux \
|
|
|
|
--prefix=/
|
|
|
|
make -C apps/$(ETHTOOL)
|
|
|
|
|
|
|
|
.PHONY: ethtool
|
|
|
|
ethtool: apps/$(ETHTOOL)/ethtool
|
|
|
|
|
2015-04-21 14:54:49 +02:00
|
|
|
#
|
|
|
|
# libtirpc
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(LIBTIRPC)/configure:
|
|
|
|
$(call WGET,http://sourceforge.net/projects/libtirpc/files/libtirpc/$(LIBTIRPC_VERSION)/$(LIBTIRPC).tar.bz2,apps/$(LIBTIRPC).tar.bz2)
|
|
|
|
tar -C apps -xjf apps/$(LIBTIRPC).tar.bz2
|
|
|
|
|
|
|
|
apps/$(LIBTIRPC)/src/.libs/libtirpc.a: apps/$(LIBTIRPC)/configure
|
|
|
|
cd apps/$(LIBTIRPC) && \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
CFLAGS="-O2" \
|
|
|
|
./configure \
|
|
|
|
--host=sh4-linux \
|
|
|
|
--prefix=/ \
|
|
|
|
--disable-shared \
|
|
|
|
--disable-gssapi \
|
|
|
|
--disable-ipv6
|
|
|
|
make -C apps/$(LIBTIRPC)
|
|
|
|
|
|
|
|
.PHONY: libtirpc
|
|
|
|
libtirpc: apps/$(LIBTIRPC)/src/.libs/libtirpc.a
|
|
|
|
|
|
|
|
#
|
|
|
|
# rpcbind
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(RPCBIND)/configure:
|
|
|
|
$(call WGET,http://sourceforge.net/projects/rpcbind/files/rpcbind/$(RPCBIND_VERSION)/$(RPCBIND).tar.bz2,apps/$(RPCBIND).tar.bz2)
|
|
|
|
tar -C apps -xjf apps/$(RPCBIND).tar.bz2
|
|
|
|
|
|
|
|
apps/$(RPCBIND)/rpcbind: apps/$(LIBTIRPC)/src/.libs/libtirpc.a apps/$(RPCBIND)/configure
|
|
|
|
cd apps/$(RPCBIND) && \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
CFLAGS="-O2" \
|
|
|
|
TIRPC_CFLAGS="-I$(PWD)/apps/$(LIBTIRPC)/tirpc" \
|
|
|
|
TIRPC_LIBS="-L$(PWD)/apps/$(LIBTIRPC)/src/.libs -Wl,-Bstatic -ltirpc -Wl,-Bdynamic" \
|
|
|
|
./configure \
|
|
|
|
--host=sh4-linux \
|
|
|
|
--prefix=/ \
|
|
|
|
--with-systemdsystemunitdir=no
|
|
|
|
make -C apps/$(RPCBIND)
|
|
|
|
|
|
|
|
.PHONY: rpcbind
|
|
|
|
rpcbind: apps/$(RPCBIND)/rpcbind
|
|
|
|
|
|
|
|
#
|
|
|
|
# nfs-utils
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(NFSUTILS)/configure:
|
|
|
|
$(call WGET,http://sourceforge.net/projects/nfs/files/nfs-utils/$(NFSUTILS_VERSION)/$(NFSUTILS).tar.bz2,apps/$(NFSUTILS).tar.bz2)
|
|
|
|
tar -C apps -xjf apps/$(NFSUTILS).tar.bz2
|
|
|
|
|
|
|
|
apps/$(NFSUTILS)/utils/exportfs/exportfs: apps/$(RPCBIND)/rpcbind apps/$(NFSUTILS)/configure
|
|
|
|
cd apps/$(NFSUTILS) && \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
CFLAGS="-O2" \
|
|
|
|
TIRPC_CFLAGS="-I$(PWD)/apps/$(LIBTIRPC)/tirpc" \
|
|
|
|
TIRPC_LIBS="-L$(PWD)/apps/$(LIBTIRPC)/src/.libs -Wl,-Bstatic -ltirpc -Wl,-Bdynamic" \
|
|
|
|
./configure \
|
|
|
|
--host=sh4-linux \
|
|
|
|
--prefix=/ \
|
|
|
|
--disable-mount \
|
|
|
|
--disable-nfsdcltrack \
|
|
|
|
--disable-nfsv4 \
|
|
|
|
--disable-gss \
|
|
|
|
--disable-ipv6 \
|
|
|
|
--disable-uuid \
|
|
|
|
--without-tcp-wrappers
|
|
|
|
make -C apps/$(NFSUTILS)
|
|
|
|
|
|
|
|
.PHONY: nfsutils
|
|
|
|
nfsutils: apps/$(NFSUTILS)/utils/exportfs/exportfs
|
|
|
|
|
2015-04-08 17:30:03 +02:00
|
|
|
#
|
|
|
|
# oscam
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/oscam-svn/config.sh:
|
|
|
|
cd apps && svn checkout http://www.streamboard.tv/svn/oscam/trunk oscam-svn -r $(OSCAM_REV)
|
|
|
|
|
|
|
|
apps/oscam-svn/Distribution/oscam-1.20-unstable_svn$(OSCAM_REV)-sh4-linux: apps/oscam-svn/config.sh
|
|
|
|
make -C apps/oscam-svn CROSS_DIR=$(TOOLCHAIN)/bin/ CROSS=sh4-linux-
|
|
|
|
|
|
|
|
.PHONY: oscam
|
|
|
|
oscam: apps/oscam-svn/Distribution/oscam-1.20-unstable_svn$(OSCAM_REV)-sh4-linux
|
|
|
|
|
2015-05-22 21:48:07 +02:00
|
|
|
#
|
|
|
|
# nano
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/$(NANO)/configure:
|
|
|
|
$(call WGET,$(NANO_DOWNLOAD),apps/$(NANO_FILENAME))
|
|
|
|
tar -C apps -xzf apps/$(NANO_FILENAME)
|
|
|
|
|
|
|
|
apps/$(NANO)/nano: apps/$(NANO)/configure
|
|
|
|
cd apps/$(NANO) && \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
CFLAGS="-O2" \
|
|
|
|
./configure \
|
|
|
|
--host=sh4-linux \
|
|
|
|
--prefix=/
|
|
|
|
make -C apps/$(NANO)
|
|
|
|
|
|
|
|
.PHONY: nano
|
|
|
|
nano: apps/$(NANO)/nano
|
|
|
|
|
2015-05-12 11:27:26 +02:00
|
|
|
#
|
|
|
|
# tvheadend
|
|
|
|
#
|
|
|
|
|
|
|
|
apps/tvheadend/Makefile:
|
|
|
|
$(call GIT_CLONE,https://github.com/tvheadend/tvheadend.git,tvheadend,$(TVHEADEND_COMMIT))
|
|
|
|
|
|
|
|
apps/tvheadend/build.linux/tvheadend: apps/tvheadend/Makefile
|
|
|
|
cd apps/tvheadend && \
|
|
|
|
PKG_CONFIG_PATH=$(TOOLCHAIN)/target/usr/lib/pkgconfig \
|
|
|
|
PKG_CONFIG=$(TOOLPATH)/pkg-config \
|
|
|
|
ARCH=sh \
|
|
|
|
CC=$(TOOLCHAIN)/bin/sh4-linux-gcc \
|
|
|
|
./configure \
|
|
|
|
--disable-dbus_1 \
|
|
|
|
--disable-imagecache \
|
2015-05-22 20:37:54 +02:00
|
|
|
--disable-uriparser \
|
2015-05-12 11:27:26 +02:00
|
|
|
--enable-bundle
|
|
|
|
$(MAKE) -j $(CPUS) -C apps/tvheadend
|
|
|
|
|
|
|
|
.PHONY: tvheadend
|
|
|
|
tvheadend: apps/tvheadend/build.linux/tvheadend
|
|
|
|
|
2015-03-26 20:15:21 +01:00
|
|
|
#
|
|
|
|
# clean all
|
|
|
|
#
|
2015-03-26 20:55:54 +01:00
|
|
|
|
2015-03-26 20:15:21 +01:00
|
|
|
.PHONY: clean
|
|
|
|
clean: kernel-mrproper
|
|
|
|
rm -rf firmware/initramfs
|
|
|
|
rm -rf toolchain/4.5.3-99
|
2015-04-03 13:20:23 +02:00
|
|
|
rm -rf tools/syscall-dump.o* tools/syscall-dump.s*
|