(self)
return aliases
If the versioned library name is libfoo.so.0.100.0, aliases are:
        * libfoo.so.0 (soversion) -> libfoo.so.0.100.0
        * libfoo.so (unversioned; for linking) -> libfoo.so.0
        Same for dylib:
        * libfoo.dylib (unversioned; for linking) -> libfoo.0.dylib
If the versioned library name is libfoo.so.0.100.0, aliases are:
        * libfoo.so.0 (soversion) -> libfoo.so.0.100.0
        * libfoo.so (unversioned; for linking) -> libfoo.so.0
        Same for dylib:
        * libfoo.dylib (unversioned; for linking) -> libfoo.0.dylib
If the versioned library name is libfoo . so . 0 . 100 . 0 aliases are : * libfoo . so . 0 ( soversion ) - > libfoo . so . 0 . 100 . 0 * libfoo . so ( unversioned ; for linking ) - > libfoo . so . 0 Same for dylib : * libfoo . dylib ( unversioned ; for linking ) - > libfoo . 0 . dylib
def get_aliases(self) -> T.Dict[str, str]:
        """
        If the versioned library name is libfoo.so.0.100.0, aliases are:
        * libfoo.so.0 (soversion) -> libfoo.so.0.100.0
        * libfoo.so (unversioned; for linking) -> libfoo.so.0
        Same for dylib:
        * libfoo.dylib (unversioned; for linking) -> libfoo.0.dylib
        """
        aliases: T.Dict[str, str] = {}
        # Aliases are only useful with .so and .dylib libraries. Also if
        # there's no self.soversion (no versioning), we don't need aliases.
        if self.suffix not in ('so', 'dylib') or not self.soversion:
            return aliases
        # With .so libraries, the minor and micro versions are also in the
        # filename. If ltversion != soversion we create an soversion alias:
        # libfoo.so.0 -> libfoo.so.0.100.0
        # Where libfoo.so.0.100.0 is the actual library
        if self.suffix == 'so' and self.ltversion and self.ltversion != self.soversion:
            alias_tpl = self.filename_tpl.replace('ltversion', 'soversion')
            ltversion_filename = alias_tpl.format(self)
            aliases[ltversion_filename] = self.filename
        # libfoo.so.0/libfoo.0.dylib is the actual library
        else:
            ltversion_filename = self.filename
        # Unversioned alias:
        #  libfoo.so -> libfoo.so.0
        #  libfoo.dylib -> libfoo.0.dylib
        aliases[self.basic_filename_tpl.format(self)] = ltversion_filename
        return aliases
def get_aliases ( self ) -> T . Dict [ str , str ] : aliases : T . Dict [ str , str ] = { } # Aliases are only useful with .so and .dylib libraries. Also if # there's no self.soversion (no versioning), we don't need aliases. if self . suffix not in ( 'so' , 'dylib' ) or not self . soversion : return aliases # With .so libraries, the minor and micro versions are also in the # filename. If ltversion != soversion we create an soversion alias: # libfoo.so.0 -> libfoo.so.0.100.0 # Where libfoo.so.0.100.0 is the actual library if self . suffix == 'so' and self . ltversion and self . ltversion != self . soversion : alias_tpl = self . filename_tpl . replace ( 'ltversion' , 'soversion' ) ltversion_filename = alias_tpl . format ( self ) aliases [ ltversion_filename ] = self . filename # libfoo.so.0/libfoo.0.dylib is the actual library else : ltversion_filename = self . filename # Unversioned alias: #  libfoo.so -> libfoo.so.0 #  libfoo.dylib -> libfoo.0.dylib aliases [ self . basic_filename_tpl . format ( self ) ] = ltversion_filename return aliases