Skip to content

Commit

Permalink
Fix 'scons dist'
Browse files Browse the repository at this point in the history
This makes 'scons dist' work, although the resulting tarballs are not
yet identical to cmake tarballs.

Remove awk usage made obsolete by the git transition
(7f85fa0).

Update src/revision.hpp reference to use src/revision.h.  The former
name is unused since at least 7625b1e.
  • Loading branch information
jostephd authored and jyrkive committed Jun 23, 2018
1 parent f2c2ef1 commit 91586e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions SConstruct
Expand Up @@ -762,11 +762,11 @@ if 'dist' in COMMAND_LINE_TARGETS: # Speedup, the manifest is expensive
def dist_manifest():
"Get an argument list suitable for passing to a distribution archiver."
# Start by getting a list of all files under version control
lst = subprocess.check_output("git ls-files | grep -v 'data\/test\/.*' | awk '/^[^?]/ {print $4;}'", shell=True).split()
lst = subprocess.check_output("git ls-files | grep -v 'data\/test\/.*'", shell=True).splitlines()
lst = filter(os.path.isfile, lst)
return lst
dist_tarball = env.Tar('wesnoth-${version}.tar.bz2', [])
open("dist.manifest", "w").write("\n".join(dist_manifest() + ["src/revision.hpp"]))
open("dist.manifest", "w").write("\n".join(dist_manifest() + ["src/revision.h"]))
env.Append(TARFLAGS='-j -T dist.manifest --transform "s,^,wesnoth-$version/,"',
TARCOMSTR="Making distribution tarball...")
env.AlwaysBuild(dist_tarball)
Expand Down

0 comments on commit 91586e9

Please sign in to comment.