5.6. Ports Collection ¤ÎÍøÍÑ

¤³¤Î¥»¥¯¥·¥ç¥ó¤Ç¤Ï¡¢Ports Collection ¤òÍøÍѤ·¤Æ¥×¥í¥°¥é¥à¤ò¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¤ê¡¢ ¥·¥¹¥Æ¥à¤«¤éºï½ü¤·¤¿¤ê¤¹¤ë´ðËÜŪ¤Ê¼ê½ç¤Ë¤Ä¤¤¤ÆÀâÌÀ¤·¤Þ¤¹¡£ ÍøÍѲÄǽ¤Ê make ¤Î¥¿¡¼¥²¥Ã¥È¤ä´Ä¶­ÊÑ¿ô¤Ë¤Ä¤¤¤Æ¤Î¾ÜºÙ¤Ï ports(7) ¤ò¤´Í÷¤¯¤À¤µ¤¤¡£

警告FreeBSD Ports ¥×¥í¥¸¥§¥¯¥È¤Ï¡¢2012 ǯ¤Ë¥Ð¡¼¥¸¥ç¥ó´ÉÍý¥·¥¹¥Æ¥à¤ò CVS ¤«¤é Subversion ¤Ø¤È°Ü¹Ô¤·¤Þ¤·¤¿¡£ °ìÈÌŪ¤Ê ports ¤ÎÍøÍѤˤª¤¤¤Æ¿ä¾©¤µ¤ì¤ëÊýË¡¤Ï Portsnap ¤Ç¤¹¡£ ¥í¡¼¥«¥ë¤Ç ports ¤ò¥«¥¹¥¿¥Þ¥¤¥º¤·¤¿¤¤ (¤¹¤Ê¤ï¤Á¡¢¥í¡¼¥«¥ë¤ÇÄɲäΥѥåÁ¤ò¥á¥ó¥Æ¥Ê¥ó¥¹¤·¤¿¤¤) ¤È¹Í¤¨¤Æ¤¤¤ë¥æ¡¼¥¶¤Ï¡¢Ä¾ÀÜ Subversion ¤ò»È¤¦¤È¤è¤¤¤Ç¤·¤ç¤¦¡£ CVSup ¤Î¥µ¡¼¥Ó¥¹¤Ï¡¢ 2013 ǯ 2 ·î 28 Æü¤Þ¤Ç¤ËÃʳ¬Åª¤ËÇѻߤµ¤ì¤ë¤Î¤Ç¡¢ º£¸å CVSup ¤ÎÍøÍѤò¿Ê¤á¤ë¤³¤È¤Ï¡¢¿ä¾©¤µ¤ì¤Þ¤»¤ó¡£

5.6.1. Ports Collection ¤Î½àÈ÷

Ports Collection ¤È¤Ï¡¢/usr/ports °Ê²¼¤ËÃÖ¤«¤ì¤ë Makefile, ½¤Àµ¥Ñ¥Ã¥Á¡¢ ÀâÌÀʸ¤Ê¤É¤Î°ìÏ¢¤Î¥Õ¥¡¥¤¥ë¤Î¤³¤È¤Ç¤¹¡£¤³¤Î¥Õ¥¡¥¤¥ë¤Î¥»¥Ã¥È¤Ï¡¢ ¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤ò¥³¥ó¥Ñ¥¤¥ë¤·¤Æ FreeBSD ¤Ë¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ë¤Î¤ËÍѤ¤¤é¤ì¤Þ¤¹¡£ °Ê²¼¤Ç¤Ï¡¢FreeBSD ¤Î¥»¥Ã¥È¥¢¥Ã¥×»þ¤Ë Ports Collection ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤·¤Ê¤«¤Ã¤¿¾ì¹ç¤Ë¡¢ Ports Collection ¤ò½àÈ÷¤¹¤ëÊýË¡¤Ë¤Ä¤¤¤Æ¼¨¤·¤Þ¤¹¡£

Portsnap ¤òÍøÍѤ¹¤ëÊýË¡

Portsnap ¤Ï Ports Collection ¤ò¼èÆÀ¤¹¤ë¤¿¤á¤Î®¤¯¤Æ»È¤¤¤ä¤¹¤¯¡¢ ¿¤¯¤Î¥æ¡¼¥¶¤Ë¿ä¾©¤µ¤ì¤ë¥Ä¡¼¥ë¤Ç¤¹¡£ Portsnap ¤Îµ¡Ç½¤Ë¤Ä¤¤¤Æ¤Î¾ÜºÙ¤Ï Portsnap ¤ò»È¤¦ ¤ÎÀá¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£

  1. °µ½Ì¤µ¤ì¤¿ Ports Collection ¤Î¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¤ò /var/db/portsnap ¤Ë¥À¥¦¥ó¥í¡¼¥É¤·¤Æ¤¯¤À¤µ¤¤¡£

    # portsnap fetch
    
  2. ½é¤á¤Æ Portsnap ¤ò»È¤¦»þ¤Ï¡¢ ¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¤ò¤Þ¤º /usr/ports ¤ËŸ³«¤·¤Æ¤¯¤À¤µ¤¤¡£

    # portsnap extract
    

    ¾å¤Ç¼¨¤·¤¿ Portsnap ¤ò½é¤á¤ÆÍøÍѤ¹¤ëºÝ¤Ë¹Ô¤¦¥³¥Þ¥ó¥É¤ò¼Â¹Ô¤·¤¿¸å¤Ï¡¢ °Ê²¼¤Î¥³¥Þ¥ó¥É¤Ç /usr/ports ¤ò¥¢¥Ã¥×¥Ç¡¼¥È¤Ç¤­¤Þ¤¹¡£

    # portsnap update
    

Subversion ¤òÍѤ¤¤ëÊýË¡

¤¿¤È¤¨¤Ð¡¢¥í¡¼¥«¥ë¤ÇÊѹ¹ÅÀ¤ò¥á¥ó¥Æ¥Ê¥ó¥¹¤¹¤ë¾õ¶·¤Î¤è¤¦¤Ë¡¢ ports ¥Ä¥ê¡¼¤Î´ÉÍý¤¬É¬Íפʾì¹ç¤Ë¤Ï¡¢ Subversion ¤ò»È¤Ã¤Æ Ports Collection ¤ò¼èÆÀ¤¹¤ëÊýË¡¤¬¤¢¤ê¤Þ¤¹¡£ Subversion ¤Î¤è¤ê¾ÜºÙ¤ÊÀâÌÀ¤Ë¤Ä¤¤¤Æ¤Ï¡¢ Subversion Primer ¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£

  1. Subversion ¤ò»È¤Ã¤Æ ports ¥Ä¥ê¡¼¤ò¥Á¥§¥Ã¥¯¥¢¥¦¥È¤¹¤ëÁ°¤Ë¡¢ Subversion ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤·¤Æ¤ª¤¯É¬Íפ¬¤¢¤ê¤Þ¤¹¡£ ports ¥Ä¥ê¡¼¤¬¤¹¤Ç¤Ë¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Æ¤¤¤ì¤Ð¡¢ °Ê²¼¤Î¤è¤¦¤Ë¤·¤Æ Subversion ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤Ç¤­¤Þ¤¹¡£

    # cd /usr/ports/devel/subversion
    # make install clean
    

    ports ¥Ä¥ê¡¼¤¬¤Ê¤±¤ì¤Ð¡¢package ¤«¤é Subversion ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤Ç¤­¤Þ¤¹¡£

    # pkg_add -r subversion
    

    package ¤Î´ÉÍý¤Ë pkgng ¤ò»È¤Ã¤Æ¤¤¤ë¤Î¤Ç¤¢¤ì¤Ð¡¢Âå¤ï¤ê¤Ë°Ê²¼¤Î¤è¤¦¤Ë¤·¤Æ Subversion ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤Ç¤­¤Þ¤¹¡£

    # pkg install subversion
    
  2. ports ¥Ä¥ê¡¼¤ò¥Á¥§¥Ã¥¯¥¢¥¦¥È¤·¤Æ¤¯¤À¤µ¤¤¡£ ¥Ñ¥Õ¥©¡¼¥Þ¥ó¥¹¤òÎɤ¯¤¹¤ë¤¿¤á¡¢°Ê²¼¤Î¥³¥Þ¥ó¥É¤Ë¤ª¤¤¤Æ¡¢ svn.FreeBSD.org ¤ò Subversion ¥ß¥é¡¼ ¤ÎÃ椫¤éÃÏÍýŪ¤Ë¶á¤¤¾ì½ê¤Ë¤¢¤ë¥ß¥é¡¼¤ËÃÖ¤­´¹¤¨¤Æ¤¯¤À¤µ¤¤¡£ ¥³¥ß¥Ã¥¿¤ÎÊý¡¹¤Ï¡¢ºÇ½é¤Ë Subversion Primer ¤òÆɤó¤Ç¡¢Å¬Àڤʥץí¥È¥³¥ë¤òÁªÂò¤·¤Æ¤¯¤À¤µ¤¤¡£

    # svn checkout svn://svn.FreeBSD.org/ports/head /usr/ports
    
  3. Subversion ¤Ç¥Á¥§¥Ã¥¯¥¢¥¦¥È¤·¤¿¸å¡¢ /usr/ports ¤ò¥¢¥Ã¥×¥Ç¡¼¥È¤¹¤ë¤Ë¤Ï¡¢°Ê²¼¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£

    # svn update /usr/ports
    

