code: def _lib(self, name, only_if_have=False):
          
          emit = True
          if only_if_have:
              emit = self.env.get('HAVE_LIB' + self.env_key(name))
          if emit:
              return '-l' + name
          return ''
docs: Specify a linker library.
  
          Example:
  
              LDFLAGS={{ lib("rt") }} {{ lib("pthread", True) }}
  
          Will unconditionally add `-lrt` and check the environment if the key
          `HAVE_LIBPTHREAD` is set to be true, then add `-lpthread`.