From 1a20bb0f4b9017a1fbc8e7a6b56b335c3bca4367 Mon Sep 17 00:00:00 2001 From: risci_atom Date: Tue, 12 Apr 2011 03:12:28 +0000 Subject: [PATCH] Added re-branding script git-svn-id: http://svn.librewrt.org/librewrt@132 d459f2a8-9e7c-4474-95e1-7f88c49cc8e2 --- branding/creative-craftsman/librewrt.sh | 69 +++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100755 branding/creative-craftsman/librewrt.sh diff --git a/branding/creative-craftsman/librewrt.sh b/branding/creative-craftsman/librewrt.sh new file mode 100755 index 0000000..38ad256 --- /dev/null +++ b/branding/creative-craftsman/librewrt.sh @@ -0,0 +1,69 @@ +#!/bin/sh +# LibreWRT Rebranding Script +# Copyright (C) 2011 Jason Self +# Copyright (C) 2011 Robert Call +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# The LibreWRT Re-branding script is used to remove non-free software +# from OpenWRT. The LibreWRT project does not suggest that users +# download LibreWrt Sources, for they contain non-free software. +# Free your device. + +# Also note that this script currently does not replace the kernel +# that feature will be added at a later date. As of now, +# creative-craftsman does use a linux-libre kernel. + clear + echo " " + echo " _ _ _ __ _____ _____ " + echo " | (_) |__ _ _ ___\\ \\ / / _ \_ _| " + echo " | | | '_ \\ '_/ -_)\\ \\/\\/ /| / | | " + echo " |_|_|_.__/_| \___| \\_/\\_/ |_|_\\ |_| " + echo " -----------------------------------------" + echo " Creative Craftsman Version 2 Pre-Alpha 1 " + + +# Remove OpenWRT Subversion / git meta data +find ./ -iname .svn -exec rm -fr {} + +find ./ -iname .gitnore -exec rm -fr {} + + +# re-name LeTeX documents +mv docs/librewrt.sty docs/librewrt.sty +mv docs/librewrt.tex docs/librewrt.tex + +# Clean target directory +find target/linux \( ! -path "target/linux/ar71xx/*" ! -path "target/linux/generic/*" ! -path "target/linux/uml/*" ! -path "target/linux/x86/*" ! -path "target/linux/xburst/*" ! -path "target/linux/Makefile" \) -delete > /dev/null +rm target/linux/ar71xx/generic/profiles/02-madwifi.mk > /dev/null + +# Clean package directory +find package \( ! -path "package/base-files/*" ! -path "package/busybox/*" ! -path "package/dnsmasq/*" ! -path "package/dropbear/*" ! -path "package/firewall/*" ! -path "package/grub/*" ! -path "package/hotplug2/*" ! -path "package/iptables/*" ! -path "package/kernel/*" ! -path "package/libpcap/*" ! -path "package/libreadline/*" ! -path "package/libtool/*" ! -path "package/linux-atm/*" ! -path "package/lua/*" ! -path "package/ncurses/*" ! -path "package/ocf-crypto-headers/*" ! -path "package/mtd/*" ! -path "package/openssl/*" ! -path "package/opkg/*" ! -path "package/ppp/*" ! -path "package/pptp/*" ! -path "package/uci/*" ! -path "package/udevtrigger/*" ! -path "package/zlib/*" ! -path "package/Makefile" \) -delete > /dev/null +find package/kernel/modules -iname wireless.mk -exec rm -fr {} + +# Clean firmware-utils directory +find tools/firmware-utils \( ! -path "tools/firmware-utils/src/sha1.h" ! -path "tools/firmware-utils/src/sha1.c" ! -path "tools/firmware-utils/src/mkplanexfw.c" ! -path "tools/firmware-utils/Makefile" \) -delete > /dev/null +find tools/Makefile -exec sed -i 's/firmware-utils//g' {} \; +# Clean scripts directory +rm scripts/slugimage.pl + +# Clean tools directory +rm -fr tools/upslug2 +rm -fr tools/wrt350nv2-builder + +#create card dir as part of base-files +mkdir package/base-files/files/card + +# Find "LIBREWRT", "LibreWrt", "librewrt" -> "LIBREWRT", "LibreWrt", "librewrt" +find ./ -type f -exec sed -i 's/OPENWRT/LIBREWRT/g' {} \; +find ./ -type f -exec sed -i 's/OpenWrt/LibreWrt/g' {} \; +find ./ -type f -exec sed -i 's/openwrt/librewrt/g' {} \; +find ./ -type f -exec sed -i 's/LibreWrt.org/OpenWrt.org/g' {} \; +find ./ -type f -exec sed -i 's/Creative Craftsman/Creative Craftsman/g' {} \; -- 2.35.1