Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building documentation from the tarball fails #2187

Merged
merged 2 commits into from
Jul 19, 2013
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 6 additions & 0 deletions doc/make.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,12 @@ def all():
os.chdir(os.path.dirname(os.path.join(current_dir, __file__)))
copy_if_out_of_date('../INSTALL', 'users/installing.rst')

# Create the examples symlink, if it doesn't exist
if not os.path.exists('mpl_examples'):
if hasattr(os, 'symlink'):
os.symlink('../examples', 'mpl_examples')
else:
shutil.copytree('../examples', 'mpl_examples')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there an OS that doesn't support symlinks? If so, should we delete the folder if it was copied (not symlinked)? Of course, there's an argument to be made against a makefile's 'install' target to delete things.

Also, subsequent documentation builds will copy this regardless if it is out of date or not. I notice a copy_if_out_of_date function on line 237. I think I'd like that to be used here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MS-Windows doesn't support symlinks, at least not on all file systems. Even Linux, when running on an external FAT32 USB drive, for example, may not support symlinks.

Not a bad idea to "copy_if_out_of_date" (recursively), of course.


if len(sys.argv)>1:
if '--small' in sys.argv[1:]:
Expand Down