Annotation of wikisrc/pkgsrc/targets.mdwn, revision 1.3

1.1       asau        1: # pkgsrc targets
                      2: 
                      3: It was proposed that we document _all_ pkgsrc targets,
                      4: but this is unreasonable and useless.
                      5: Most targets are ancilliary ones,
                      6: they exist because that's how make(1) works,
                      7: only few of them are useful for regular work.
                      8: 
                      9: The following targets may be useful to invoke from keyboard:
1.2       asau       10: 
1.3     ! asau       11: * "fetch" to fetch distribution file(s)
        !            12: * "checksum" to fetch and check distribution file(s)
1.1       asau       13: * "extract" to look at unmodified source
                     14: * "patch" to look at initial source
                     15: * "configure" to stop after configure stage
                     16: * "all" or "build" to stop after build stage
                     17: * "stage-install" to install under stage directory
                     18: * "test" to run package's self-tests, if any exist and supported
                     19: * "package" to create binary package before installing it
                     20: * "replace" to change (upgrade, downgrade, or just replace) installed package in-place
                     21: * "deinstall" to deinstall previous package
                     22: * "package-install" to install package and build binary package
                     23: * "install" to install package
1.3     ! asau       24: * "bin-install" to attempt to skip building from source and use pre-built binary package
        !            25: 
        !            26: The following targets are useful in development and thus may be useful for an advanced user:
        !            27: 
        !            28: * "makesum" to fetch and generate checksum for distributed file(s)
        !            29: * "makepatchsum" to (re)generate checksum for patches
        !            30: * "makedistinfo" to (re)generate "distinfo" file (creating checksums for distributed file and patches)
        !            31: * "mps" short for "makepatchsum"
        !            32: * "mdi" short for "makedistinfo"
1.1       asau       33: 
                     34: For example, package updating looks like this:
                     35: <pre>
                     36: rm -f distinfo && su root -c "make makesum clean" && make makepatchsum
                     37: make clean && make stage-install # build
                     38: # modify patches
                     39: make makepatchsum # and build again, or
                     40: make makepatchsum && make clean && make patch # until all patches apply, if they failed at first
                     41: make print-PLIST | diff -u PLIST -
                     42: # modify PLIST
                     43: rm $(make show-var VARNAME=WRKDIR)/.PLIST* # this deserves to be another target
                     44: make stage-install
                     45: # modify PLIST again or build again
                     46: make test # just to check for regressions
                     47: su root -c "make package deinstall bin-install" # or
                     48: su root -c "make package replace"
                     49: </pre>

CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb