Bug 34920

Summary: [GTK] Fails to build on GNU/Hurd because of PATH_MAX usage
Product: WebKit Reporter: Emilio Pozuelo Monfort <pochu27>
Component: WebKitGTKAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, darin
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Other   
Attachments:
Description Flags
Avoid using PATH_MAX for portability reasons
gustavo: review-
Avoid using PATH_MAX for portability reasons none

Description Emilio Pozuelo Monfort 2010-02-13 07:06:18 PST
Hi,

WebKit built fine on GNU/Hurd until 1.1.17. However some release after that has introduced PATH_MAX in a couple of tests. PATH_MAX is not guaranteed to be defined and thus shouldn't be used unconditionally for portability reasons.

I've prepared a patch to avoid using PATH_MAX to let WebKit build on GNU/Hurd again. It uses dynamic allocation instead of fixed size buffers.
Comment 1 Emilio Pozuelo Monfort 2010-02-13 07:18:16 PST
Created attachment 48703 [details]
Avoid using PATH_MAX for portability reasons

The patch is against 1.1.20 and builds fine, so since the patch is for the test suite, the tests should be fine :)
Comment 2 Gustavo Noronha (kov) 2010-02-14 08:04:19 PST
Comment on attachment 48703 [details]
Avoid using PATH_MAX for portability reasons

Patch looks sane, can you add a ChangeLog entry to WebKit/gtk/ChangeLog, and repost, please? =)
Comment 3 Emilio Pozuelo Monfort 2010-02-14 11:44:09 PST
Created attachment 48730 [details]
Avoid using PATH_MAX for portability reasons

Now with a ChangeLog entry. Patch against current git.

I haven't built the tests in git, should I? If so, what's the best way to do it?
Comment 4 Gustavo Noronha (kov) 2010-02-15 08:09:51 PST
Comment on attachment 48730 [details]
Avoid using PATH_MAX for portability reasons

Setting the review flag, since Emilio forgot it.
Comment 5 Gustavo Noronha (kov) 2010-02-15 09:26:26 PST
Comment on attachment 48730 [details]
Avoid using PATH_MAX for portability reasons

Thanks!
Comment 6 WebKit Commit Bot 2010-02-15 09:46:45 PST
Comment on attachment 48730 [details]
Avoid using PATH_MAX for portability reasons

Clearing flags on attachment: 48730

Committed r54779: <http://trac.webkit.org/changeset/54779>
Comment 7 WebKit Commit Bot 2010-02-15 09:46:52 PST
All reviewed patches have been landed.  Closing bug.