aboutsummaryrefslogtreecommitdiffstats
path: root/tools
Commit message (Collapse)AuthorAgeFilesLines
* mkrasimage: fix segmentation faultMichael T Farnworth2020-03-291-9/+10
| | | | | | | | | | | | | | Code was attempting to determine the size of the file before it was actually known and allocating insufficient memory space. Images above a certain size caused a segmentation fault. Moving the calloc() ensured ensured that large images didn't result in a buffer overflow on memcpy(). Signed-off-by: Michael T Farnworth <michael@turf.org> [fixed name in From to match one in SoB] Signed-off-by: Petr Štetiar <ynezz@true.cz> (cherry picked from commit b468353a373d181c4362ff690d7b22a08f5f6949)
* tools: squashfskit4: fix build with GCC10Robert Marko2020-03-292-1/+44
| | | | | | | | | In order to build squashfskit with GCC10, this backport from upstream is needed. Signed-off-by: Robert Marko <robert.marko@sartura.hr> [increase PKG_RELEASE] Signed-off-by: Alexander Couzens <lynxis@fe80.eu> (cherry picked from commit be4ed1db18e68cc57f03788b4529afbbf629411c)
* squashfskit4/Makefile: introduce PKG_RELEASE=1Alexander Couzens2020-03-291-1/+1
| | | | | | | When adding patches, the PKG_RELEASE should be increased. Signed-off-by: Alexander Couzens <lynxis@fe80.eu> (cherry picked from commit 1f4020a293476d5e34461a655cb9f6540cefeea2)
* ath79: add support for TP-Link Archer C60 v3Adrian Schmutzler2020-03-201-0/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link Archer C60 v3 is a dual-band AC1350 router, based on Qualcomm/Atheros QCA9561 + QCA9886. It seems to be identical to the v2 revision, except that it lacks a WPS LED and has different GPIO for amber WAN LED. Specification: - 775/650/258 MHz (CPU/DDR/AHB) - 64 MB of RAM (DDR2) - 8 MB of FLASH (SPI NOR) - 3T3R 2.4 GHz - 2T2R 5 GHz - 5x 10/100 Mbps Ethernet - 6x LED, 2x button - UART header on PCB Flash instruction (WebUI): Download *-factory.bin image and upload it via the firmwary upgrade function of the stock firmware WebUI. Flash instruction (TFTP): 1. Set PC to fixed IP address 192.168.0.66 2. Download *-factory.bin image and rename it to tp_recovery.bin 3. Start a tftp server with the file tp_recovery.bin in its root directory 4. Turn off the router 5. Press and hold reset button 6. Turn on router with the reset button pressed and wait ~15 seconds 7. Release the reset button and after a short time the firmware should be transferred from the tftp server 8. Wait ~30 second to complete recovery While TFTP works for OpenWrt images, my device didn't accept the only available official firmware "Archer C60(EU)_V3.0_190115.bin". In contrast to earlier revisions (v2), the v3 contains the (same) MAC address twice, once in 0x1fa08 and again in 0x1fb08. While the partition-table on the device refers to the latter, the firmware image contains a different partition-table for that region: name device firmware factory-boot 0x00000-0x1fb00 0x00000-0x1fa00 default-mac 0x1fb00-0x1fd00 0x1fa00-0x1fc00 pin 0x1fd00-0x1fe00 0x1fc00-0x1fd00 product-info 0x1fe00-0x1ff00 0x1fd00-0x1ff00 device-id 0x1ff00-0x20000 0x1ff00-0x20000 While the MAC address is present twice, other data like the PIN isn't, so with the partitioning from the firmware image the PIN on the device would actually be outside of its partition. Consequently, the patch uses the MAC location from the device (which is the same as for the v2). Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> (cherry picked from commit 646d95c374072598fab9e949ef4425177c5c7960)
* firmware-utils: add lxlfw tool for generating Luxul firmwaresDan Haab2020-02-072-0/+283
| | | | | | | It's a simple tool prepending image with a Luxul header. Signed-off-by: Dan Haab <dan.haab@legrand.com> (cherry picked from commit 9aa6569aa669767ec9febf1de01a3983a1cb9482)
* tools: tplink-safeloader: update soft_ver for TP-Link Archer C6 v2 (EU)Anderson Vulczak2020-01-231-1/+1
| | | | | | | | | | | | | | | | | | This patch updates "soft_ver" for TP-Link Archer C6 v2 (EU). It makes possible to upload OpenWrt on lastest vendor's firmware as the web-based updater checks for major.minor version during upload. Due to that on next major/minor version update TP-Link will stop us from using the web-based firmware update tool, so it will require a new patch on soft_ver to match major and minor version. Up to today's latest stock firmware the patch (major.minor.patch) version does not matters, that allows downgrade from 1.1.4 to 1.1.1 but do not allow downgrade from 1.1.X to 1.0.X. Signed-off-by: Anderson Vulczak <andi@andi.com.br> (cherry picked from commit 7a8bfbf0ffaea14e15ae2016a54adf48337c6251) (cherry picked from commit eeb93e5c2b23518e372737ecf8fdde4b9f139a49)
* ath79: add support for the TP-LINK CPE220 V3Andrew Cameron2020-01-081-0/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for a popular low-cost 2.4GHz N based AP Specifications: SoC: Qualcomm Atheros QCA9533 (650MHz) RAM: 64MB Storage: 8 MB SPI NOR Wireless: 2.4GHz N based built into SoC 2x2 Ethernet: 2x 100/10 Mbps, integrated into SoC Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 This also applies some minor changes to the common DTSI: - use &wmac for label-mac-device, as this one is actually set up in common DTSI - move &eth0 to parent DTSI - fix several leading spaces, added/removed newlines Signed-off-by: Andrew Cameron <apcameron@softhome.net> [DTS style fixes/improvements, updated commit message/title, backport to 19.07] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* expat: Update to version 2.2.9Josef Schlehofer2019-11-071-2/+2
| | | | | | | Fixes CVE-2019-15903 Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com> (cherry picked from commit b4af2c689fc8736777940b7bbf009bb1672296ec)
* tools/e2fsprogs: Update to version 1.45.4Josef Schlehofer2019-11-071-2/+2
| | | | | | | Fixes CVE-2019-5094 Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com> (cherry picked from commit 700e7a2eb9c515ffe4f3278857e538ea37cc5e56)
* ar71xx: improve support for TP-Link CPE510 v2Adrian Schmutzler2019-11-061-2/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes commit bae927c551fd ("ar71xx: add support for TP-LINK CPE510 V2.0") where the support for this device wasn't optimal. Device support for the CPE510v2 so far has been a hack to enable flashing with CPE510v1 images. Those even have different hardware (e.g. additional ethernet port). With this patch, we provide proper support for this device in ar71xx. Installation: - Flash factory image through stock firmware WEB UI or through TFTP - To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. - Rename factory image to recovery.bin - Stock TFTP server IP: 192.168.0.100 - Stock device TFTP address: 192.168.0.254 Fixes: bae927c551fd ("ar71xx: add support for TP-LINK CPE510 V2.0") Signed-off-by: Andrew Cameron <apcameron@softhome.net> [Rebased onto revert commit, changed comments in mach-cpe510.c, changed commit title and description, fixed eth0 MAC address, removed eth1 initialization] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> [squashed revert, added fixes tag] Signed-off-by: Petr Štetiar <ynezz@true.cz> (cherry picked from commit c79b796280fa5cd64bac663f9d5e5d9a737c30d6) [added CPE510V2 entry to tplink-safeloader.c] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* tplink-safeloader: fix compilation warningsIlya Gordeev2019-10-191-12/+13
| | | | | Signed-off-by: Ilya Gordeev <Mirraz@users.noreply.github.com> (cherry picked from commit 5daf09435311922cad32b66b75d13b9367db62f7)
* tools: mkimage: fix __u64 typedef conflict with new glibcYousong Zhou2019-09-121-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Including "sys/stat.h" from newer glibc will cause __u64 from linux uapi header to be included, causing compilation failure for u-boot tools USE_HOSTCC Remove typedef for __u64 in include/compiler.h to fix the issue. It should be safe because as of u-boot-2018.03, no ref to __u64 is found under u-boot tools/ directory Error message snippet follows HOSTCC tools/mkenvimage.o In file included from /usr/include/asm-generic/types.h:7, from /usr/include/asm/types.h:5, from /usr/include/linux/types.h:5, from /usr/include/linux/stat.h:5, from /usr/include/bits/statx.h:30, from /usr/include/sys/stat.h:446, from tools/mkenvimage.c:21: /usr/include/asm-generic/int-ll64.h:31:42: error: conflicting types for '__u64' 31 | __extension__ typedef unsigned long long __u64; | ^~~~~ In file included from <command-line>: ././include/compiler.h:69:18: note: previous declaration of '__u64' was here 69 | typedef uint64_t __u64; | ^~~~~ make[5]: *** [scripts/Makefile.host:116: tools/mkenvimage.o] Error 1 Ref: https://forum.openwrt.org/t/compile-error-19-07/44423 Ref: https://bugzilla.redhat.com/show_bug.cgi?id=1699194 Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
* upslug2: Update to git repositoryRosen Penev2019-09-042-297/+7
| | | | | | | | | | | | | | | This has two improvements over the current version. An autotools fix and application of the wrt350v2 patch. Cleaned up Makefile as a result of makefiles being fixed. Note that this package is not really used as it depends on orion, which is classified as broken. This is the last package that uses svn in the tree. Signed-off-by: Rosen Penev <rosenp@gmail.com> (cherry picked from commit ac31ec0f62af31cdbc348911503bae8c152f8516)
* tools: libelf: fix headers to trigger -Wundef warningsJo-Philipp Wich2019-09-041-0/+198
| | | | | | | | | | | | | When libelf from tools/ is used for building the kernel, compilation aborts due to access to undefined defines since Kbuild adds -Wundef to the compiler flags. Patch the header files to use `#if defined(...)` instead of `#if ...` to prevent such issues. Ref: https://github.com/NixOS/nixpkgs/issues/59929 Signed-off-by: Jo-Philipp Wich <jo@mein.io> (cherry picked from commit f3ab336d7ceda929dc8dc4a8b09a9552dc6be0b1)
* tools: libelf: install pkg-config fileJo-Philipp Wich2019-09-041-1/+3
| | | | | | | | Install the pkg-config definition for libelf in order to allow the kernel build process discover it later on. Signed-off-by: Jo-Philipp Wich <jo@mein.io> (cherry picked from commit d3f86c9cc3e465fbca51aaadbb274856831ba56c)
* tools/cmake: Update to 3.15.1Daniel Engberg2019-09-045-33/+22
| | | | | | | | | | | | | Update CMake to 3.15.1 Refresh patches Remove inofficial fossies.org and replace with GitHub (link on official site) Remove 150-C-feature-checks-Match-warnings-more-strictly.patch as it's a no longer needed backport from upstream. Disable ccache if GCC is 4.8, 4.9 or 5.X to avoid build failures. Reference: https://github.com/openwrt/openwrt/pull/1929 Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> (cherry picked from commit 413c68d120043cd8ff1f4aa057d33c140bfc6bfa)
* tools/e2fsprogs: Update to 1.45.3Daniel Engberg2019-09-044-36/+13
| | | | | | | | | | Update e2fsprogs to 1.45.3 Remove OpenBSD patch Remove Darwin patch, neither macports or brew patches these files Add patch to avoid crond detection on host OS Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> (cherry picked from commit 234f7a9e5dccfaa449d75a120ef90080d0715436)
* expat: Update to 2.2.7Daniel Engberg2019-09-041-2/+2
| | | | | | | Update (lib)expat to 2.2.7 Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> (cherry picked from commit 7270fdb62ff86f7b85c6dfbc0ea4ff0ba5ff9b9e)
* ccache: update to 3.7.2DENG Qingfang2019-09-042-3/+3
| | | | | | | | | | Update ccache to 3.7.2 Release notes: https://ccache.dev/releasenotes.html#_ccache_3_7_2 Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn> (cherry picked from commit 2caf747116337645420653ec003799a8eef69229)
* tools: libressl: fix compilation for non-glibc clib (FS#2400)Hans Dedecker2019-09-041-0/+23
| | | | | | | | | | | | | | Fixes compilaton issue for non glibc clibs : libtool: compile: gcc -DPACKAGE_NAME=\"libressl\" -DPACKAGE_TARNAME=\"libressl\" -DPACKAGE_VERSION=\"2.9.2\" "-DPACKAGE_STRING=\"libressl 2.9.2\"" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DPACKAGE=\"libressl\" -DVERSION=\"2.9.2\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" -DHAVE_SYMLINK=1 -DHAVE_ERR_H=1 -DHAVE_ASPRINTF=1 -DHAVE_MEMMEM=1 -DHAVE_STRLCAT=1 -DHAVE_STRLCPY=1 -DHAVE_STRNDUP=1 -DHAVE_STRNLEN=1 -DHAVE_STRSEP=1 -DHAVE_TIMEGM=1 -DHAVE_SYSLOG=1 -DHAVE_ACCEPT4=1 -DHAVE_PIPE2=1 -DHAVE_POLL=1 -DHAVE_SOCKETPAIR=1 -DHAVE_EXPLICIT_BZERO=1 -DHAVE_GETAUXVAL=1 -DHAVE_GETAUXVAL=1 -DHAVE_DL_ITERATE_PHDR=1 -DHAVE_CLOCK_GETTIME=1 -DHAVE_VA_COPY=1 -DHAS_GNU_WARNING_LONG=1 -DSIZEOF_TIME_T=8 -I. -I../include -I../include/compat -DLIBRESSL_INTERNAL -D__BEGIN_HIDDEN_DECLS= -D__END_HIDDEN_DECLS= -I../crypto/asn1 -I../crypto/bn -I../crypto/ec -I../crypto/ecdsa -I../crypto/evp -I../crypto/modes -I../crypto -I/builds/pantacor/pv-platforms/openwrt-base/openwrt/staging_dir/host/include -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_POSIX_SOURCE -D_GNU_SOURCE -D__STRICT_ALIGNMENT -O2 -I/builds/pantacor/pv-platforms/openwrt-base/openwrt/staging_dir/host/include -fpic -Wall -std=gnu99 -fno-strict-aliasing -fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-strong -DHAVE_GNU_STACK -Wno-pointer-sign -MT compat/getprogname_linux.lo -MD -MP -MF compat/.deps/getprogname_linux.Tpo -c compat/getprogname_linux.c -o compat/getprogname_linux.o compat/getprogname_linux.c: In function 'getprogname': compat/getprogname_linux.c:32:2: error: #error "Cannot emulate getprogname" #error "Cannot emulate getprogname" ^~~~~ Reported-by: Anibal Portero <anibal.portero@pantacor.com> Signed-off-by: Hans Dedecker <dedeckeh@gmail.com> (cherry picked from commit 1282a630272c59dfd105262772a2ca136084db03)
* tools: libressl: fix build on MacOSKevin Darbyshire-Bryant2019-09-041-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Making all in tests depbase=`echo handshake_table.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\ gcc -DPACKAGE_NAME=\"libressl\" -DPACKAGE_TARNAME=\"libressl\" -DPACKAGE_VERSION=\"2.9.2\" -DPACKAGE_STRING=\"libressl\ 2.9.2\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DPACKAGE=\"libressl\" -DVERSION=\"2.9.2\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" -DHAVE_SYMLINK=1 -DHAVE_ERR_H=1 -DHAVE_READPASSPHRASE_H=1 -DHAVE_ASPRINTF=1 -DHAVE_MEMMEM=1 -DHAVE_READPASSPHRASE=1 -DHAVE_STRLCAT=1 -DHAVE_STRLCPY=1 -DHAVE_STRNDUP=1 -DHAVE_STRNLEN=1 -DHAVE_STRSEP=1 -DHAVE_TIMEGM=1 -DHAVE_GETPROGNAME=1 -DHAVE_SYSLOG=1 -DHAVE_POLL=1 -DHAVE_SOCKETPAIR=1 -DHAVE_ARC4RANDOM=1 -DHAVE_ARC4RANDOM_BUF=1 -DHAVE_ARC4RANDOM_UNIFORM=1 -DHAVE_TIMINGSAFE_BCMP=1 -DHAVE_CLOCK_GETTIME=1 -DHAVE_VA_COPY=1 -DHAVE___VA_COPY=1 -DSIZEOF_TIME_T=8 -I. -I../include -I../include/compat -DLIBRESSL_INTERNAL -D__BEGIN_HIDDEN_DECLS= -D__END_HIDDEN_DECLS= -I ../crypto/modes -I ../crypto/asn1 -I ../ssl -I ../tls -I ../apps/openssl -I ../apps/openssl/compat -D_PATH_SSL_CA_FILE=\"../apps/openssl/cert.pem\" -I/Users/kevin/wrt/staging_dir/host/include -D__STRICT_ALIGNMENT -O2 -I/Users/kevin/wrt/staging_dir/host/include -fpic -Wall -std=gnu99 -fno-strict-aliasing -fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-strong -Qunused-arguments -Wno-pointer-sign -MT handshake_table.o -MD -MP -MF $depbase.Tpo -c -o handshake_table.o handshake_table.c &&\ mv -f $depbase.Tpo $depbase.Po make[4]: *** No rule to make target `/Users/kevin/wrt/build_dir/host/libressl-2.9.2/crypto/.libs/libcrypto_la-cpuid-macosx-x86_64.o', needed by `handshake_table'. Stop. make[3]: *** [all-recursive] Error 1 A similar error & clues from https://gitlab.com/ymorin/buildroot/commit/e783d60473944f8b39f1def45d8d6b483a062158 " LibreSSL 2.9.1 now has a test that requires libtls.a, however, when building a shared library only build, the --disable-static flag is passed to libressl, which prevents the building of libtls.a. With libtls.a not being built, the following error occurs: libressl-2.9.1/tls/.libs/libtls.a', needed by 'handshake_table'. Stop. There are three options to fix this: 1) Stick with autotools, and provide a patch that removes building anything in the tests folder. 2) Pass --enable-static to LIBRESSL_CONF_OPTS 3) Change the package type to cmake, as a cmake build does not have this issue." It appears we cannot change to cmake because cmake has a dependency on an ssl library. Take option 1 and do not build the tests. Also take the opportunity to remove man page building as well. Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk> (cherry picked from commit 8d6d227bb653b7cce7092a5a9d55180c3e022848)
* tools: libressl: update to 2.9.2 versionRoman Yeryomin2019-09-041-2/+2
| | | | | | | To keep in sync with OpenSSL 1.1.x branch version options. Signed-off-by: Roman Yeryomin <roman@advem.lv> (cherry picked from commit 3f1e8c01316a5ea0162197cd8eb6dbbabe396176)
* tools/gengetopt: Update to 2.23Daniel Engberg2019-09-044-29/+38
| | | | | | | | | | Update gengetopt to 2.23 Remove 100-dependency_fix.patch, fixed upstream Rework no tests and docs patch Fix typo in copyright section Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> (cherry picked from commit 6fac9077c674e151e86cb02319c76f6d526579c7)
* tools/bison: Update to 3.4.1Daniel Engberg2019-09-043-16/+3
| | | | | | | | Update bison to 3.4.1 Remove 010-intl-stub-compat.patch Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> (cherry picked from commit 9fc03832bc46b13b377cbe2f6d1acca45f1ad002)
* tools/mtd-utils: update to 2.1.1DENG Qingfang2019-08-273-14/+16
| | | | | Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn> (cherry picked from commit 1664d6698169bed1373db70acdf8ad46fa786b2e)
* tools/patch: apply upstream patch for cve-2019-13638Russell Senior2019-08-142-1/+39
| | | | | | | | | | | | | GNU patch through 2.7.6 is vulnerable to OS shell command injection that can be exploited by opening a crafted patch file that contains an ed style diff payload with shell metacharacters. The ed editor does not need to be present on the vulnerable system. This is different from CVE-2018-1000156. https://nvd.nist.gov/vuln/detail/CVE-2019-13638 Signed-off-by: Russell Senior <russell@personaltelco.net> (cherry picked from commit bcfd1d76852974170780dbe368e6194dbb0e123e)
* tools/patch: apply upstream patch for CVE-2019-13636Russell Senior2019-08-012-1/+109
| | | | | | | | | | In GNU patch through 2.7.6, the following of symlinks is mishandled in certain cases other than input files. This affects inp.c and util.c. https://nvd.nist.gov/vuln/detail/CVE-2019-13636 Signed-off-by: Russell Senior <russell@personaltelco.net> (cherry picked from commit 995bcc532943639f3df36dbcaa361f9167f9f4d5)
* tools/ccache: update to 3.7.1Deng Qingfang2019-06-082-3/+3
| | | | | | | | | Update ccache to 3.7.1 Release notes: https://ccache.dev/releasenotes.html#_ccache_3_7_1 Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
* firmware-utils: jcgimage: add support for 4MiB+ imagesDavide Fioravanti2019-05-311-5/+19
| | | | | | | | | | | | | The first version of this script allowed just 4Mb factory images. With this patch is possible to set the maximum size of the payload. For an 8Mb flash, the corresponding maxsize is: 8 * 1024 * 1024 - 5 * 64 * 1024 = 8388608 - 327680 = 8060928 If the -m argument is not set, the default maximum size will be used for backward compatibility. Signed-off-by: Davide Fioravanti <pantanastyle@gmail.com>
* firmware-utils: jcgimage: fix style and compiler warningsDavide Fioravanti2019-05-311-48/+46
| | | | | | Fixed some compilation warnings. Signed-off-by: Davide Fioravanti <pantanastyle@gmail.com>
* Revert "bc: update to 1.07.1"Hans Dedecker2019-05-222-15/+20
| | | | | | | | | This reverts commit 0111b86f1db501d57bfee8a313fe5bebdf8b2ed9 as it breaks on Linux distributions without ed support ./fix-libmath_h: line 1: ed: command not found Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
* bc: update to 1.07.1Deng Qingfang2019-05-222-20/+15
| | | | | | | Update bc to 1.07.1 Use GNU mirror Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
* scons: update to 3.0.5Deng Qingfang2019-05-181-2/+2
| | | | | | Update scons to 3.0.5 Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
* tools/firmware-utils: mktplinkfw2: add Qualcomm layoutsDavide Fioravanti2019-05-181-0/+12
| | | | | | | This commit adds the partition layout used by the TP-Link Archer D50 and probably by the TP-Link Archer D7 to mktplinkfw2. Signed-off-by: Davide Fioravanti <pantanastyle@gmail.com>
* ipq40xx: add factory image for EnGenius ENS620EXTSteve Glennon2019-05-112-28/+178
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Extended mksenaofw to support new "capwap" header structure. This supports flashing from factory 3.0.0, 3.0.1, 3.1.0 and 3.5.5 firmware. Note that the factory image format changes for 3.1 and later firmware, and that the 3.1.0 and 3.5.5 Engenius firmware will refuse the factory_30.bin file. Similarly, the 3.0.0 and 3.0.1 Engenius firmware will refuse the factory_35.bin file. Flashing from the Engenius 3.1.0 firmware with the factory_35.bin firmware has not been tested, as 3.1.0 firmware (Engenius "middleFW") is only intended as part of the upgrade path to 3.5.5 firmware. Modified ipq40xx image Makefile to appropriately invoke mksenaofw with new parameters to configure the capwap header. Note that there is currently no method to return to factory firmware, so this is a one-way street. Path from factory 3.0.0 and 3.0.1 (EnGenius) software to OpenWrt is to navigate to 192.168.1.1 on the stock firmware and navigate to the firmware menu. Then copy the URL you have for that page, something like http://192.168.1.1/cgi-bin/luci/;stok=12345abcdef/admin/system/flashops and replace the trailing /admin/system/flashops with just /easyflashops You should then be presented with a simple "Firmware Upgrade" page. On that page, BE SURE TO CLEAR the "Keep Settings:" checkbox. Choose the openwrt-ipq40xx-engenius_ens620ext-squashfs-factory_30.bin, click "Upgrade" and on the following page select "Proceed". Path from factory 3.5.5 (EnGenius) software to OpenWrt is simply to use the stock firmware update menu. Choose the openwrt-ipq40xx-engenius_ens620ext-squashfs-factory_35.bin and click "Upload" and "Proceed". The device should then flash the OpenWrt firmware and reboot. Note that this resets the device to a default configuration with Wi-Fi disabled, LAN1/PoE acting as a WAN port (running DHCP client) and LAN2 acting as a LAN port with a DHCP server on 192.168.1.x (AP is at 192.168.1.1) Signed-off-by: Steve Glennon <s.glennon@cablelabs.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [sorry, for unfixing the 80-lines eyesores.]
* tools/ccache: update to 3.7Deng Qingfang2019-04-292-5/+4
| | | | | | | | | Update ccache to 3.7 Release notes: https://ccache.dev/releasenotes.html#_ccache_3_7 Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
* tools: cbootimage: depend on automakeTomasz Maciej Nowak2019-04-071-1/+1
| | | | | | | Fix missing aclocal reported by buildbot. Fixes: 8595bb0 ("tools: add cbootimage for tegra") Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
* firmware-utils: fix nec-enc build on older architecturesChristian Lamparter2019-04-061-1/+1
| | | | | | | | | | | | | | | | | | | | This patch enable gnu99 mode for the nec-enc utility which fixes the following build-breaking errors on some older architectures. nec-enc.c: In function ‘xor_data’: nec-enc.c:34:2: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode for (int i = 0; i < len; i++) { ^~~ nec-enc.c:34:2: note: use option -std=c99, -std=gnu99, -std=c11 or -std=gnu11 to compile your code nec-enc.c: In function ‘main’: nec-enc.c:101:3: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode for (int i = 0; i < n; i++) { ^~~ Spotted-By: Buildbot Fixes: fac27643f057 ("firmware-utils: add nec-enc") Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* firmware-utils: add nec-encINAGAKI Hiroshi2019-04-062-0/+130
| | | | | | | | | | | | | | | | | | | | nec-enc provides firmware encoding/decoding with model specific key for NEC devices. known devices: - Aterm WF1200CR - Aterm WG1200CR - Aterm WG2600HS usage: nec-enc -i infile -o outfile -k key Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [checkpatch fixes, marked usage as noreturn, added static function, moved buf* from stack to the global data segment]
* tools/xz: Compile with PIC to fix linking errorsRosen Penev2019-04-061-2/+3
| | | | | | | | | | | I made a similar change to this here: https://github.com/openwrt/packages/pull/8159 However, it turns out this did not fix the problem as the problem has to do with tools/xz and not the xz package. The error is the same and causes linking errors as can be seen above. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* tools: tplink-safeloader: add C7v5 KR SupportMichael Gray2019-04-061-1/+2
| | | | | | The added entry originates from TP-Links latest Archer C7 v5 KR firmware. Signed-off-by: Michael Gray <michael.gray@lantisproject.com>
* tools: add cbootimage-configs for tegraTomasz Maciej Nowak2019-04-062-1/+33
| | | | | | | This provides board configuraion tables for various Tegra boards needed by cbootimage tool to create flashable bootloader images. Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
* tools: add cbootimage for tegraTomasz Maciej Nowak2019-04-062-0/+33
| | | | | | | | | | | | | | | | | Tegra BCT and bootable flash image generator/compiler >From documentation: This project provides a tool which compiles BCT (Boot Configuration Table) images to place into the boot flash of a Tegra-based device. The tool will either: a) Compile a textual representation of a BCT into a binary image. b) Generate an entire boot image from a previously compiled BCT and a bootloader binary. Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
* ath79: Add support for TP-Link CPE210 v3Mario Schroen2019-04-021-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: * SoC: Qualcomm Atheros QCA9533 (650MHz) * RAM: 64MB * Storage: 8 MB SPI NOR * Wireless: 2.4GHz N based built into SoC 2x2 * Ethernet: 1x 100/10 Mbps, integrated into SoC, 24V POE IN Installation: Flash factory image through stock firmware WEB UI or TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Thanks to robimarko for the work inside the ar71xx tree. Thanks to adrianschmutzler for deep discussion and fixes. Signed-off-by: Mario Schroen <m.schroen@web.de> [Split into DTS/DTSI, read-only config partition in DTSI] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> [renamed dtsi filename, light subject touches] Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ar71xx: Use dynamic partitions for TP-Link CPE210 v2Adrian Schmutzler2019-04-021-2/+1
| | | | | | | This is also helpful to add support in ath79. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> Tested-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* tools/ccache: update to 3.6Deng Qingfang2019-03-242-3/+3
| | | | | | Update ccache to 3.6 Signed-off-by: Deng Qingfang <dengqf6@mail2.sysu.edu.cn>
* firmware-utils: mkdlinkfw: add kernel image offsetPawel Dembicki2019-03-241-4/+9
| | | | | | | | Some boards with JBOOT have partiton between bootloader and kernel image. This patch add possibility to change kernel partition start address. Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
* Revert "tools/cmake: Update to 3.14.0"Stijn Tintel2019-03-175-8/+33
| | | | | | | | The cmake bump to 3.14.0 breaks build on all targets. Revert it for now. This reverts commit a3446257a8737bfc2899c5911791873561feecc7. Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>
* tools/libelf: Add mirrors as main site is deadDaniel Engberg2019-03-171-2/+3
| | | | | | Main site hasn't resolved for days so just add a few mirrors instead Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>
* tools/cmake: Update to 3.14.0Daniel Engberg2019-03-165-33/+8
| | | | | | | | | | Update CMake to 3.14.0 Refresh patches Remove inofficial fossies.org and replace with GitHub (link on official site) Remote 150-C-feature-checks-Match-warnings-more-strictly.patch as it's a no longer needed backport from upstream. Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net>