[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: pmake patch



On Mon, Sep 04, 2000 at 09:40:25PM +0200, Marcus Brinkmann wrote:
> On Fri, Aug 25, 2000 at 11:54:40PM -0400, Igor Khavkine wrote:
> > Hi, some time ago Marcus mentioned that pmake needed a patch to work under the 
> > Hurd (MAXPATHLEN issues). I went through the code and corrected for it using 
> > dynamic memory allocation for all strings that were using MAXPATHLEN before.
> > My patch is attached. Please test it, I have not tested it on a Hurd machine, 
> > for lack thereof, but it should work since it only uses glibc.
> 
> Thanks for you rwork, Igor. There is one glitch. You define -D_GNU_SOURCE,
> but I don't see why.
> 
> You have:
> -       if (getcwd(curdir, MAXPATHLEN) == NULL) {
> +       if ((curdir = getcwd(NULL,0)) == NULL) {
> 
> Maybe this is why you defined _GNU_SOURCE. This is not necessary, the above
> will work without _GNU_SOURCE, which is only needed to get the prototype of
> get_current_dir_name. Neither is portable (but get_current_dir_name should
> be used if available, something that can be checked with autoconf.
> Unfortunately, pmake doesn't use autoconf). There is an xgetcwd
> implementation in inetutils, which I attach. This could be incorporated.
> 
> After fixing this, the patch should be reported to the Debian maintainer,
> who can add it to the Debian diff. He can also try to take it up with the
> upstream maintainers.
> 
Ok, i'll try it out. Having no internet for most of the last week did wonders
for my development work. I was able to test out the pmake patch and also
produce one for ash. I'm attaching it here. And I'll put it up on my page 
http://alcor.concordia.ca/~i_khavki/ with some comments that anyone who wants
to review the patch should read.

> > I think not having pmake was one of the obstacles in order to compile ash, 
> > hopefully that'll be possible now.
> 
> Yes, I will investigate.
> 
> Thanks,
> Marcus
> 

Igor

Attachment: ash-0.3.7-3.diff.gz
Description: Binary data


Reply to: