salt.modules.makeconf

Support for modifying make.conf under Gentoo

salt.modules.makeconf.append_cflags(value)

Add to or create a new CFLAGS in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_cflags '-pipe'
salt.modules.makeconf.append_cxxflags(value)

Add to or create a new CXXFLAGS in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_cxxflags '-pipe'
salt.modules.makeconf.append_emerge_default_opts(value)

Add to or create a new EMERGE_DEFAULT_OPTS in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_emerge_default_opts '--jobs'
salt.modules.makeconf.append_features(value)

Add to or create a new FEATURES in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_features 'webrsync-gpg'
salt.modules.makeconf.append_gentoo_mirrors(value)

Add to or create a new GENTOO_MIRRORS in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_gentoo_mirrors 'http://distfiles.gentoo.org'
salt.modules.makeconf.append_makeopts(value)

Add to or create a new MAKEOPTS in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_makeopts '-j3'
salt.modules.makeconf.append_var(var, value)

Add to or create a new variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.append_var 'LINGUAS' 'en'
salt.modules.makeconf.cflags_contains(value)

Verify if CFLAGS variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.cflags_contains '-pipe'
salt.modules.makeconf.chost_contains(value)

Verify if CHOST variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.chost_contains 'x86_64-pc-linux-gnu'
salt.modules.makeconf.cxxflags_contains(value)

Verify if CXXFLAGS variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.cxxflags_contains '-pipe'
salt.modules.makeconf.emerge_default_opts_contains(value)

Verify if EMERGE_DEFAULT_OPTS variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.emerge_default_opts_contains '--jobs'
salt.modules.makeconf.features_contains(value)

Verify if FEATURES variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.features_contains 'webrsync-gpg'
salt.modules.makeconf.gentoo_mirrors_contains(value)

Verify if GENTOO_MIRRORS variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.gentoo_mirrors_contains 'http://distfiles.gentoo.org'
salt.modules.makeconf.get_cflags()

Get the value of CFLAGS variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_cflags
salt.modules.makeconf.get_chost()

Get the value of CHOST variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_chost
salt.modules.makeconf.get_cxxflags()

Get the value of CXXFLAGS variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_cxxflags
salt.modules.makeconf.get_emerge_default_opts()

Get the value of EMERGE_DEFAULT_OPTS variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_emerge_default_opts
salt.modules.makeconf.get_features()

Get the value of FEATURES variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_features
salt.modules.makeconf.get_gentoo_mirrors()

Get the value of GENTOO_MIRRORS variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_gentoo_mirrors
salt.modules.makeconf.get_makeopts()

Get the value of MAKEOPTS variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_makeopts
salt.modules.makeconf.get_sync()

Get the value of SYNC variable in the make.conf

Return the value of the variable or None if the variable is not in the make.conf

CLI 范例:

salt '*' makeconf.get_sync
salt.modules.makeconf.get_var(var)

Get the value of a variable in make.conf

Return the value of the variable or None if the variable is not in make.conf

CLI 范例:

salt '*' makeconf.get_var 'LINGUAS'
salt.modules.makeconf.makeopts_contains(value)

Verify if MAKEOPTS variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.makeopts_contains '-j3'
salt.modules.makeconf.remove_var(var)

Remove a variable from the make.conf

Return a dict containing the new value for the variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.remove_var 'LINGUAS'
salt.modules.makeconf.set_cflags(value)

Set the CFLAGS variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_cflags '-march=native -O2 -pipe'
salt.modules.makeconf.set_chost(value)

Set the CHOST variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_chost 'x86_64-pc-linux-gnu'
salt.modules.makeconf.set_cxxflags(value)

Set the CXXFLAGS variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_cxxflags '-march=native -O2 -pipe'
salt.modules.makeconf.set_emerge_default_opts(value)

Set the EMERGE_DEFAULT_OPTS variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_emerge_default_opts '--jobs'
salt.modules.makeconf.set_gentoo_mirrors(value)

Set the GENTOO_MIRRORS variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_gentoo_mirrors 'http://distfiles.gentoo.org'
salt.modules.makeconf.set_makeopts(value)

Set the MAKEOPTS variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_makeopts '-j3'
salt.modules.makeconf.set_sync(value)

Set the SYNC variable

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_sync 'rsync://rsync.namerica.gentoo.org/gentoo-portage'
salt.modules.makeconf.set_var(var, value)

Set a variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.set_var 'LINGUAS' 'en'
salt.modules.makeconf.sync_contains(value)

Verify if SYNC variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.sync_contains 'rsync://rsync.namerica.gentoo.org/gentoo-portage'
salt.modules.makeconf.trim_cflags(value)

Remove a value from CFLAGS variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_cflags '-pipe'
salt.modules.makeconf.trim_cxxflags(value)

Remove a value from CXXFLAGS variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_cxxflags '-pipe'
salt.modules.makeconf.trim_emerge_default_opts(value)

Remove a value from EMERGE_DEFAULT_OPTS variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_emerge_default_opts '--jobs'
salt.modules.makeconf.trim_features(value)

Remove a value from FEATURES variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_features 'webrsync-gpg'
salt.modules.makeconf.trim_gentoo_mirrors(value)

Remove a value from GENTOO_MIRRORS variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_gentoo_mirrors 'http://distfiles.gentoo.org'
salt.modules.makeconf.trim_makeopts(value)

Remove a value from MAKEOPTS variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_makeopts '-j3'
salt.modules.makeconf.trim_var(var, value)

Remove a value from a variable in the make.conf

Return a dict containing the new value for variable:

{'<variable>': {'old': '<old-value>',
                'new': '<new-value>'}}

CLI 范例:

salt '*' makeconf.trim_var 'LINGUAS' 'en'
salt.modules.makeconf.var_contains(var, value)

Verify if variable contains a value in make.conf

Return True if value is set for var

CLI 范例:

salt '*' makeconf.var_contains 'LINGUAS' 'en'