(self)
Preprocesses the command line options before they are passed to
        setup.py and sets up the build configuration.
Preprocesses the command line options before they are passed to
        setup.py and sets up the build configuration.
Preprocesses the command line options before they are passed to setup . py and sets up the build configuration .
def process_args_from_command_line(self):
        """Preprocesses the command line options before they are passed to
        setup.py and sets up the build configuration."""
        # Yes, this is ugly, but we don't want to interfere with setup.py's own
        # option handling
        opts_to_remove = []
        for idx, option in enumerate(sys.argv):
            if not option.startswith("--"):
                continue
            if option == "--static":
                opts_to_remove.append(idx)
                self.static_extension = True
            elif option == "--no-pkg-config":
                opts_to_remove.append(idx)
                self.use_pkgconfig = False
            elif option == "--no-wait":
                opts_to_remove.append(idx)
                self.wait = False
            elif option == "--use-pkg-config":
                opts_to_remove.append(idx)
                self.use_pkgconfig = True

        for idx in reversed(opts_to_remove):
            sys.argv[idx : (idx + 1)] = []
def process_args_from_command_line ( self ) : # Yes, this is ugly, but we don't want to interfere with setup.py's own # option handling opts_to_remove = [ ] for idx , option in enumerate ( sys . argv ) : if not option . startswith ( "--" ) : continue if option == "--static" : opts_to_remove . append ( idx ) self . static_extension = True elif option == "--no-pkg-config" : opts_to_remove . append ( idx ) self . use_pkgconfig = False elif option == "--no-wait" : opts_to_remove . append ( idx ) self . wait = False elif option == "--use-pkg-config" : opts_to_remove . append ( idx ) self . use_pkgconfig = True for idx in reversed ( opts_to_remove ) : sys . argv [ idx : ( idx + 1 ) ] = [ ]