Changes between Version 24 and Version 25 of howto/cpan2port


Ignore:
Timestamp:
Mar 1, 2019, 10:23:26 PM (6 years ago)
Author:
hyperbole (hyperbole)
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • howto/cpan2port

    v24 v25  
    9494}}}
    9595
    96 === Step 7: '''Build the port''' ===
     96=== Step 7: '''Fix the Portfile''' ===
     97
     98The Portfile as generated is in rough form and not ready for submission as a new or updated port. Please at least check and update the following in the Portfile:
     99
     100  * Check if the port compiles any files or is simply straight perl code. If the latter, then uncomment the following line and delete the comment above it. Otherwise delete the lines entirely.
     101{{{
     102# Uncomment this line if you know there will be no arch-specific code:
     103#supported_archs     noarch
     104}}}
     105
     106  * Determine and add the correct license. There is a commented license line that is common to many perl ports.
     107{{{
     108#license             {Artistic-1 GPL}
     109}}}
     110
     111  * Dependencies need to be put into an if block so that they only appear in the sub-ports, not the stub p5 port. See below as an example.
     112{{{
     113if {${perl5.major} != ""} {
     114    depends_lib-append  port:p${perl5.major}-digest-md5 \
     115                        port:p${perl5.major}-io-compress
     116}
     117}}}
     118
     119  * Check the appropriate perl versions supported by the port. At the time of writing, 5.28 is the current and only version in use.
     120{{{
     121perl5.branches      5.28
     122}}}
     123
     124
     125=== Step 8: '''Build the port''' ===
    97126First you can review the portfile:
    98127{{{
     
    142171}}}
    143172
    144 === Step 8: '''Fix the Portfile''' ===
    145 
    146 The Portfile as generated is in rough form and not ready for submission as a new or updated port. Please at least check and update the following in the Portfile:
    147 
    148   * Check if the port compiles any files or is simply straight perl code. If the latter, then uncomment the following line and delete the comment above it. Otherwise delete the lines entirely.
    149 {{{
    150 # Uncomment this line if you know there will be no arch-specific code:
    151 #supported_archs     noarch
    152 }}}
    153 
    154   * Determine and add the correct license. There is a commented license line that is common to many perl ports.
    155 {{{
    156 #license             {Artistic-1 GPL}
    157 }}}
    158 
    159   * Dependencies need to be put into an if block so that they only appear in the sub-ports, not the stub p5 port. See below as an example.
    160 {{{
    161 if {${perl5.major} != ""} {
    162     depends_lib-append  port:p${perl5.major}-digest-md5 \
    163                         port:p${perl5.major}-io-compress
    164 }
    165 }}}
    166 
    167   * Check the appropriate perl versions supported by the port. At the time of writing, 5.28 is the current and only version in use.
    168 {{{
    169 perl5.branches      5.28
    170 }}}
    171 
    172 
    173 If you make changes to the Portfile, remember to re-build it:
    174 {{{
    175 $ cd ~/macports/perl/p5-timedate
    176 $ sudo port build
    177 }}}
    178 
    179173=== Step 9: '''Update your PortIndex Files''' ===
    180174
     
    185179$ portindex
    186180}}}
     181
     182If you make changes to the Portfile, remember to re-build it:
     183{{{
     184$ cd ~/macports/perl/p5-timedate
     185$ sudo port build
     186}}}
     187
    187188----
    188189