aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/feeds
Commit message (Collapse)AuthorAgeFilesLines
* feeds: use git-src-full to allow Git versioningPaul Spooren2022-08-281-2/+2
| | | | | | | | | | | | | | | | Both $(AUTORELEASE) and $(PKG_SRC_VERSION) (from luci.git) use the Git log to determine releases and package timestamps. Feeds are shallow cloned by default, resulting in an incomplete Git log and therefore different local package versions than offered upstream. This commits sets the default feeds to use `src-git-full` to solve that. Add fixes from "2b1d92f: scripts/feeds: silence git warning by selecting pull style" to `src-git-full` Signed-off-by: Paul Spooren <mail@aparcar.org> (cherry picked from commit 7fae1e5677e9bb4979c8d4ac99be4de6955b13d0)
* scripts/feed: no warn on toolchain/linux overwritePaul Spooren2021-01-061-1/+3
| | | | | | | | | | | The recent 7f285d "scripts/feeds: warn when skipping core package override" floods SDK output with warning of overwriting "linux" and "toolchain" core packages. This should be ignored as these are not regular packages added via feeds. While at it slightly improve the warning string. Signed-off-by: Paul Spooren <mail@aparcar.org>
* scripts/feeds: fix preference of package installKarel Kočí2020-12-091-16/+14
| | | | | | | | | | | | | | The previous behavior prefered same feed for dependent packages as initial package. This caused inconsitency in installation of packages. The difference was if two feeds provide same package (different version) there was different result if you executed install for that specific version compared to install for package depending on it from different feed. This ensures that preferred feed is propagated without change and selected feed is used only really for package it was selected for. Signed-off-by: Karel Kočí <karel.koci@nic.cz>
* scripts/feeds: warn when skipping core package overrideBrian Norris2020-12-091-1/+4
| | | | | | | | | | Otherwise, a n00b like myself can get quite confused when moving a package from core to feeds, for example. (Hint: one *really* needs to clear out the tmp/info/.packageinfo... entries for the stale package, but '-f' works as well.) Signed-off-by: Brian Norris <computersforpeace@gmail.com>
* scripts/feeds: silence git warning by selecting pull styleHannu Nyman2020-11-261-2/+2
| | | | | | | Silence the warning in git 2.27 about undefined fast-forward style in git pull. Define "ff-only" as the style. Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
* scripts/feeds: fix accepting "-" in feed type stringFelix Fietkau2019-09-151-1/+1
| | | | | | Fixes a syntax error in processing the type src-git-full Signed-off-by: Felix Fietkau <nbd@nbd.name>
* scripts/feeds: fix 'src-include' directiveBjørn Mork2019-09-021-1/+1
| | | | | | | | | | | | Commit 775b70f8d5df renamed parse_file() parameters without updating the recursive call. This broke parsing of any feeds.conf using 'src-include'. $ scripts/feeds update -a Can't use string ("defaults") as a HASH ref while "strict refs" in use at scripts/feeds line 63, <$fh> line 1. Fixes: 775b70f8d5df ("scripts/feeds: allow adding parameters to feeds") Signed-off-by: Bjørn Mork <bjorn@mork.no>
* scripts/feeds: allow adding parameters to feedsJo-Philipp Wich2019-08-281-18/+30
| | | | | | | | | this allows adding "--" prefixed parameters inside feeds.conf between the target and name. The first parameter is --force which has the same effect as using -f when installing any of the packages. This allows creating feeds that will override base packages by default. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* scripts/feeds: add src-include methodBjørn Mork2019-07-011-11/+26
| | | | | | | | | | | | The src-include method allows recursive inclusion of feeds.conf snippets. This can for example be used for adding static local feeds to feeds.conf.default without ever having to update the local feeds.conf: src-include defaults feeds.conf.default src-link custom /usr/local/src/lede/custom Signed-off-by: Bjørn Mork <bjorn@mork.no>
* include/feeds.mk: rework generation of opkg distfeeds.confMatthias Schiffer2018-07-121-2/+3
| | | | | | | Allow enabling/commenting/disabling each feed individually by using a tristate config symbol. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* scripts/feeds: add src-dummy methodMatthias Schiffer2018-07-121-1/+6
| | | | | | | | | The src-dummy method does not actually obtain any feed, but it can be used to insert addtional entries into the opkg distfeeds.conf. This is useful to make package feeds available to users without requiring the corresponding source feeds to be available during build. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* build: fix target metadata scan dependenciesFelix Fietkau2018-07-021-2/+2
| | | | | | | Move SCAN_DEPS to scan.mk to eliminate redundancy with scripts/feeds Add image/*.mk to SCAN_DEPS for targets to pick up newly added devices Signed-off-by: Felix Fietkau <nbd@nbd.name>
* scripts/feeds: add support for git feeds with submodulesFelix Fietkau2018-04-271-0/+6
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* scripts/feeds: fix install of packages with different source/binary namesMatthias Schiffer2018-01-141-1/+1
| | | | | | | | The logic for choice between source and binary packages was reversed. Fixes: 52719c2b67af "metadata: scripts/feeds: distinguish between source and binary packages, resolve virtual dependencies" Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: scripts/feeds: distinguish between source and binary packages, ↵Matthias Schiffer2018-01-131-70/+110
| | | | | | | | | | resolve virtual dependencies Properly resolve build depends to source packages and runtime depends to binary packages. Dependencies on virtual packages are resolved to the first provider now. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: always resolve dependencies through provides listMatthias Schiffer2018-01-131-3/+1
| | | | | | | | | | | Instead of adding virtual packages to the normal package list, keep a separate list for provides, make each package provide itself, and resolve all dependencies through this list. This allows to use PROVIDES to replace existing packages. Fixes FS#837. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: remove redundant fields from package hashMatthias Schiffer2018-01-131-1/+5
| | | | Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: change pkg->{src} field to hold a referenceMatthias Schiffer2018-01-131-2/+2
| | | | | | | | We often want to access fields of a source packages through pkg->{src}. Allow accessing them directly instead of resolving the source hash through srcpackages. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: move 'builddepends' from binary to source packagesMatthias Schiffer2018-01-131-9/+11
| | | | Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: make srcpackage extensibleMatthias Schiffer2018-01-131-1/+1
| | | | | | | Turn the srcpackage values into hashes to allow storing more information than just binary package names. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* scripts/feeds: Reuse TOPDIR if defined in environmentMichal Sojka2017-02-211-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The feeds script sets value of TOPDIR in a way that is inconsistent with how toplevel Makefile sets it. The inconsistency manifests when I use a "build directory" with symlinks to LEDE source (see below). When make is invoked in such a directory, make's TOPDIR variable is set to that directory, whereas scripts/feeds sets TOPDIR to the top of LEDE source, which results in creating feeds directory inside the LEDE source instead of in the build directory. This patch changes the script so that it reuses the TOPDIR value form the environment if it exists. The result is that 'make package/symlinks' correctly fetches feeds to the build directory instead in the source. I use the following commands to create the build directory: ln -s $SRC/config config ln -s $SRC/Config.in Config.in ln -s $SRC/feeds.conf.default feeds.conf.default ln -s $SRC/include include ln -s $SRC/Makefile Makefile mkdir package ln -s $SRC/package/base-files package/base-files ln -s $SRC/package/boot package/boot ln -s $SRC/package/devel package/devel ln -s $SRC/package/firmware package/firmware ln -s $SRC/package/kernel package/kernel ln -s $SRC/package/libs package/libs ln -s $SRC/package/Makefile package/Makefile ln -s $SRC/package/network package/network ln -s $SRC/package/system package/system ln -s $SRC/package/utils package/utils ln -s $SRC/rules.mk rules.mk ln -s $SRC/scripts scripts ln -s $SRC/target target ln -s $SRC/toolchain toolchain ln -s $SRC/tools tools This allows me to easily test changes in LEDE on multiple targets. Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
* feeds: add option to force feed update despite modified filesJo-Philipp Wich2017-02-151-9/+26
| | | | | | | | Implement a new flag "-f" for the feeds update command which causes the script to fall back to a more agressive git update strategy in case there are locally modified files in the feeds directory. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* scripts/feeds: use git rev-parse for getting revisionRafał Miłecki2016-11-081-3/+3
| | | | | | It provides simpler output so we don't need extra head and cut commands. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* scripts/feeds: display "X" as revision of uninitialized feedsRafał Miłecki2016-11-081-1/+1
| | | | | | | | So far we were displaying "local" which could be misinterpreted. It wasn't possible e.g. to say if src-link feed was initialized or not. Hopefully "X" makes (a bit) more sense. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* scripts/feeds: use 10 chars for feed name column widthRafał Miłecki2016-11-031-1/+1
| | | | | | | | It's always hard to find a reasonable width that will make everyone happy. This one at least makes "telephony" (one of default feeds) name fit the column and hopefully isn't too big. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* scripts/feeds: Prevent .config autocreationDaniel Dickinson2016-07-051-0/+5
| | | | | | | | | | | | | When using scripts/feeds upgrade the .config needs to be updated but the code to do so was also autocreating a .config if one didn't exist. This is counter-productive when you have not yet used menuconfig (or other config targets) because things like selecting or deselecting CONFIG_ALL (to build all package by default) only works if the package selection has not already been done via an existing .config selection. Signed-off-by: Daniel Dickinson <lede@daniel.thecshore.com>
* scripts: feeds: fix version detection for Make >= 4.2.1Jo-Philipp Wich2016-06-151-1/+4
| | | | Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* scripts: avoid hard-coded paths in scriptsIblis Lin2016-04-281-1/+1
| | | | Signed-off-by: Iblis Lin <e196819@hotmail.com>
* scripts/feeds: allow export of feeds with static revisionsJonas Gorski2015-08-231-1/+10
| | | | | | | | | | | | Add a switch to scripts/feeds that allows listing the feeds with their currently checked out revisions in feeds.conf compatible format. This allows providing a feeds.conf for public builds to make replication of the build easier. Signed-off-by: Jonas Gorski <jogo@openwrt.org> SVN-Revision: 46706
* scripts/feeds: return error status from feed updateJo-Philipp Wich2015-07-141-4/+4
| | | | | | | | | | | | | | | | This patch is a modified version of the patch being discussed at here: https://patchwork.ozlabs.org/patch/471303/ from Martin Strbacka <martin.strbacka@nic.cz> My version modifies scripts/feeds so that an error with one of the feeds just raises the error flag, but script continues and tries to update the other feeds. After all feeds have been updated, the script returns 1 if at least one feed failed, and 0 on success with all feeds. The user can then utilise the status in his build script, if he wants. signed-off-by: Hannu Nyman <hannu.nyman@iki.fi> SVN-Revision: 46374
* scripts/feeds: print the source of packages installedSteven Barth2015-07-071-2/+2
| | | | | | | | | Can be helpful in diagnosing unexpected package overlaps between feeds/core. Signed-off-by: Karl Palsson <karlp@remake.is> SVN-Revision: 46255
* scripts/feeds: observe -p flag for preferential feedsSteven Barth2015-06-241-3/+3
| | | | | | | | | | | lookup_target was trampling the $feed variable, resulting in the -p flag no longer preferentially installing from the named feed. Make sure to use a local variable for this instead. Signed-off-by: Karl Palsson <karlp@remake.is> SVN-Revision: 46120
* scripts/feeds: fix typo in copied codeFelix Fietkau2015-05-271-1/+1
| | | | | | | | | do_install_target copied code from do_install_package, but didn't replace all text. Signed-off-by: Karl Palsson <karlp@remake.is> SVN-Revision: 45784
* scripts/feeds: Delete package/feeds folder in the clean procedure to prevent ↵John Crispin2015-05-231-1/+1
| | | | | | | | | | | | | | | | | dangling links. Hello, if you run: ./scripts/feeds clean It removes ./feeds folder but not ./package/feeds/ which is full of dangling links then. This patch fixes it. Best Regards, Martin Strbačka Signed-off-by: Martin Strbacka <martin.strbacka@nic.cz> SVN-Revision: 45738
* scripts/feeds: add support for optionally using a full clone of git repositoriesFelix Fietkau2015-05-101-1/+8
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 45668
* scripts/feeds: add support for uninstalling targetsFelix Fietkau2015-03-151-0/+22
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44782
* scripts/feeds: add support for installing targetsFelix Fietkau2015-03-151-0/+57
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44781
* scripts/feeds: get rid of redundant feed cache copyFelix Fietkau2015-03-151-8/+6
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44779
* scripts/feeds: remove useless install_method abstractionFelix Fietkau2015-03-151-18/+2
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44778
* scripts/feeds: add support for searching for targetsFelix Fietkau2015-03-151-1/+44
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44777
* scripts/feeds: scan for target metadataFelix Fietkau2015-03-151-0/+2
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44775
* scripts/feeds: remove a few trailing tabsFelix Fietkau2015-03-151-2/+2
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 44773
* build: allow openwrt.git packages to be replaced by feedsJohn Crispin2015-02-091-8/+22
| | | | | | | | | | | | | | | | | | | | | Currently, replacing a package available in openwrt.git requires modifications in openwrt.git, or requires duplicating the package in a feed but with a different name, which causes all kind of problems related to dependencies (all packages selecting it would have to be modified accordingly to select the new package). With this change, if a package with the same name is present both in feeds/ and package/ folders, the one in feeds/ can override the one in package/, both in the menuconfig and during the build, by passing the "-f" option to "./scripts/feeds install" This mechanism is particularly useful for vendor tree, or in general for application which needs to replace one particular package which exists within openwrt.git by a custom/newer version. Signed-off-by: Mathieu Olivari <mathieu@qca.qualcomm.com> SVN-Revision: 44334
* build: revert r44076John Crispin2015-01-221-18/+7
| | | | | | | | the patch causes issues when installing feeds Signed-off-by: John Crispin <blogic@openwrt.org> SVN-Revision: 44078
* build: allow openwrt.git packages to be replaced by feedsJohn Crispin2015-01-221-7/+18
| | | | | | | | | | | | | | | | | | | | | Currently, replacing a package available in openwrt.git requires modifications in openwrt.git, or requires duplicating the package in a feed but with a different name, which causes all kind of problems related to dependencies (all packages selecting it would have to be modified accordingly to select the new package). With this change, if a package with the same name is present both in feeds/ and package/ folders, the one in feeds/ can override the one in package/, both in the menuconfig and during the build, by passing the "-f" option to "./scripts/feeds install" This mechanism is particularly useful for vendor tree, or in general for application which needs to replace one particular package which exists within openwrt.git by a custom/newer version. Signed-off-by: Mathieu Olivari <mathieu@qca.qualcomm.com> SVN-Revision: 44076
* scripts/feeds: handle missing/broken feeds betterJohn Crispin2014-10-131-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | pts/feeds update -a" can fail rather silently for feeds using git, as the script does not pause when updating a feed fails. Instead it prints the error message and calmly continues to the next feed. It is very easy to overlook update errors with the feeds updated first, as their text scrolls rapidly away from the screen. This behaviour has not been a big problem with svn feeds, as svn update stops with a conflict message and interactively forces the user to resolve or postpone the conflict. In any case the svn error is noticed by the user. Majority of the feeds use now git, so this silent failure can affect users doing private builds in an increasing amount. Below is an example of update failing and script continuing: perus@v1404:/Openwrt/barrier$ ./scripts/feeds update -a Updating feed 'packages' from 'https://github.com/openwrt/packages.git;for-14.07' ... remote: Counting objects: 17, done. remote: Compressing objects: 100% (15/15), done. remote: Total 17 (delta 10), reused 8 (delta 1) Unpacking objects: 100% (17/17), done. From https://github.com/openwrt/packages 62031da..dc26009 for-14.07 -> origin/for-14.07 Updating 62031da..dc26009 error: Your local changes to the following files would be overwritten by merge: utils/collectd/Makefile Please, commit your changes or stash them before you can merge. Aborting failed. Updating feed 'luci' from 'http://git.openwrt.org/project/luci.git;luci-0.12' ... Already up-to-date. Create index file './feeds/luci.index' Updating feed 'routing' from 'https://github.com/openwrt-routing/packages.git;for-14.07' ... ... The script prints "failed.", but does not break the updating process. The "update_feed" function returns an error code 1, but that value is not checked in the "update" function, which continues to the next feed. Return 1 as error: ​https://dev.openwrt.org/browser/trunk/scripts/feeds#L547 Call to update_feed without any error monitoring: ​https://dev.openwrt.org/browser/trunk/scripts/feeds#L585 The included patch makes the feeds script to stop updating after failing to update a feed. The script continues to the refresh_config step despite a possible failure in updating, so the stopping action just prevents the other feeds from updating and makes the error more clearly visible. Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi> SVN-Revision: 42891
* build: introduce per feed repository supportJo-Philipp Wich2014-08-051-1/+25
| | | | | | | | | This changeset implements a new menuconfig option to generate separate repositories for each enabled package feed instead of one monolithic one. Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 42002
* scripts: unset GREP_OPTIONS in env and feeds (fixes #16924)Felix Fietkau2014-06-301-0/+1
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 41407
* feeds: enable cloning of specific git commitLuka Perkov2013-09-251-2/+8
| | | | | | | | | | Following syntax should be used to enable this feature: src-git custom git://openwrt/custom-feed^SHA_COMMIT_ID Signed-off-by: Luka Perkov <luka@openwrt.org> SVN-Revision: 38172
* scripts/feeds: ensure that --ff is enabledFlorian Fainelli2013-09-021-1/+1
| | | | | | | | | | | Users may have merge.ff set to false, which will force merge commits to be generated. The intent here is to have a fast-forward merge when possible, so let's make sure fast-forwards are enabled. Signed-off-by: John Szakmeister <john@szakmeister.net> Signed-off-by: Florian Fainelli <florian@openwrt.org> SVN-Revision: 37884