sysinstall ¤òÍøÍѤ¹¤ëÊýË¡

¤³¤³¤Ç¤Ï¡¢sysinstall ¤òÍøÍѤ·¤Æ¥¤¥ó¥¹¥È¡¼¥ë¥á¥Ç¥£¥¢¤«¤é Ports Collection ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ëÊýË¡¤Ë¤Ä¤¤¤ÆÀâÌÀ¤·¤Þ¤¹¡£ ¤³¤ÎÊýË¡¤Ç¤Ï¡¢¥ê¥ê¡¼¥¹»þ¤Î¸Å¤¤ Ports Collection ¤¬¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤ë¤³¤È¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£ ¤â¤·¡¢¥¤¥ó¥¿¡¼¥Í¥Ã¥È¤Ø¤ÎÀܳ¤¬²Äǽ¤Ç¤¢¤ì¤Ð¡¢ ¤³¤ì¤Þ¤Ç¤ËÀâÌÀ¤·¤¿ÊýË¡¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£

  1. root ¥æ¡¼¥¶¸¢¸Â¤Ç¡¢°Ê²¼¤Î¤è¤¦¤Ë sysinstall ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£

    # sysinstall
    
  2. ¥¹¥¯¥í¡¼¥ë¥À¥¦¥ó¤·¤Æ Configure ¤òÁª¤Ó¡¢ Enter ¤ò²¡¤·¤Æ¤¯¤À¤µ¤¤¡£

  3. ¥¹¥¯¥í¡¼¥ë¥À¥¦¥ó¤·¤Æ Distributions ¤òÁª¤Ó¡¢ Enter ¤ò²¡¤·¤Æ¤¯¤À¤µ¤¤¡£

  4. ¥¹¥¯¥í¡¼¥ë¥À¥¦¥ó¤·¤Æ ports ¤òÁª¤Ó¡¢ Space ¥­¡¼¤ò²¡¤·¤Æ¤¯¤À¤µ¤¤¡£

  5. Exit ¤Þ¤Ç¥¹¥¯¥í¡¼¥ë¥¢¥Ã¥×¤·¤Æ¡¢ Enter ¤ò²¡¤·¤Æ¤¯¤À¤µ¤¤¡£

  6. CDROM ¤ä FTP ¤È¤¤¤Ã¤¿¥¤¥ó¥¹¥È¡¼¥ë¥á¥Ç¥£¥¢¤òÁªÂò¤·¤Æ¤¯¤À¤µ¤¤¡£

  7. Exit ¤Þ¤Ç¥¹¥¯¥í¡¼¥ë¥¢¥Ã¥×¤·¤Æ¡¢Enter ¤ò²¡¤·¤Æ¤¯¤À¤µ¤¤¡£

  8. X ¤ò²¡¤·¤Æ¡¢ sysinstall ¤ò½ªÎ»¤·¤Æ¤¯¤À¤µ¤¤¡£

5.6.2. CVSup/csup ¤«¤é portsnap ¤Ø¤Î°Ü¹Ô

警告2013 ǯ 2 ·î 28 Æü¤Þ¤Ç¤Ë ports ¥Ä¥ê¡¼¤Î CVS ¤Ø¤Î¥¨¥¯¥¹¥Ý¡¼¥È¤Ï½ªÎ»¤·¤Þ¤¹¡£ ¤½¤Î¤¿¤á¡¢CVSup ¤ª¤è¤Ó csup ¤òÍѤ¤¤Æ ports ¥Ä¥ê¡¼¤ò¥¢¥Ã¥×¥Ç¡¼¥È¤¹¤ë¤³¤È¤Ï¤Ç¤­¤Ê¤¯¤Ê¤ê¤Þ¤¹¡£

Portsnap ¤Ø¤Î°Ü¹Ô

°Ü¹Ô¤ËºÝ¤·¤Æ¤Ï¡¢ /usr ¤ËÌó 1 GB ¤Î¥Ç¥£¥¹¥¯ÍÆÎ̤ȡ¢ ¤µ¤é¤Ë Portsnap ¤ÏÌó 150 MB ¤Î¥Ç¥£¥¹¥¯ÍÆÎ̤ò /var ¤ËɬÍפȤ·¤Þ¤¹¡£

  1. ¤â¤· cron(8) ¤ò»È¤Ã¤Æ CVSup csup ¤ò¼Â¹Ô¤¹¤ë¤Ê¤É¡¢ ¼«Æ°Åª¤Ê ports ¤Î¥¢¥Ã¥×¥Ç¡¼¥È¤ò¹Ô¤Ê¤Ã¤Æ¤¤¤ë¤Î¤Ç¤¢¤ì¤Ð¡¢ Ää»ß¤·¤Æ¤¯¤À¤µ¤¤¡£

  2. ¸½ºß¤Î ports ¥Ä¥ê¡¼¤ò°ì»þŪ¤ËÊ̤ξì½ê¤Ë°ÜÆ°¤·¤Þ¤¹¡£

    # mv /usr/ports /usr/ports.old
    
  3. ¿·¤·¤¤ ports ¥Ä¥ê¡¼¤ò Portsnap ¤ò»È¤Ã¤Æ¥À¥¦¥ó¥í¡¼¥É¤·¤Æ¡¢ /usr/ports ¤ËŸ³«¤·¤Æ¤¯¤À¤µ¤¤¡£

    # portsnap fetch extract
    
  4. distfiles ¤ª¤è¤ÓÊݸ¤µ¤ì¤Æ¤¤¤ë packages ¤ò¿·¤·¤¤ port ¥Ä¥ê¡¼¤Ë°ÜÆ°¤·¤Æ¤¯¤À¤µ¤¤¡£

    # mv /usr/ports.old/distfiles /usr/ports
    # mv /usr/ports.old/packages /usr/ports
    
  5. ¸Å¤¤ ports ¥Ä¥ê¡¼¤òºï½ü¤·¤Æ¤¯¤À¤µ¤¤¡£

    # rm -rf /usr/ports.old
    
  6. ¤â¤· CVSup ¤ò»ÈÍѤ·¤Æ¤¤¤¿¤Î¤Ç¤¢¤ì¤Ð¡¢¥¢¥ó¥¤¥ó¥¹¥È¡¼¥ë¤Ç¤­¤Þ¤¹¡£

    # pkg_delete -r -v cvsup-without-gui-\*
    

    pkgng ¤Î¥æ¡¼¥¶¤Ï¡¢ °Ê²¼¤Î¥³¥Þ¥ó¥É¤ò»È¤Ã¤Æºï½ü¤Ç¤­¤Þ¤¹¡£

    # pkg delete cvsup-without-gui
    

