RESOLVED FIXED Bug 82448
[GTK] generate-gtk-doc doesn't cope with custom build directory
https://bugs.webkit.org/show_bug.cgi?id=82448
Summary [GTK] generate-gtk-doc doesn't cope with custom build directory
Philippe Normand
Reported 2012-03-28 04:16:58 PDT
I have one product directory per branch. So generate-gtk-doc should use WebKitBuild/brancName/Release or Debug instead of trying almost random directories in WebKitBuild :)
Attachments
Patch (7.72 KB, patch)
2012-03-28 04:20 PDT, Philippe Normand
mrobinson: review-
Patch (4.21 KB, patch)
2012-03-28 08:12 PDT, Philippe Normand
mrobinson: review+
mrobinson: commit-queue-
Philippe Normand
Comment 1 2012-03-28 04:20:49 PDT
Philippe Normand
Comment 2 2012-03-28 04:21:30 PDT
Carlos can you please test this patch in the distcheck scenario?
Martin Robinson
Comment 3 2012-03-28 07:56:59 PDT
Comment on attachment 134263 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=134263&action=review > Tools/gtk/generate-gtkdoc:-123 > + build_directory = sys.argv[-1] > options = get_common_options().copy() > options.update({ > 'module_name' : 'webkitgtk', > 'doc_dir' : src_path('docs'), > - 'output_dir' : common.build_path('Documentation', 'webkitgtk'), This looks like it will pass something crazy (like the command name) if you don't pass an argument for build directory. I think I'd like to keep the logic for understanding the command-line arguments in common.build_path instead of forcing all the code here to pass the build_directory down. in common.get_build_path() you could do this: def get_build_path(): if len(sys.argv) > 1 and os.path.exists(sys.argv[-1]): # Try to use this path as a build directory. With that change you could avoid all the modifications to this file.
Philippe Normand
Comment 4 2012-03-28 08:12:38 PDT
Martin Robinson
Comment 5 2012-03-28 09:03:49 PDT
Comment on attachment 134299 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=134299&action=review > Tools/gtk/common.py:-40 > - global build_dir > - if build_dir: > - return build_dir Why do you no longer cache the build directory here?
Martin Robinson
Comment 6 2012-03-28 09:07:00 PDT
Comment on attachment 134299 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=134299&action=review >> Tools/gtk/common.py:-40 >> - return build_dir > > Why do you no longer cache the build directory here? I cannot see a reason why it isn't. The patch looks great, but I think caching the build directory was a nice feature in that it avoided touching the file system every time you needed the build directory. Perhaps you could restore that before landing?
Philippe Normand
Comment 7 2012-03-28 09:13:59 PDT
(In reply to comment #5) > (From update of attachment 134299 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=134299&action=review > > > Tools/gtk/common.py:-40 > > - global build_dir > > - if build_dir: > > - return build_dir > > Why do you no longer cache the build directory here? Right, I'll restore this part and land, thanks for the review :)
Philippe Normand
Comment 8 2012-03-28 09:33:32 PDT
Note You need to log in before you can comment on or make changes to this bug.