• ijones's avatar
    fixes to parser from krasimir, fixes to sdist from ross · 0b3d4691
    ijones authored
    Krasimir says:
      Small fixes in the parser/printer. When there is a package description with
      executables only then the old implementation of pretty printer was written
      to print empty "exposed-modules" field while there isn`t any library. After
      that the parser will generate PackageDescription with (Just emptyLibrary)
      instead of Nothing. Now exposed-modules field is printed only if
      library /= Nothing
    
    Ross says:
      In smartCopySources, don't try to strip the prefix if it was ".",
      because joinFileName "." x == x
      (fixes bug reported by Iavor Diatchki)
    
      Improve sdist a bit: copy files named in main-is, license-file and c-sources.
      Also supply a default Setup.hs if none is present.
      
      This will get it working for only the simplest of packages.  It omits
      header files, configure stuff and files named in the buildinfo file.
      To do it properly, we'd need a field in the package description listing
      extra files to copy into a source distribution.
    0b3d4691