Portsnap ¤Î¾ÜºÙ¤È¡¢ Portsnap ¤òÍѤ¤¤¿ ports ¥Ä¥ê¡¼¤Î¥¢¥Ã¥×¥Ç¡¼¥ÈÊýË¡¤Ë¤Ä¤¤¤Æ¤Ï¡¢ Portsnap ¤ò»È¤¦ ¤ÎÀá¤òÆɤó¤Ç¤¯¤À¤µ¤¤¡£

5.6.3. ports ¤Î¥¤¥ó¥¹¥È¡¼¥ë

port ¥¹¥±¥ë¥È¥ó¤Ï¡¢¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤ò FreeBSD ¾å¤ÇÀµ¤·¤¯¥³¥ó¥Ñ¥¤¥ë¤·¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ëÊýË¡¤òÄ󶡤¹¤ë¥Õ¥¡¥¤¥ë¤Î¥»¥Ã¥È¤Î¤³¤È¤Ç¤¹¡£ ¤½¤ì¤¾¤ì¤Î port ¥¹¥±¥ë¥È¥ó¤Ë¤Ï¡¢¼¡¤Î¥Õ¥¡¥¤¥ë¤¬´Þ¤Þ¤ì¤Æ¤¤¤Þ¤¹¡£

¤³¤ì¤é¤Î¾¤Ë pkg-message ¤È¤¤¤Ã¤¿¥Õ¥¡¥¤¥ë¤ò´Þ¤à ports ¤â¤¢¤ê¤Þ¤¹¡£ ports ¥·¥¹¥Æ¥à¤Ï¡¢ ¤³¤Î¤è¤¦¤Ê¥Õ¥¡¥¤¥ë¤òÍѤ¤¤ÆÆüì¤Ê¾õ¶·¤Ë¤âÂбþ¤·¤Æ¤¤¤Þ¤¹¡£ ¤³¤ì¤é¤Î¥Õ¥¡¥¤¥ë¤Ë¤Ä¤¤¤Æ¤Î¾ÜºÙ¤ª¤è¤Ó ports ¤Î°ìÈÌŪ¤ÊÀâÌÀ¤Ë¤Ä¤¤¤Æ¤Ï¡¢port ºîÀ®¼Ô¤Î¤¿¤á¤Î¥Ï¥ó¥É¥Ö¥Ã¥¯ ¤ò¤´Í÷²¼¤µ¤¤¡£

port ¤Ï¼ÂºÝ¤Î¥½¡¼¥¹¥³¡¼¥É (“distfile” ¤È¤â¸Æ¤Ð¤ì¤Þ¤¹) ¤ò´Þ¤ó¤Ç¤Ï¤¤¤Þ¤»¤ó¡£ ¥½¡¼¥¹¥³¡¼¥É¤Ï¥½¥Õ¥È¥¦¥§¥¢¤Îºî¼Ô¤¬¹¥¤à·Á¼°¤ÇÇÛÉÛ¤µ¤ì¤Þ¤¹¡£ °Ê²¼¤Ç¤Ï port ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ë 2 ¤Ä¤ÎÊýË¡¤Ë¤Ä¤¤¤ÆÀâÌÀ¤·¤Þ¤¹¡£

注意: ports ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ë¤Ë¤Ï¡¢ root ¤È¤·¤Æ¥í¥°¥¤¥ó¤¹¤ëɬÍפ¬¤¢¤ê¤Þ¤¹¡£

警告port ¤ò¥³¥ó¥Ñ¥¤¥ë¤¹¤ëÁ°¤Ë¡¢ Ports Collection ¤¬ºÇ¿·¤Ç¤¢¤ë¤³¤È¤ò³Îǧ¤·¤Æ¤¯¤À¤µ¤¤¡£ ¤Þ¤¿¡¢¤½¤Î port ¤Ë´ØÏ¢¤·¤¿¥»¥­¥å¥ê¥Æ¥£¾å¤ÎÌäÂ꤬¤Ê¤¤¤³¤È¤ò http://vuxml.freebsd.org/ ¤Ç³Îǧ¤·¤Æ¤¯¤À¤µ¤¤¡£ports-mgmt/portaudit ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤·¤Æ¤¤¤ë¤Î¤Ç¤¢¤ì¤Ð¡¢ ¿·¤·¤¯ port ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ëÁ°¤Ë¡¢ portaudit -F ¥³¥Þ¥ó¥É¤ò¼Â¹Ô¤·¤Æ¡¢ ºÇ¿·¤ÎÀȼåÀ­¤Ë´Ø¤¹¤ë¥Ç¡¼¥¿¥Ù¡¼¥¹¤ò¥À¥¦¥ó¥í¡¼¥É¤·¤Æ¤¯¤À¤µ¤¤¡£ ¥»¥­¥å¥ê¥Æ¥£¤Î¸¡ºº¤ª¤è¤Ó¥Ç¡¼¥¿¥Ù¡¼¥¹¤Î¹¹¿·¤Ï¡¢ Æü¡¹¤Î¥»¥­¥å¥ê¥Æ¥£¥Á¥§¥Ã¥¯¤Ç¹Ô¤Ê¤ï¤ì¤Þ¤¹¡£ ¾Ü¤·¤¯¤Ï¡¢ portaudit(1) ¤ª¤è¤Ó periodic(8) ¤Î¥Þ¥Ë¥å¥¢¥ë¥Ú¡¼¥¸¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£

Ports Collection ¤Ï¡¢¥Í¥Ã¥È¥ï¡¼¥¯¤ËÀܳ¤Ç¤­¤ë¤³¤È¤òÁÛÄꤷ¤Æ¤¤¤Þ¤¹¡£ ¤â¤·Àܳ¤Ç¤­¤Ê¤±¤ì¤Ð¡¢distfile ¤Î¥³¥Ô¡¼¤ò /usr/ports/distfiles ¤Ë¼êÆ°¤ÇÃÖ¤¤¤Æ¤¯¤À¤µ¤¤¡£

¤Þ¤º¡¢¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¤¤ port ¤Î¥Ç¥£¥ì¥¯¥È¥ê¤Ë°ÜÆ°¤·¤Æ¤¯¤À¤µ¤¤¡£

# cd /usr/ports/sysutils/lsof

port ¤ò¥³¥ó¥Ñ¥¤¥ë¤Þ¤¿¤Ï “¥Ó¥ë¥É (build)” ¤¹¤ë¤Ë¤Ï¡¢¥×¥í¥ó¥×¥È¤«¤é make ¤ÈÆþÎϤ·¤Æ¤¯¤À¤µ¤¤¡£ ¤½¤¦¤¹¤ë¤È¡¢¼¡¤Î¤è¤¦¤Ê½ÐÎϤ¬¸½¤ï¤ì¤ë¤Ï¤º¤Ç¤¹¡£

# make
>> lsof_4.57D.freebsd.tar.gz doesn't seem to exist in /usr/ports/distfiles/.
>> Attempting to fetch from ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/.
===>  Extracting for lsof-4.57
...
[extraction output snipped]
...
>> Checksum OK for lsof_4.57D.freebsd.tar.gz.
===>  Patching for lsof-4.57
===>  Applying FreeBSD patches for lsof-4.57
===>  Configuring for lsof-4.57
...
[configure output snipped]
...
===>  Building for lsof-4.57
...
[compilation output snipped]
...
#

¥³¥ó¥Ñ¥¤¥ë¤¬½ªÎ»¤¹¤ë¤È¡¢¥×¥í¥ó¥×¥È¤ËÌá¤ê¤Þ¤¹¡£ ¼¡¤Ë make install ¤ò»È¤Ã¤Æ¡¢ port ¤Î¥¤¥ó¥¹¥È¡¼¥ë¤ò¹Ô¤Ê¤¤¤Þ¤¹¡£

