User:Bugman/subsystems: Difference between revisions

Jump to navigation Jump to search
→‎Script: Bug fixes.
(→‎Script: Newest version of the script.)
(→‎Script: Bug fixes.)
Line 140: Line 140:
                 # The probable implementation file name.
                 # The probable implementation file name.
                 file_name = subsystem.declaration_file[:-3] + "cxx"
                 file_name = subsystem.declaration_file[:-3] + "cxx"
                 full_path = file_name
                 full_path = path + sep + file_name
                if not subsystem.root_path:
                    full_path = path + sep + file_name
                 if access(full_path, F_OK):
                 if access(full_path, F_OK):
                     # The Unix grep commands to run.
                     # The Unix grep commands to run.
Line 155: Line 153:
                         lines = pipe.stdout.readlines()
                         lines = pipe.stdout.readlines()
                         if len(lines):
                         if len(lines):
                             if self.output_full_path:
                             subsystem.add_implementation_file(file_name)
                                subsystem.add_implementation_file(full_path)
                            else:
                                subsystem.add_implementation_file(file_name)
                             break
                             break


Line 191: Line 186:
                     # Store the implementation file.
                     # Store the implementation file.
                     elif len(files):
                     elif len(files):
                         file_name = files[0]
                         subsystem.add_implementation_file(files[0])
                        if subsystem.root_path:
                            file_name = subsystem.root_path + sep + file_name
                        subsystem.add_implementation_file(file_name)
                         break
                         break


Navigation menu