Changes between Version 25 and Version 26 of howto/cpan2port


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

--

Legend:

Unmodified
Added
Removed
Modified
  • howto/cpan2port

    v25 v26  
    9696=== Step 7: '''Fix the Portfile''' ===
    9797
    98 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:
    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 {{{
    113 if {${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 {{{
    121 perl5.branches      5.28
    122 }}}
    123 
    124 
    125 === Step 8: '''Build the port''' ===
    12698First you can review the portfile:
    12799{{{
     
    145117}}}
    146118
    147 Then build it:
    148    # Note: make sure you're in the Portfile directory for the port you want to build. In our case ~/macports/perl/p5-timedate.
     119The 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. Edit the file to make the following changes:
    149120
     121  * 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.
    150122{{{
     123# Uncomment this line if you know there will be no arch-specific code:
     124#supported_archs     noarch
     125}}}
     126
     127  * Find and add the correct license. There is a commented license line that is common to many perl ports.
     128{{{
     129#license             {Artistic-1 GPL}
     130}}}
     131
     132  * 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.
     133{{{
     134if {${perl5.major} != ""} {
     135    depends_lib-append  port:p${perl5.major}-digest-md5 \
     136                        port:p${perl5.major}-io-compress
     137}
     138}}}
     139
     140  * Check the appropriate perl versions supported by the port. At the time of writing, 5.28 is the current version in use.
     141{{{
     142perl5.branches      5.28
     143}}}
     144
     145=== Step 8: '''Build the port''' ===
     146{{{
     147$ cd ~/macports/perl/p5-timedate
    151148$ sudo port build
    152149--->  Computing dependencies for p5-timedate