# make install
===>  Installing for lsof-4.57
...
[installation output snipped]
...
===>   Generating temporary packing list
===>   Compressing manual pages for lsof-4.57
===>   Registering installation for lsof-4.57
===>  SECURITY NOTE:
      This port has installed the following binaries which execute with
      increased privileges.
#

¥×¥í¥ó¥×¥È¤ËÌá¤Ã¤¿¤é¡¢ ¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¥×¥í¥°¥é¥à¤Ï¼Â¹Ô¤Ç¤­¤ë¤è¤¦¤Ë¤Ê¤Ã¤Æ¤¤¤Þ¤¹¡£ lsof ¤Ï¹â¤¤¸¢¸Â¤ÇÆ°ºî¤¹¤ë¥×¥í¥°¥é¥à¤Ê¤Î¤Ç¡¢ ¥»¥­¥å¥ê¥Æ¥£¤Ë´Ø¤¹¤ë·Ù¹ð¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£ports ¤Î¥³¥ó¥Ñ¥¤¥ë¤ä¥¤¥ó¥¹¥È¡¼¥ëÃæ¤Ëɽ¼¨¤µ¤ì¤ë¤³¤ì¤é¤Î·Ù¹ð¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£

¥³¥ó¥Ñ¥¤¥ë»þ¤ËºîÀ®¤µ¤ì¤ëºî¶ÈÍѥǥ£¥ì¥¯¥È¥ê¤òºï½ü¤¹¤ë¤ÈÎɤ¤¤Ç¤·¤ç¤¦¡£ ¤³¤Î¥Ç¥£¥ì¥¯¥È¥ê¤Ë¤Ï¥³¥ó¥Ñ¥¤¥ë»þ¤Ë»ÈÍѤµ¤ì¤ë¤¹¤Ù¤Æ¤Î°ì»þ¥Õ¥¡¥¤¥ë¤¬´Þ¤Þ¤ì¤Æ¤¤¤Þ¤¹¡£ ¤³¤Î¥Ç¥£¥ì¥¯¥È¥ê¤òºï½ü¤¹¤ë¤³¤È¤Ç¡¢¥Ç¥£¥¹¥¯ÍÆÎ̤òÀáÌó¤Ç¤­¡¢¤Þ¤¿ port ¤ò¿·¤·¤¤¥Ð¡¼¥¸¥ç¥ó¤Ø¥¢¥Ã¥×¥Ç¡¼¥È¤¹¤ëºÝ¤ËÌäÂ꤬µ¯¤³¤ë²ÄǽÀ­¤ò¾®¤µ¤¯¤·¤Þ¤¹¡£

# make clean
===>  Cleaning for lsof-4.57
#

注意: make¡¢make install ¤ª¤è¤Ó make clean ¤È»°¤Ä¤Ëʬ¤±¤é¤ì¤¿¼ê½ç¤ÎÂå¤ï¤ê¤Ë¡¢ ºÇ½é¤«¤é make install clean ¤È¼Â¹Ô¤¹¤ë¤³¤È¤Ç¡¢ ;ʬ¤Ê¼ê½ç¤òÆó¤Ä¾Ê¤¯¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£

注意: ¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¡¢¥æ¡¼¥¶¤Ë port ¤Î¥ª¥×¥·¥ç¥ó¤òÁªÂò¤µ¤»¤ëÀßÄê¤Î¤¿¤á¡¢ make install ¤À¤±¤Î¼Â¹Ô¤Ç¤Ï¡¢¥æ¡¼¥¶¤È¤ÎÂÐÏ䬵¯¤³¤êĹ»þ´ÖÂÔ¤¿¤µ¤ì¤ë¤³¤È¤¬¤¢¤ê¤Þ¤¹¡£ °Í¸¤¹¤ë port ¤Î¿ô¤¬Â¿¤¤¾ì¹ç¤Ë¡¢¤³¤ì¤òÈò¤±¤ë¤Ë¤Ï¡¢¤Þ¤ººÇ½é¤Ë make config-recursive ¤ò¼Â¹Ô¤·¤ÆÀßÄê¤ò°ì³ç¤Ç¹Ô¤¤¡¢¤½¤Î¸å make install [clean] ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£

ティップ: config-recursive ¤ò¼Â¹Ô¤¹¤ëºÝ¡¢ make(1) ¤Î¥¿¡¼¥²¥Ã¥È¤Ç¤¢¤ë all-depends-list ¤ò¼Â¹Ô¤¹¤ë¤È¡¢ÀßÄꤹ¤Ù¤­ ports ¤Î°ìÍ÷¤òÆÀ¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ ¿¤¯¤Î¾ì¹ç¤Ï¡¢¤¹¤Ù¤Æ¤Î°Í¸ ports ¤Î¥ª¥×¥·¥ç¥ó¤¬ÄêµÁ¤µ¤ì¡¢ ports ¥ª¥×¥·¥ç¥ó¤Î dialog(1) ²èÌ̤¬É½¼¨¤µ¤ì¤Ê¤¯¤Ê¤ê¡¢ ¤¹¤Ù¤Æ¤Î¥ª¥×¥·¥ç¥ó¤¬°Õ¿ÞÄ̤ê¤ËÀßÄꤵ¤ì¤¿¤³¤È¤ò³Îǧ¤Ç¤­¤ë¤Þ¤Ç make config-recursive ¤ò¼Â¹Ô¤¹¤ë¤ÈÎɤ¤¤Ç¤·¤ç¤¦¡£

注意: ¥·¥§¥ë¤Ë¤è¤Ã¤Æ¤Ï¥³¥Þ¥ó¥É¤Î¼Â¹Ô¥Õ¥¡¥¤¥ë¤òõ¤¹»þ´Ö¤òû½Ì¤¹¤ë¤¿¤á¤Ë¡¢ ´Ä¶­ÊÑ¿ô PATH ¤ËÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë ¥Ç¥£¥ì¥¯¥È¥ê¤Î¥³¥Þ¥ó¥É°ìÍ÷¤ò¥­¥ã¥Ã¥·¥å¤¹¤ë¤â¤Î¤¬¤¢¤ê¤Þ¤¹¡£ tcsh ¤ò»È¤Ã¤Æ¤¤¤ë¤Î¤Ç¤¢¤ì¤Ð¡¢ ¥Õ¥ë¥Ñ¥¹¤ò»ØÄꤹ¤ë¤³¤È¤Ê¤¯¿·¤·¤¯¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¥³¥Þ¥ó¥É¤òÍøÍѤǤ­¤ë¤è¤¦¤Ë¡¢ rehash ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£ sh ¥·¥§¥ë¤ò»È¤Ã¤Æ¤¤¤ë¤Î¤Ç¤¢¤ì¤Ð ¤«¤ï¤ê¤Ë hash -r ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£ ¾ÜºÙ¤Ë¤Ä¤¤¤Æ¤Ï¡¢ ¤¢¤Ê¤¿¤Î»È¤Ã¤Æ¤¤¤ë¥·¥§¥ë¤Î¥É¥­¥å¥á¥ó¥È¤ò¤´Í÷¤¯¤À¤µ¤¤¡£

FreeBSD Mall ¤Î FreeBSD Toolkit ¤Î¤è¤¦¤Ê¥µ¡¼¥É¥Ñ¡¼¥Æ¥£À½¤Î DVD-ROM À½ÉʤÎÃæ¤Ë¤Ï distfiles ¤ò¼ýÏ¿¤·¤Æ¤¤¤ë¤â¤Î¤¬¤¢¤ê¤Þ¤¹¡£ ¤³¤ì¤é¤ò Ports Collection ¤Ç»È¤¦¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ DVD-ROM ¤ò /cdrom ¤Ë¥Þ¥¦¥ó¥È¤·¤Æ¤¯¤À¤µ¤¤¡£ ¤Û¤«¤Î¥Þ¥¦¥ó¥È¥Ý¥¤¥ó¥È¤ò»ÈÍѤ·¤¿¤±¤ì¤Ð¡¢ CD_MOUNTPTS ÊÑ¿ô¤òÀßÄꤷ¤Æ¤¯¤À¤µ¤¤¡£ ¥Ç¥£¥¹¥¯¾å¤ËɬÍ×¤Ê distfiles ¤¬Â¸ºß¤¹¤ë¤È¡¢ ¼«Æ°Åª¤ËÍøÍѤµ¤ì¤Þ¤¹¡£

注意: port ¤Ë¤Ï DVD ¤Ø¤Î¼ýÏ¿¤òµö²Ä¤·¤Ê¤¤¥é¥¤¥»¥ó¥¹¾ò¹à¤ò»ý¤Ä¤â¤Î¤¬¤¢¤ê¤Þ¤¹¡£ ¤³¤ì¤Ë¤Ï¥À¥¦¥ó¥í¡¼¥ÉÁ°¤ËÅÐÏ¿¤òɬÍפȤ·¤¿¤ê¡¢ ºÆÇÛÉÛ¤¬¶Ø»ß¤µ¤ì¤Æ¤¤¤ë¤È¤¤¤¦Íýͳ¤¬¤¢¤ê¤Þ¤¹¡£ DVD ¤Ë´Þ¤Þ¤ì¤Æ¤¤¤Ê¤¤ port ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¤¤¾ì¹ç¤Ë¤Ï¡¢ ¥Í¥Ã¥È¥ï¡¼¥¯¤ËÀܳ¤¹¤ëɬÍפ¬¤¢¤ê¤Þ¤¹¡£

ports ¤Ï¡¢FTP_PASSIVE_MODE, FTP_PROXY, FTP_PASSWORD ¤È¤¤¤Ã¤¿´Ä¶­ÊÑ¿ô¤ò»²¾È¤¹¤ë fetch(1) ¤òÍѤ¤¤Æ¥Õ¥¡¥¤¥ë¤ò¥À¥¦¥ó¥í¡¼¥É¤·¤Þ¤¹¡£ ¥Õ¥¡¥¤¥¢¥¦¥©¡¼¥ë¤ÎÆ⦤Ǥ¢¤Ã¤¿¤ê¡¢ FTP/HTTP ¥×¥í¥­¥·¤ò»È¤¦¾ì¹ç¤Ë¤Ï¡¢ ¤³¤ì¤é¤Î´Ä¶­ÊÑ¿ô¤òÀßÄꤹ¤ë¤³¤È¤Ê¤ê¤Þ¤¹¡£ ´Ä¶­ÊÑ¿ô¤Î°ìÍ÷¤Ë¤Ä¤¤¤Æ¤Ï fetch(3) ¤ò¤´Í÷¤¯¤À¤µ¤¤¡£

¥Í¥Ã¥È¥ï¡¼¥¯¤Ë¾ï»þÀܳ¤Ç¤­¤Ê¤¤¥æ¡¼¥¶¤Î¤¿¤á¤Ë make fetch ¥³¥Þ¥ó¥É¤¬ÍÑ°Õ¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ (¥Í¥Ã¥È¥ï¡¼¥¯¤ËÀܳ¤·¤Æ¤¤¤ë»þ¤Ë) ¤³¤Î¥³¥Þ¥ó¥É¤ò /usr/ports ¤Ç¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£ ɬÍפʥե¡¥¤¥ë¤¬¥À¥¦¥ó¥í¡¼¥É¤µ¤ì¤Þ¤¹¡£ ¤³¤Î¥³¥Þ¥ó¥É¤Ï /usr/ports/net ¤È¤¤¤Ã¤¿¡¢¤è¤ê²¼¤Î³¬ÁؤΥ«¥Æ¥´¥ê¤Ë¤ª¤¤¤Æ¤â»È¤¦¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ ¤¢¤ë port ¤¬¥é¥¤¥Ö¥é¥ê¤ä¤½¤Î¾¤Î ports ¤Ë°Í¸¤·¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢ Ê̤Υ«¥Æ¥´¥ê¤Î ports ¤Î distfiles ¤Ï¥À¥¦¥ó¥í¡¼¥É¤µ¤ì¤Ê¤¤¤³¤È¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£ port ¤¬°Í¸¤·¤Æ¤¤¤ë¤¹¤Ù¤Æ¤ò¥À¥¦¥ó¥í¡¼¥É¤·¤¿¤±¤ì¤Ð¡¢ makefetch-recursive fetch ¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£

注意: ¥È¥Ã¥×¥Ç¥£¥ì¥¯¥È¥ê¤Ç make ¤ò¼Â¹Ô¤¹¤ë¤È¤¹¤Ù¤Æ¤Î port ¤¬¥Ó¥ë¥É¤µ¤ì¤Þ¤¹¡£ ¤·¤«¤·¤Ê¤¬¤é ports ¤ÎÃæ¤Ë¤ÏƱ»þ¤Ë¸ºß¤Ç¤­¤Ê¤¤¤â¤Î¤¬¤¢¤Ã¤¿¤ê¡¢ °Û¤Ê¤ë ports ¤ÎÊ̤Υե¡¥¤¥ë¤¬Æ±¤¸Ì¾Á°¤Ç ¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤ë¾ì¹ç¤¬¤¢¤ë¤³¤È¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£

¤á¤Ã¤¿¤Ë¤Ê¤¤¤³¤È¤«¤â¤·¤ì¤Þ¤»¤ó¤¬¡¢ ¥Ç¥Õ¥©¥ë¥È¤Î MASTER_SITES ¤Ë½ñ¤«¤ì¤Æ¤¤¤ë¥µ¥¤¥È°Ê³°¤«¤é tarball ¤ò»ý¤Ã¤Æ¤¯¤ë¤³¤È¤¬É¬Íפˤʤë¾ì¹ç¤¬¤¢¤ê¤Þ¤¹¡£ ¤½¤Î¤è¤¦¤Ê¾ì¹ç¤Ë¤Ï°Ê²¼¤Î¤è¤¦¤Ë MASTER_SITES ¤òÊѹ¹¤·¤Æ¤¯¤À¤µ¤¤¡£

# cd /usr/ports/directory
# make MASTER_SITE_OVERRIDE= \
ftp://ftp.FreeBSD.org/pub/FreeBSD/ports/distfiles/ fetch

¾å¤ÎÎã¤Ç¤Ï MASTER_SITES ¤ò ftp.FreeBSD.org/pub/FreeBSD/ports/distfiles/ ¤ËÊѹ¹¤·¤Æ¤¤¤Þ¤¹¡£

注意: ports ¤ÎÃæ¤Ë¤Ï¥Ó¥ë¥É¥ª¥×¥·¥ç¥ó¤ò»ØÄê¤Ç¤­¤ë¤â¤Î¤¬¤¢¤ê¤Þ¤¹¡£ ¤³¤Î¥ª¥×¥·¥ç¥ó¤ò»ØÄꤹ¤ë¤³¤È¤Ç¡¢ ¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Îµ¡Ç½¤Î°ìÉô¤òÍ­¸ú¤â¤·¤¯¤Ï̵¸ú¤Ë¤Ç¤­¤Þ¤¹¡£ ¤Þ¤¿¡¢¥»¥­¥å¥ê¥Æ¥£¥ª¥×¥·¥ç¥ó¤òÀßÄꤷ¤¿¤ê¡¢ ¤½¤Î¾¤Î¥«¥¹¥¿¥Þ¥¤¥º¤ò¹Ô¤¦¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ ¤³¤Î¤è¤¦¤Ê¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Ë¤Ï www/firefox, security/gpgme ¤ä mail/sylpheed-claws ¤Ê¤É¤¬¤¢¤ê¤Þ¤¹¡£ ÍøÍѲÄǽ¤Ê¥ª¥×¥·¥ç¥ó¤¬¤¢¤ë¾ì¹ç¤Ë¤Ï¡¢ port ¤ò¥³¥ó¥Ñ¥¤¥ë¤¹¤ëÁ°¤Ë¥á¥Ë¥å¡¼¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£

5.6.3.1. ports ¥Ç¥£¥ì¥¯¥È¥ê¤ÎÊѹ¹

