      if stderr:
          out_error("g++ not installed. Please install g++ for your distribution")
          return
      gpp = [re.sub(" +", " ", line.strip())
             for line in stdout.decode().splitlines()
             if line.lower().strip().startswith("g++")][0]
      version = gpp[gpp.rfind(" ") + 1:]
      out_info("g++ version: {}".format(version))
  
  
 
</s> remove            for line in stdout.decode().splitlines()
 </s> add            for line in stdout.decode(ENCODING).splitlines() </s> remove              for line in stdout.decode().splitlines()
 </s> add              for line in stdout.decode(ENCODING).splitlines() </s> remove              for line in stdout.decode().splitlines()
 </s> add              for line in stdout.decode(ENCODING).splitlines() </s> remove     stdout = stdout.decode()
 </s> add     stdout = stdout.decode(ENCODING) </s> remove     installed = chk.communicate()[0].decode().splitlines()
 </s> add     installed = chk.communicate()[0].decode(ENCODING).splitlines()
           for line in stdout.decode(ENCODING).splitlines()
      if stderr:
          out_error("g++ not installed. Please install g++ for your distribution")
          return
      gpp = [re.sub(" +", " ", line.strip())
           for line in stdout.decode(ENCODING).splitlines()
             if line.lower().strip().startswith("g++")][0]
      version = gpp[gpp.rfind(" ") + 1:]
      out_info("g++ version: {}".format(version))
  
  
keep keep keep keep replace keep keep keep keep keep
 setup.py - Get system encoding 
setup.py