guix-devel
[Top][All Lists]
Advanced

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

Re: info dir clashes


From: Ludovic Courtès
Subject: Re: info dir clashes
Date: Mon, 06 Apr 2015 00:26:38 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux)

Mark H Weaver <address@hidden> skribis:

> Federico Beffa <address@hidden> writes:
>
>> From 06441ea6992808ef96139ab171269172dc65f2db Mon Sep 17 00:00:00 2001
>> From: Federico Beffa <address@hidden>
>> Date: Sun, 5 Apr 2015 21:59:18 +0200
>> Subject: [PATCH] build-system/gnu: Add 'delete-info-dir-file' phase.
>>
>> * guix/build/gnu-build-system.scm (delete-info-dir-file): New procedure.
>>   (%standard-phases): Use it.
>> ---
>>  guix/build/gnu-build-system.scm | 10 ++++++++++
>>  1 file changed, 10 insertions(+)
>>
>> diff --git a/guix/build/gnu-build-system.scm 
>> b/guix/build/gnu-build-system.scm
>> index 5220bda..284d1ee 100644
>> --- a/guix/build/gnu-build-system.scm
>> +++ b/guix/build/gnu-build-system.scm
>> @@ -538,6 +538,15 @@ DOCUMENTATION-COMPRESSOR-FLAGS."
>>          (format #t "not compressing documentation~%")
>>          #t)))
>>  
>> +(define* (delete-info-dir-file #:key outputs #:allow-other-keys)
>> +  (every (match-lambda
>> +          ((output . directory)
>> +           (let ((info-dir-file (string-append directory 
>> "/share/info/dir")))
>> +             (when (file-exists? info-dir-file)
>> +               (delete-file info-dir-file))
>> +             #t)))
>> +         outputs))
>
> In this case 'for-each' is the appropriate tool, since it ignores the
> results of the procedure calls, which are made only for their side
> effects.  So you can omit the #t.

Agreed.

Also add a docstring please.

> Otherwise, looks good to me for 'core-updates'.

One last thing:

>              patch-usr-bin-file
>              patch-source-shebangs configure patch-generated-file-shebangs
>              build check install
> +            delete-info-dir-file
>              patch-shebangs strip
>              validate-runpath
>              validate-documentation-location

The phase should go after ‘validate-documentation-location’, which is
makes sure things are in share/info/ rather than info/.

OK to push to ‘core-updates’ with these changes.

Thanks!

Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]