WRKDIRPREFIX ÊÑ¿ô¤È PREFIX ÊÑ¿ô¤òÊѹ¹¤¹¤ë¤³¤È¤Ç¡¢ ºî¶È¥Ç¥£¥ì¥¯¥È¥ê¤ä¥¿¡¼¥²¥Ã¥È¥Ç¥£¥ì¥¯¥È¥ê¤ò¥Ç¥Õ¥©¥ë¥È¤Î¤â¤Î¤«¤éÊѹ¹¤Ç¤­¤Þ¤¹¡£

# make WRKDIRPREFIX=/usr/home/example/ports install

¤È¤¹¤ë¤È¡¢ports ¤Ï /usr/home/example/ports ¤Ç¥³¥ó¥Ñ¥¤¥ë¤µ¤ì¡¢¤¹¤Ù¤Æ /usr/local °Ê²¼¤Ë¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Þ¤¹¡£

# make PREFIX=/usr/home/example/local install

¤³¤Î¾ì¹ç¡¢port ¤Î¥³¥ó¥Ñ¥¤¥ë¤Ï /usr/ports ¤Ç¤ª¤³¤Ê¤¤¡¢ /usr/home/example/local ¤Ë¥¤¥ó¥¹¥È¡¼¥ë¤·¤Þ¤¹¡£

¤½¤·¤Æ¡¢

# make WRKDIRPREFIX=../ports PREFIX=../local install

¤È¤¹¤ì¤Ðξ¼Ô¤òÁȤ߹ç¤ï¤»¤ë¤³¤È¤¬²Äǽ¤Ç¤¹¡£

¤¢¤ë¤¤¤Ï¡¢¤³¤ì¤é¤ò´Ä¶­ÊÑ¿ô¤ËÀßÄꤹ¤ëÊýË¡¤â¤¢¤ê¤Þ¤¹¡£ ¤É¤Î¤è¤¦¤Ë´Ä¶­ÊÑ¿ô¤òÀßÄꤹ¤ë¤«¤Ë¤Ä¤¤¤Æ¤Ï¡¢ ¤¢¤Ê¤¿¤Î»È¤Ã¤Æ¤¤¤ë¥·¥§¥ë¤Î¥Þ¥Ë¥å¥¢¥ë¥Ú¡¼¥¸¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£

5.6.3.2. ports ¤ÎºÆ¹½ÃÛ

ports ¤ò¥³¥ó¥Ñ¥¤¥ë¤¹¤ëºÝ¡¢¥Ó¥ë¥É¥ª¥×¥·¥ç¥ó¤òÀßÄꤹ¤ë¤¿¤á¤Ë ncurses ¥Ù¡¼¥¹¤Î¥á¥Ë¥å¡¼¤¬É½¼¨¤µ¤ì¤ë¤³¤È¤¬¤¢¤ê¤Þ¤¹¡£ port ¤Î¹½Ã۸塢ºÆ¤Ó¤³¤Î¥á¥Ë¥å¡¼¤òɽ¼¨¤µ¤»¤Æ¥ª¥×¥·¥ç¥ó¤ÎÄɲääºï½ü¡¢ ÀßÄê¤ÎÊѹ¹¤ò¹Ô¤¦ÊýË¡¤Ï¤¿¤¯¤µ¤ó¤¢¤ê¤Þ¤¹¡£ °ì¤ÄÌÜ¤Ï port ¤Î¥Ç¥£¥ì¥¯¥È¥ê¤Ë cd ¤Ç°ÜÆ°¤·¡¢ make config ¤ÈÆþÎϤ¹¤ëÊýË¡¤Ç¤¹¡£ Ê̤ÎÊýË¡¤Ï make showconfig ¤ò»È¤¦ÊýË¡¤Ç¤¹¡£ ¾¤ÎÊýË¡¤Ï make rmconfig ¤Î¼Â¹Ô¤Ç¤¹¡£ ¤³¤Î¥³¥Þ¥ó¥É¤ò¼Â¹Ô¤¹¤ë¤ÈÁªÂò¤µ¤ì¤Æ¤¤¤ë¤¹¤Ù¤Æ¤Î¥ª¥×¥·¥ç¥ó¤¬ºï½ü¤µ¤ì¡¢ ÀßÄê¤ò¤â¤¦°ìÅÙ¤ä¤êľ¤¹¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£ ¤³¤ì¤é¤ÎÊýË¡¤ä¾¤ÎÊýË¡¤Ë¤Ä¤¤¤Æ¤Î¾ÜºÙ¤Ï¡¢ ports(7) ¥Þ¥Ë¥å¥¢¥ë¤ÇÀâÌÀ¤µ¤ì¤Æ¤¤¤Þ¤¹¡£

5.6.4. ¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿ ports ¤Îºï½ü

¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤¿ ports ¤ª¤è¤Ó packages ¤Ï¡¢ pkg_delete(1) ¥³¥Þ¥ó¥É¤Çºï½ü¤Ç¤­¤Þ¤¹¡£

# pkg_delete lsof-4.57

5.6.5. ports ¤Î¥¢¥Ã¥×¥°¥ì¡¼¥É

¤Þ¤ººÇ½é¤Ë pkg_version(1) ¥³¥Þ¥ó¥É¤ò»È¤Ã¤Æ¡¢ ¸Å¤¯¤Ê¤Ã¤Æ¤·¤Þ¤Ã¤¿ ports ¤ÎÃæ¤Ç¿·¤·¤¤¥Ð¡¼¥¸¥ç¥ó¤Ë¥¢¥Ã¥×¥Ç¡¼¥È²Äǽ¤Ê¤â¤Î¤ò Ports Collection ¤«¤é¥ê¥¹¥È¥¢¥Ã¥×¤·¤Æ¤¯¤À¤µ¤¤¡£

# pkg_version -v

5.6.5.1. /usr/ports/UPDATING ¤òÆɤà

Ports Collection ¤ò¹¹¿·¤·¤¿¤é¡¢port ¤ò¥¢¥Ã¥×¥°¥ì¡¼¥É¤¹¤ëÁ°¤Ë /usr/ports/UPDATING ¥Õ¥¡¥¤¥ë¤ËÌܤòÄ̤·¤Æ¤¯¤À¤µ¤¤¡£ ¤³¤Î¥Õ¥¡¥¤¥ë¤Ë¤Ï port ¤ò¥¢¥Ã¥×¥°¥ì¡¼¥É¤¹¤ëºÝ¤Ë¥æ¡¼¥¶¤¬Áø¶ø¤¹¤ë¤Ç¤¢¤í¤¦ÌäÂê¤ä¡¢ ÄɲäÇɬÍפʺî¶È¤Ê¤É¤¬µ­½Ò¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ Î㤨¤Ð¡¢¥Õ¥¡¥¤¥ë·Á¼°¤ÎÊѹ¹¤äÀßÄê¥Õ¥¡¥¤¥ë¤Î¾ì½ê¤ÎÊѹ¹¡¢ Á°¤Î¥Ð¡¼¥¸¥ç¥ó¤È¸ß´¹À­¤¬¤Ê¤¯¤Ê¤Ã¤¿¤³¤È¤Ê¤É¤¬½ñ¤«¤ì¤Æ¤¤¤Þ¤¹¡£

¤â¤·¡¢¤³¤ÎÀá¤Ë½ñ¤¤¤Æ¤¢¤ë¤³¤È¤È UPDATING ¤Ë½ñ¤«¤ì¤Æ¤¤¤ë¤³¤È¤¬Ì·½â¤·¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢ UPDATING ¤òÍ¥À褷¤Æ¤¯¤À¤µ¤¤¡£

5.6.5.2. portupgrade ¤òÍѤ¤¤¿ ports ¤Î¥¢¥Ã¥×¥°¥ì¡¼¥É

