Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(980)

Side by Side Diff: pym/_emerge/main.py

Issue 6905107: Rebuild when build-time/run-time deps are upgraded. (Closed) Base URL: git://git.overlays.gentoo.org/proj/portage.git@master
Patch Set: Address review feedback, add tests. Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « pym/_emerge/depgraph.py ('k') | pym/_emerge/resolver/backtracking.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 1999-2011 Gentoo Foundation 1 # Copyright 1999-2011 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2 2 # Distributed under the terms of the GNU General Public License v2
3 3
4 from __future__ import print_function 4 from __future__ import print_function
5 5
6 import logging 6 import logging
7 import signal 7 import signal
8 import stat 8 import stat
9 import sys 9 import sys
10 import textwrap 10 import textwrap
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 '--deselect' : y_or_n, 431 '--deselect' : y_or_n,
432 '--binpkg-respect-use' : y_or_n, 432 '--binpkg-respect-use' : y_or_n,
433 '--fail-clean' : y_or_n, 433 '--fail-clean' : y_or_n,
434 '--getbinpkg' : y_or_n, 434 '--getbinpkg' : y_or_n,
435 '--getbinpkgonly' : y_or_n, 435 '--getbinpkgonly' : y_or_n,
436 '--jobs' : valid_integers, 436 '--jobs' : valid_integers,
437 '--keep-going' : y_or_n, 437 '--keep-going' : y_or_n,
438 '--package-moves' : y_or_n, 438 '--package-moves' : y_or_n,
439 '--quiet' : y_or_n, 439 '--quiet' : y_or_n,
440 '--quiet-build' : y_or_n, 440 '--quiet-build' : y_or_n,
441 '--rebuild' : y_or_n,
441 '--rebuilt-binaries' : y_or_n, 442 '--rebuilt-binaries' : y_or_n,
442 '--root-deps' : ('rdeps',), 443 '--root-deps' : ('rdeps',),
443 '--select' : y_or_n, 444 '--select' : y_or_n,
444 '--selective' : y_or_n, 445 '--selective' : y_or_n,
445 "--use-ebuild-visibility": y_or_n, 446 "--use-ebuild-visibility": y_or_n,
446 '--usepkg' : y_or_n, 447 '--usepkg' : y_or_n,
447 '--usepkgonly' : y_or_n, 448 '--usepkgonly' : y_or_n,
448 } 449 }
449 450
450 if _ENABLE_DYN_LINK_MAP: 451 if _ENABLE_DYN_LINK_MAP:
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
732 "choices" : true_y_or_n 733 "choices" : true_y_or_n
733 }, 734 },
734 735
735 "--nousepkg-atoms": { 736 "--nousepkg-atoms": {
736 "help" :"A space separated list of package names or sl ot atoms. " + \ 737 "help" :"A space separated list of package names or sl ot atoms. " + \
737 "Emerge will ignore matching binary packages. ", 738 "Emerge will ignore matching binary packages. ",
738 739
739 "action" : "append", 740 "action" : "append",
740 }, 741 },
741 742
743 "--norebuild-atoms": {
744 "help" :"A space separated list of package names or sl ot atoms. " + \
745 "Emerge will not rebuild these packages due to t he " + \
746 "--rebuild flag. ",
747
748 "action" : "append",
749 },
750
742 "--package-moves": { 751 "--package-moves": {
743 "help" : "perform package moves when necessary", 752 "help" : "perform package moves when necessary",
744 "type" : "choice", 753 "type" : "choice",
745 "choices" : true_y_or_n 754 "choices" : true_y_or_n
746 }, 755 },
747 756
748 "--quiet": { 757 "--quiet": {
749 "shortopt" : "-q", 758 "shortopt" : "-q",
750 "help" : "reduced or condensed output", 759 "help" : "reduced or condensed output",
751 "type" : "choice", 760 "type" : "choice",
752 "choices" : true_y_or_n 761 "choices" : true_y_or_n
753 }, 762 },
754 763
755 "--quiet-build": { 764 "--quiet-build": {
756 "help" : "redirect build output to logs", 765 "help" : "redirect build output to logs",
757 "type" : "choice", 766 "type" : "choice",
758 "choices" : true_y_or_n 767 "choices" : true_y_or_n
759 }, 768 },
760 769
770 "--rebuild": {
771 "help" : "Rebuild packages when dependencies that ar e " + \
772 "used at both build-time and run-time are upgrad ed.",
773 "type" : "choice",
774 "choices" : true_y_or_n
775 },
776
761 "--rebuilt-binaries": { 777 "--rebuilt-binaries": {
762 "help" : "replace installed packages with binary " + \ 778 "help" : "replace installed packages with binary " + \
763 "packages that have been rebuilt", 779 "packages that have been rebuilt",
764 "type" : "choice", 780 "type" : "choice",
765 "choices" : true_y_or_n 781 "choices" : true_y_or_n
766 }, 782 },
767 783
768 "--rebuilt-binaries-timestamp": { 784 "--rebuilt-binaries-timestamp": {
769 "help" : "use only binaries that are newer than this " + \ 785 "help" : "use only binaries that are newer than this " + \
770 "timestamp for --rebuilt-binaries", 786 "timestamp for --rebuilt-binaries",
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
880 myoptions.changed_use = False 896 myoptions.changed_use = False
881 897
882 if myoptions.deselect in true_y: 898 if myoptions.deselect in true_y:
883 myoptions.deselect = True 899 myoptions.deselect = True
884 900
885 if myoptions.binpkg_respect_use in true_y: 901 if myoptions.binpkg_respect_use in true_y:
886 myoptions.binpkg_respect_use = True 902 myoptions.binpkg_respect_use = True
887 else: 903 else:
888 myoptions.binpkg_respect_use = None 904 myoptions.binpkg_respect_use = None
889 905
890 » if myoptions.complete_graph in true_y: 906 » if myoptions.complete_graph in true_y or myoptions.rebuild in true_y:
891 myoptions.complete_graph = True 907 myoptions.complete_graph = True
892 else: 908 else:
893 myoptions.complete_graph = None 909 myoptions.complete_graph = None
894 910
895 if _ENABLE_DYN_LINK_MAP: 911 if _ENABLE_DYN_LINK_MAP:
896 if myoptions.depclean_lib_check in true_y: 912 if myoptions.depclean_lib_check in true_y:
897 myoptions.depclean_lib_check = True 913 myoptions.depclean_lib_check = True
898 914
899 if myoptions.exclude: 915 if myoptions.exclude:
900 bad_atoms = _find_bad_atoms(myoptions.exclude) 916 bad_atoms = _find_bad_atoms(myoptions.exclude)
901 if bad_atoms and not silent: 917 if bad_atoms and not silent:
902 parser.error("Invalid Atom(s) in --exclude parameter: '% s' (only package names and slot atoms (with wildcards) allowed)\n" % \ 918 parser.error("Invalid Atom(s) in --exclude parameter: '% s' (only package names and slot atoms (with wildcards) allowed)\n" % \
903 (",".join(bad_atoms),)) 919 (",".join(bad_atoms),))
904 920
905 if myoptions.reinstall_atoms: 921 if myoptions.reinstall_atoms:
906 bad_atoms = _find_bad_atoms(myoptions.reinstall_atoms) 922 bad_atoms = _find_bad_atoms(myoptions.reinstall_atoms)
907 if bad_atoms and not silent: 923 if bad_atoms and not silent:
908 parser.error("Invalid Atom(s) in --reinstall-atoms param eter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \ 924 parser.error("Invalid Atom(s) in --reinstall-atoms param eter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \
909 (",".join(bad_atoms),)) 925 (",".join(bad_atoms),))
910 926
927 if myoptions.norebuild_atoms:
928 bad_atoms = _find_bad_atoms(myoptions.norebuild_atoms)
929 if bad_atoms and not silent:
930 parser.error("Invalid Atom(s) in --norebuild-atoms param eter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \
931 (",".join(bad_atoms),))
932
911 if myoptions.nousepkg_atoms: 933 if myoptions.nousepkg_atoms:
912 bad_atoms = _find_bad_atoms(myoptions.nousepkg_atoms) 934 bad_atoms = _find_bad_atoms(myoptions.nousepkg_atoms)
913 if bad_atoms and not silent: 935 if bad_atoms and not silent:
914 parser.error("Invalid Atom(s) in --nousepkg-atoms parame ter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \ 936 parser.error("Invalid Atom(s) in --nousepkg-atoms parame ter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \
915 (",".join(bad_atoms),)) 937 (",".join(bad_atoms),))
916 938
917 if myoptions.useoldpkg_atoms: 939 if myoptions.useoldpkg_atoms:
918 bad_atoms = _find_bad_atoms(myoptions.useoldpkg_atoms) 940 bad_atoms = _find_bad_atoms(myoptions.useoldpkg_atoms)
919 if bad_atoms and not silent: 941 if bad_atoms and not silent:
920 parser.error("Invalid Atom(s) in --useoldpkg-atoms param eter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \ 942 parser.error("Invalid Atom(s) in --useoldpkg-atoms param eter: '%s' (only package names and slot atoms (with wildcards) allowed)\n" % \
(...skipping 893 matching lines...) Expand 10 before | Expand all | Expand 10 after
1814 return 1 1836 return 1
1815 1837
1816 if "--pretend" not in myopts: 1838 if "--pretend" not in myopts:
1817 display_news_notification(root_config, myopts) 1839 display_news_notification(root_config, myopts)
1818 retval = action_build(settings, trees, mtimedb, 1840 retval = action_build(settings, trees, mtimedb,
1819 myopts, myaction, myfiles, spinner) 1841 myopts, myaction, myfiles, spinner)
1820 post_emerge(myaction, myopts, myfiles, settings["ROOT"], 1842 post_emerge(myaction, myopts, myfiles, settings["ROOT"],
1821 trees, mtimedb, retval) 1843 trees, mtimedb, retval)
1822 1844
1823 return retval 1845 return retval
OLDNEW
« no previous file with comments | « pym/_emerge/depgraph.py ('k') | pym/_emerge/resolver/backtracking.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698