[haiku-bugs] Re: [Haiku] #5508: [patch] AddExpanderRuleToHaikuImage (was: [WIP-patch] AddExpanerRule)

  • From: "mmadia" <trac@xxxxxxxxxxxx>
  • Date: Mon, 01 Mar 2010 23:26:13 -0000

#5508: [patch] AddExpanderRuleToHaikuImage
--------------------------+-------------------------------------------------
 Reporter:  mmadia        |       Owner:  bonefish      
     Type:  enhancement   |      Status:  new           
 Priority:  normal        |   Milestone:  R1            
Component:  Build System  |     Version:  R1/Development
 Keywords:                |   Blockedby:                
 Platform:  All           |    Blocking:  5155          
--------------------------+-------------------------------------------------

Old description:

> This patch creates a new rule AddExpanerRule, which allows optional
> packages to add one or more rules to common/etc/expander.rules
>
> It is functional for the P7zip package. However,
> BuildHaikuImageExpanderRules isn't outputting the desired output for the
> XZ-Utils package.
>
> common/etc/expander.rules:
> {{{
> "application/x-7z-compressed"   .7z     "7za l %s"      "7za x -y %s"
> "application/x-xz"      .tar.xz "xz -dc %s \
>  tar tvf -"     "xz -dc %s \
>  tar xvf -"
> "application/x-xz"      .txz    "echo %s \
>  sed 's/.xz$//g'"       "xz -df %s"
> }}}
>
> As you'll see, the "|" in build/jam/OptionalPackages is somehow causing
> an odd looking line break

New description:

 This patch creates a new rule AddExpanerRule, which allows optional
 packages to add one or more rules to common/etc/expander.rules

 It is functional for the P7zip package and an upcoming XZ-Utils package.
 Tested in Haiku and FreeBSD.

 common/etc/expander.rules:
 {{{
 "application/x-7z-compressed"   .7z     "7za l %s"      "7za x -y %s"
 "application/x-xz"      .tar.xz "xz -dc %s | tar tvf -" "xz -dc %s | tar
 xvf -"
 "application/x-xz"      .txz    "echo %s | sed 's/.xz$//g'"     "xz -df
 %s"
 }}}

--

Comment(by mmadia):

 The patch is updated.  One thing that puzzles me, in r34942 {{{ echo -e
 ... }}} was removed as the '-e' option isn't supported on FreeBSD. Despite
 this, action BuildHaikuImageExpanderRules seems to work without issue.

-- 
Ticket URL: <http://dev.haiku-os.org/ticket/5508#comment:7>
Haiku <http://dev.haiku-os.org>
Haiku - the operating system.

Other related posts:

  • » [haiku-bugs] Re: [Haiku] #5508: [patch] AddExpanderRuleToHaikuImage (was: [WIP-patch] AddExpanerRule) - mmadia