portupgrade ¤Ï¡¢ ¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿ ports ¤Î¥¢¥Ã¥×¥°¥ì¡¼¥É¤ò´Êñ¤Ë¹Ô¤Ê¤¦¤¿¤á¤Î¥æ¡¼¥Æ¥£¥ê¥Æ¥£¤Ç¤¹¡£ ports-mgmt/portupgrade port ¤«¤éÍøÍѤǤ­¤Þ¤¹¡£ ¾¤Î port ¤ÈƱ¤¸¤è¤¦¤Ë make install clean ¤Ç¥¤¥ó¥¹¥È¡¼¥ë¤·¤Æ¤¯¤À¤µ¤¤¡£

# cd /usr/ports/ports-mgmt/portupgrade
# make install clean

pkgdb -F ¤ò»È¤Ã¤Æ¡¢ ¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Æ¤¤¤ë ports ¤òÄ´¤Ù¤Æ¤¯¤À¤µ¤¤¡£ Ì·½â¤¬¸¡½Ð¤µ¤ì¤¿¾ì¹ç¤Ë¤Ï½¤Éü¤·¤Æ¤¯¤À¤µ¤¤¡£ ¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤ò¥¢¥Ã¥×¥Ç¡¼¥È¤¹¤ëÁ°¤Ë¤Ï¡¢ ¤³¤Îºî¶È¤òÄê´üŪ¤Ë¹Ô¤Ê¤¦¤È¤è¤¤¤Ç¤·¤ç¤¦¡£

¥·¥¹¥Æ¥à¤Ë¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Æ¤¤¤ë port ¤ÎÃæ¤Ç¸Å¤¯¤Ê¤Ã¤¿¤â¤Î¤ò¤¹¤Ù¤Æ¥¢¥Ã¥×¥Ç¡¼¥È¤¹¤ë¤Ë¤Ï portupgrade -a ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£ ¤â¤·¡¢¤¹¤Ù¤Æ¤Î ports ¤ËÂФ·¤Æ¸ÄÊ̤˥¢¥Ã¥×¥°¥ì¡¼¥É¤¹¤ë¤«¤É¤¦¤«¤ò³Îǧ¤·¤¿¤¤¤Î¤Ç¤¢¤ì¤Ð¡¢ -i ¤òÄɲ䷤Ƥ¯¤À¤µ¤¤¡£

# portupgrade -ai

ports ¤ÇÍøÍѲÄǽ¤Ê¤¹¤Ù¤Æ¤Î¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Ç¤Ï¤Ê¤¯¡¢ ¤¢¤ëÆÃÄê¤Î¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤À¤±¤ò¹¹¿·¤·¤¿¤¤¤Î¤Ç¤¢¤ì¤Ð¡¢ portupgrade pkgname ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£ ¥¢¥Ã¥×¥°¥ì¡¼¥É¤¹¤ë¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤¬°Í¸¤·¤Æ¤¤¤ë¤¹¤Ù¤Æ¤Î ports ¤ò¤Þ¤ºÀè¤Ë¹¹¿·¤·¤¿¤¤¾ì¹ç¤Ë¤Ï¡¢ -R ¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£

# portupgrade -R firefox

ports ¤Ç¤Ï¤Ê¤¯ packages ¤òÍѤ¤¤Æ¥¤¥ó¥¹¥È¡¼¥ë¤ò¹Ô¤Ê¤¤¤¿¤¤¾ì¹ç¤Ë¤Ï¡¢ -P ¥ª¥×¥·¥ç¥ó¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£ ¤³¤Î¥ª¥×¥·¥ç¥ó¤ò»È¤¦¤È¡¢portupgrade ¤Ï PKG_PATH ¤ËÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¥í¡¼¥«¥ë¥Ç¥£¥ì¥¯¥È¥ê¤ò¸¡º÷¤·¡¢ ¥í¡¼¥«¥ë¤Ë packages ¤¬¸«¤Ä¤«¤é¤Ê¤±¤ì¤Ð¡¢ ¥ê¥â¡¼¥È¥µ¥¤¥È¤«¤é¥À¥¦¥ó¥í¡¼¥É¤ò»î¤ß¤Þ¤¹¡£ packages ¤ò¥í¡¼¥«¥ë¤Ë¸«¤Ä¤±¤ë¤³¤È¤¬¤Ç¤­¤º¡¢ ¥ê¥â¡¼¥È¥µ¥¤¥È¤«¤é¤â¥À¥¦¥ó¥í¡¼¥É¤Ç¤­¤Ê¤¤¾ì¹ç¤Ë¤Ï¡¢ portupgrade ¤Ï ports ¤«¤é¥¤¥ó¥¹¥È¡¼¥ë¤ò¹Ô¤Ê¤¤¤Þ¤¹¡£ ports ¤ò»ÈÍѤ·¤¿¤¯¤Ê¤±¤ì¤Ð¡¢-PP ¥ª¥×¥·¥ç¥ó¤ò»ØÄꤷ¤Æ¤¯¤À¤µ¤¤¡£

# portupgrade -PP gnome2

¤Þ¤¿¡¢¥Ó¥ë¥É¤ä¥¤¥ó¥¹¥È¡¼¥ë¤ò¹Ô¤Ê¤ï¤º¡¢ distfiles (-P ¤¬»ØÄꤵ¤ì¤Æ¤¤¤ë¾ì¹ç¤Ï packages) ¤À¤±¤ò¥À¥¦¥ó¥í¡¼¥É¤·¤¿¤±¤ì¤Ð¡¢ -F ¥ª¥×¥·¥ç¥ó¤ò»ØÄꤷ¤Æ¤¯¤À¤µ¤¤¡£ ¾ÜºÙ¤Ï portupgrade(1) ¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£

5.6.5.3. portmaster ¤òÍѤ¤¤¿ ports ¤Î¥¢¥Ã¥×¥°¥ì¡¼¥É

¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿ ports ¤Î¥¢¥Ã¥×¥°¥ì¡¼¥É¤ò¹Ô¤¦¤¿¤á¤Î¤â¤¦°ì¤Ä¤Î¥æ¡¼¥Æ¥£¥ê¥Æ¥£¤¬ ports-mgmt/portmaster ¤Ç¤¹¡£ portmaster ¤Ï¡¢ ¾¤Î ports ¤Ë°Í¸¤»¤º¤Ë¡¢“base” ¥·¥¹¥Æ¥à¤Î¥Ä¡¼¥ë¤Î¤ß¤ò»È¤¦¤è¤¦¤ËÀ߷פµ¤ì¤Æ¤¤¤Þ¤¹¡£ ¤³¤Î¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Ï¡¢ ¤É¤Î ports ¤ò¥¢¥Ã¥×¥°¥ì¡¼¥É¤¹¤Ù¤­¤«¤ÎȽÃǤò¡¢ /var/db/pkg/ ¤Î¾ðÊó¤ò»È¤Ã¤Æ¹Ô¤¤¤Þ¤¹¡£ port ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤¹¤ë¤Ë¤Ï°Ê²¼¤Î¤è¤¦¤Ë¤·¤Æ¤¯¤À¤µ¤¤¡£

# cd /usr/ports/ports-mgmt/portmaster
# make install clean

Portmaster ¤Ï¡¢ports ¤ò 4 ¤Ä¤Î¥«¥Æ¥´¥ê¤ËʬÎष¤Þ¤¹¡£

  • Root ports: ¾¤Î port ¤Ë°Í¸¤»¤º¡¢Â¾¤Î port ¤«¤é¤â°Í¸¤µ¤ì¤Þ¤»¤ó¡£

  • Trunk ports: ¾¤Î port ¤Ë°Í¸¤·¤Þ¤»¤ó¤¬¡¢Â¾¤Î port ¤«¤é°Í¸¤µ¤ì¤Æ¤¤¤Þ¤¹¡£

  • Branch ports: ¾¤Î port ¤Ë°Í¸¤·¡¢Â¾¤Î port ¤«¤é¤â°Í¸¤µ¤ì¤Æ¤¤¤Þ¤¹¡£

  • Leaf ports: ¾¤Î port ¤Ë°Í¸¤·¤Þ¤¹¤¬¡¢Â¾¤Î port ¤«¤é¤Ï°Í¸¤µ¤ì¤Þ¤»¤ó¡£

