Skip to content

Commit

Permalink
Refs #868: modified build scripts so 'make distdir' works
Browse files Browse the repository at this point in the history
* now ignore pdf build if pdflatex not found
* removed git-svn dependency; can now operate with svn only

svn-revision: r2629
  • Loading branch information
robmcmullen committed Nov 5, 2010
1 parent 24fad4b commit 971b7ed
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
6 changes: 3 additions & 3 deletions Makefile
Expand Up @@ -61,7 +61,7 @@ html: $(HTML) $(PRE) README.html README doc
mkdir -p web/manual mkdir -p web/manual
rsync -avuz manual/_build/html/ web/manual/ rsync -avuz manual/_build/html/ web/manual/


peppy/_peppy_version.py: .git/index peppy/_peppy_version.py:
./make-changelog.py -m peppy ./make-changelog.py -m peppy


web/thanks.html.in: web/thanks.html.in:
Expand Down Expand Up @@ -115,11 +115,11 @@ distdir: peppy/_peppy_version.py
-rm -f MANIFEST -rm -f MANIFEST
python setup.py sdist -k python setup.py sdist -k
(cd $(distdir)/manual; make) (cd $(distdir)/manual; make)
cp $(distdir)/manual/_build/latex/*.pdf $(distdir) -cp $(distdir)/manual/_build/latex/*.pdf $(distdir)
rm -rf $(distdir)/manual rm -rf $(distdir)/manual
chmod 644 $(distdir)/tests/*.py chmod 644 $(distdir)/tests/*.py


cp ./plugins/build/*.egg $(distdir)/peppy/plugins/eggs -cp ./plugins/build/*.egg $(distdir)/peppy/plugins/eggs


./make-doc.py -m peppy -o $(distdir)/py2exe/win-installer.nsi $(distdir)/py2exe/win-installer.nsi.in ./make-doc.py -m peppy -o $(distdir)/py2exe/win-installer.nsi $(distdir)/py2exe/win-installer.nsi.in


Expand Down
7 changes: 5 additions & 2 deletions make-changelog.py
Expand Up @@ -56,7 +56,10 @@ def findChangeLogVersionForGit(options):
return version, release_date, codename return version, release_date, codename


def getCurrentSvnRevision(options): def getCurrentSvnRevision(options):
info = subprocess.Popen(["git", "svn", "info"], stdout=subprocess.PIPE).communicate()[0] if os.path.exists(".git/index"):
info = subprocess.Popen(["git", "svn", "info"], stdout=subprocess.PIPE).communicate()[0]
else:
info = subprocess.Popen(["svn", "info"], stdout=subprocess.PIPE).communicate()[0]
rev = "rHEAD" rev = "rHEAD"
for line in info.splitlines(): for line in info.splitlines():
tags = line.split(":") tags = line.split(":")
Expand Down Expand Up @@ -147,7 +150,6 @@ def getGitChangeLogSuggestions(tag, options):
(options, args) = parser.parse_args() (options, args) = parser.parse_args()


version, dum, codename = findLatestChangeLogVersion(options) version, dum, codename = findLatestChangeLogVersion(options)
last_tag, git_version = getCurrentGitPatchlevel(options)
svn_revision = getCurrentSvnRevision(options) svn_revision = getCurrentSvnRevision(options)
if options.version: if options.version:
print version print version
Expand Down Expand Up @@ -181,6 +183,7 @@ def getGitChangeLogSuggestions(tag, options):
fh.close() fh.close()


if options.fixed: if options.fixed:
last_tag, git_version = getCurrentGitPatchlevel(options)
suggestions = getGitChangeLogSuggestions(last_tag, options) suggestions = getGitChangeLogSuggestions(last_tag, options)
for line in suggestions: for line in suggestions:
print line print line
2 changes: 1 addition & 1 deletion manual/Makefile
Expand Up @@ -33,4 +33,4 @@ latex:
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex


pdf: latex pdf: latex
(cd $(BUILDDIR)/latex; make) -(cd $(BUILDDIR)/latex; make)

0 comments on commit 971b7ed

Please sign in to comment.