-L ¥ª¥×¥·¥ç¥ó¤ò»È¤¦¤È¡¢ ¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿ ports ¤ä¥¢¥Ã¥×¥Ç¡¼¥È²Äǽ¤Ê port ¤Î°ìÍ÷¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£

# portmaster -L
===>>> Root ports (No dependencies, not depended on)
===>>> ispell-3.2.06_18
===>>> screen-4.0.3
        ===>>> New version available: screen-4.0.3_1
===>>> tcpflow-0.21_1
===>>> 7 root ports
...
===>>> Branch ports (Have dependencies, are depended on)
===>>> apache-2.2.3
        ===>>> New version available: apache-2.2.8
...
===>>> Leaf ports (Have dependencies, not depended on)
===>>> automake-1.9.6_2
===>>> bash-3.1.17
        ===>>> New version available: bash-3.2.33
...
===>>> 32 leaf ports

===>>> 137 total installed ports
        ===>>> 83 have new versions available

°Ê²¼¤Î¥³¥Þ¥ó¥É¤ò»È¤Ã¤Æ¡¢ ¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Æ¤¤¤ë¤¹¤Ù¤Æ¤Î ports ¤ò¥¢¥Ã¥×¥Ç¡¼¥È¤Ç¤­¤Þ¤¹¡£

# portmaster -a

注意: portmaster ¤Î¥Ç¥Õ¥©¥ë¥È¤ÎÀßÄê¤Ç¤Ï¡¢ ¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Æ¤¤¤ë port ¤òºï½ü¤¹¤ëÁ°¤Ë¥Ð¥Ã¥¯¥¢¥Ã¥×ÍѤΠpackage ¤¬ºîÀ®¤µ¤ì¤Þ¤¹¡£ ¤³¤Î¥Ð¥Ã¥¯¥¢¥Ã¥×¤Ï¡¢¿·¤·¤¤¥Ð¡¼¥¸¥ç¥ó¤Î¥¤¥ó¥¹¥È¡¼¥ë¤ËÀ®¸ù¤¹¤ë¤Èºï½ü¤µ¤ì¤Þ¤¹¡£ -b ¤ò»È¤¦¤È¡¢ portmaster ¤Ï¥Ð¥Ã¥¯¥¢¥Ã¥×¤ò¼«Æ°Åª¤Ëºï½ü¤·¤Þ¤»¤ó¡£ -i ¤òÄɲ乤ë¤È¡¢ portmaster ¤ò¥¤¥ó¥¿¥é¥¯¥Æ¥£¥Ö¥â¡¼¥É¤Ç»ÈÍѤǤ­¤Þ¤¹¡£ ¤³¤Î¥â¡¼¥É¤Ç¤Ï¡¢³Æ port ¤ò¥¢¥Ã¥×¥°¥ì¡¼¥É¤¹¤ë¤«¤É¤¦¤«¤ÎÁªÂò¤òÂÐÏÃŪ¤Ë¹Ô¤¦¤³¤È¤¬¤Ç¤Þ¤¹¡£

¥¢¥Ã¥×¥°¥ì¡¼¥É¤Î²áÄø¤Ç¥¨¥é¡¼¤ËÁø¶ø¤·¤¿¾ì¹ç¤Ë¤Ï¡¢ -f ¤ò»È¤Ã¤Æ¤¹¤Ù¤Æ¤Î ports ¤Î¥¢¥Ã¥×¥°¥ì¡¼¥É¤äºÆ¹½ÃÛ¤ò¹Ô¤Ê¤Ã¤Æ¤¯¤À¤µ¤¤¡£

# portmaster -af

portmaster ¤ò»È¤Ã¤Æ¥·¥¹¥Æ¥à¤Ë¿·¤·¤¤ ports ¤ò¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¤ê¡¢¿·¤·¤¤ port ¤Î¥³¥ó¥Ñ¥¤¥ë¤ä¥¤¥ó¥¹¥È¡¼¥ëÁ°¤Ë°Í¸¤¹¤ë¤¹¤Ù¤Æ¤Î port ¤ò¥¢¥Ã¥×¥°¥ì¡¼¥É¤Ç¤­¤Þ¤¹¡£

# portmaster shells/bash

¾ÜºÙ¤Ë¤Ä¤¤¤Æ¤Ï portmaster(8) ¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£

5.6.6. ports ¤È¥Ç¥£¥¹¥¯ÍÆÎÌ

Ports Collection ¤ò»È¤¤Â³¤±¤Æ¤¤¤ë¤È¡¢ ¤½¤Î¤¦¤Á¥Ç¥£¥¹¥¯¤ò¿©¤¤¤Ä¤Ö¤·¤Æ¤·¤Þ¤¦¤Ç¤·¤ç¤¦¡£ ports ¤ò¥Ó¥ë¥É¤·¤Æ¥¤¥ó¥¹¥È¡¼¥ë¤·¤¿¸å¡¢ make clean ¤Ïºî¶ÈÍѤΠwork ¥Ç¥£¥ì¥¯¥È¥ê¤òºï½ü¤·¤Þ¤¹¡£ °Ê²¼¤Î¥³¥Þ¥ó¥É¤Ç Ports Collection ¤òÁݽü¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£

# portsclean -C

»þ´Ö¤¬·Ð¤Ä¤Ë¤Ä¤ì distfiles ¥Ç¥£¥ì¥¯¥È¥ê¤Ë¤Ï¡¢¸Å¤¯¤Ê¤Ã¤¿¥½¡¼¥¹¥Õ¥¡¥¤¥ë¤¬¤¿¤Þ¤Ã¤Æ¤¤¤­¤Þ¤¹¡£ ¼¡¤Î¥³¥Þ¥ó¥É¤Ç¡¢¤É¤Î ports ¤«¤é¤â»È¤ï¤ì¤Æ¤¤¤Ê¤¤ distfiles ¤òºï½ü¤Ç¤­¤Þ¤¹¡£

# portsclean -D

¥·¥¹¥Æ¥à¤Ë¥¤¥ó¥¹¥È¡¼¥ë¤µ¤ì¤Æ¤¤¤ë port ¤«¤é»È¤ï¤ì¤Æ¤¤¤Ê¤¤ distfiles ¤ò¤¹¤Ù¤Æºï½ü¤¹¤ë¤Ë¤Ï¡¢°Ê²¼¤Î¥³¥Þ¥ó¥É¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£

# portsclean -DD

注意: portsclean ¥æ¡¼¥Æ¥£¥ê¥Æ¥£¤Ï portupgrade ¥Ä¡¼¥ë·²¤Î°ìÉô¤Ç¤¹¡£

ports-mgmt/pkg_cutleaves port ¤Ï¡¢ ɬÍפʤ¯¤Ê¤Ã¤¿ ports ¤òºï½ü¤¹¤ëºî¶È¤ò¼«Æ°²½¤·¤Þ¤¹¡£

ËÜʸ½ñ¡¢¤ª¤è¤Ó¾¤Îʸ½ñ¤Ï ftp://ftp.FreeBSD.org/pub/FreeBSD/doc/ ¤«¤é¥À¥¦¥ó¥í¡¼¥É¤Ç¤­¤Þ¤¹¡£

FreeBSD ¤Ë´Ø¤¹¤ë¼ÁÌ䤬¤¢¤ë¾ì¹ç¤Ë¤Ï¡¢¥É¥­¥å¥á¥ó¥È ¤òÆɤó¤À¾å¤Ç <questions@FreeBSD.org> ¤Þ¤Ç (±Ñ¸ì¤Ç) Ï¢Íí¤·¤Æ¤¯¤À¤µ¤¤¡£
ËÜʸ½ñ¤Ë´Ø¤¹¤ë¼ÁÌä¤Ë¤Ä¤¤¤Æ¤Ï¡¢<doc@FreeBSD.org> ¤Þ¤ÇÅŻҥ᡼¥ë¤ò (±Ñ¸ì¤Ç) Á÷¤Ã¤Æ¤¯¤À¤µ¤¤¡£