TheMacPortsWiki/InstallingMacPorts
の編集
http://www.lapangan.net/darwinports/?TheMacPortsWiki%2FInstallingMacPorts
[
トップ
] [
編集
|
差分
|
バックアップ
|
添付
|
リロード
] [
新規
|
一覧
|
単語検索
|
最終更新
|
ヘルプ
]
-- 雛形とするページ --
BracketName
DarwinPorts
DarwinPortsGuide
DarwinPortsGuide/Chap01
DarwinPortsGuide/Chap01Sec02
DarwinPortsGuide/Chap01Sec03
DarwinPortsGuide/Chap01Sec04
DarwinPortsGuide/Chap01Sec05
DarwinPortsGuide/Chap02
DarwinPortsGuide/Chap02Sec02
DarwinPortsGuide/Chap02Sec03
DarwinPortsGuide/Chap02Sec04
DarwinPortsGuide/Chap03
DarwinPortsGuide/Chap03Sec02
DarwinPortsGuide/Chap03Sec03
DarwinPortsGuide/Chap03Sec04
DarwinPortsGuide/Chap03Sec05
DarwinPortsGuide/Chap03Sec06
DarwinPortsGuide/Chap03Sec07
DarwinPortsGuide/Chap03Sec08
DarwinPortsGuide/Chap04
DarwinPortsGuide/Chap04Sec02
DarwinPortsGuide/Chap04Sec03
DarwinPortsGuide/Chap04Sec04
DarwinPortsGuide/Chap04Sec05
DarwinPortsGuide/Chap04Sec06
DarwinPortsGuide/Chap04Sec07
DarwinPortsGuide/Chap04Sec08
DarwinPortsGuide/Chap04Sec09
DarwinPortsGuide/Chap04Sec10
DarwinPortsGuide/Chap04Sec11
DarwinPortsGuide/Chap04Sec12
DarwinPortsGuide/Chap04Sec13
DarwinPortsGuide/Chap04Sec14
DarwinPortsGuide/Chap04Sec15
DarwinPortsGuide/Chap04Sec16
DarwinPortsGuide/Intro
DarwinPortsGuide/Part1
DarwinPortsGuide/Part2
FormattingRules
FrontPage
HowTo
HowTo/ContributeToDevelopment
HowTo/LocalPortfile
HowTo/PrivatePortfileTutorial
HowTo/TermsList
HowTo/UseMacPorts
HowTo/UseSVNRepository
HowTo/日本語環境構築
InterWiki
InterWikiName
InterWikiSandBox
InterWikiテクニカル
Links
MacPorts
MacPortsWiki-JP を SourceForge.jp へ移したい
MacPortsWikiNews
Man
Man/1Port
Man/5Macports.conf
Man/7Portfile
MenuBar
OpenDarwin
PHP
PrivatePortfile
PrivatePortfile/Anthy
PrivatePortfile/AnthySS
PrivatePortfile/Apel
PrivatePortfile/AspellDictId
PrivatePortfile/CMigemo
PrivatePortfile/CTags
PrivatePortfile/Cinepaint
PrivatePortfile/CompFace
PrivatePortfile/DdSkk
PrivatePortfile/ExifTran
PrivatePortfile/Howm
PrivatePortfile/ImageMagick
PrivatePortfile/JaIpaFonts
PrivatePortfile/Kasumi
PrivatePortfile/MacVim
PrivatePortfile/MixfontMplusIpaTrueType
PrivatePortfile/Navi2ch
PrivatePortfile/Rast
PrivatePortfile/RawStudio
PrivatePortfile/Ruby
PrivatePortfile/Sary
PrivatePortfile/Senna
PrivatePortfile/Senna-MySQL5
PrivatePortfile/Senna-PostgreSQL81
PrivatePortfile/Senna-PostgreSQL82
PrivatePortfile/SkkJisyo
PrivatePortfile/Smultron-ja
PrivatePortfile/Trac-ja
PrivatePortfile/Vim
PrivatePortfile/Vim72
PrivatePortfile/XEmacsCarbon
PrivatePortfile/XmmsOSXPlugin
PrivatePortfile/Zsh-devel
PrivatePortfile/asterisk14
PrivatePortfile/clang-checker
PrivatePortfile/docdiff
PrivatePortfile/ecell
PrivatePortfile/emacs-devel
PrivatePortfile/gauche-kahua
PrivatePortfile/gonzui
PrivatePortfile/gpac
PrivatePortfile/groff
PrivatePortfile/href
PrivatePortfile/iTerm
PrivatePortfile/imaxima
PrivatePortfile/inplace
PrivatePortfile/lcov
PrivatePortfile/m17n-db
PrivatePortfile/m17n-lib
PrivatePortfile/namazu
PrivatePortfile/ocamlgsl
PrivatePortfile/prime
PrivatePortfile/prime-dict
PrivatePortfile/py-iconvcodec
PrivatePortfile/py-webkit2png
PrivatePortfile/qkc
PrivatePortfile/rb-gettext
PrivatePortfile/rb-progressbar
PrivatePortfile/rb-rabbit
PrivatePortfile/rb-rurima-ja
PrivatePortfile/rb-sary-ruby
PrivatePortfile/rb-starruby
PrivatePortfile/scim
PrivatePortfile/scim-anthy
PrivatePortfile/scim-m17n
PrivatePortfile/scim-skk
PrivatePortfile/suikyo
PrivatePortfile/uim
PrivatePortfile/uncrustify
PrivatePortfile/wiiremote
PrivatePortfile/ypsilon
PrivatePortfileCommitted/HyperEstraier
PrivatePortfileCommitted/LookUp
PrivatePortfileCommitted/MeCab
PrivatePortfileCommitted/QDBM
PrivatePortfileCommitted/ack
PrivatePortfileCommitted/eb
PrivatePortfileCommitted/eblook
PrivatePortfileCommitted/jnethack
PrivatePortfileCommitted/mediatomb
PrivatePortfileCommitted/rb-rdtool
PrivatePortfileCommitted/rmtrash
PrivatePortfileCommitted/wxMaxima
PrivatePortfileCommitted/wxd
PukiWiki
PukiWiki/1.4
PukiWiki/1.4/Manual
PukiWiki/1.4/Manual/Plugin
PukiWiki/1.4/Manual/Plugin/A-D
PukiWiki/1.4/Manual/Plugin/E-G
PukiWiki/1.4/Manual/Plugin/H-K
PukiWiki/1.4/Manual/Plugin/L-N
PukiWiki/1.4/Manual/Plugin/O-R
PukiWiki/1.4/Manual/Plugin/S-U
PukiWiki/1.4/Manual/Plugin/V-Z
RecentDeleted
SandBox
SpamList
Subversion 経由で PrivatePorts を配布したい
TheMacPortsWiki
TheMacPortsWiki/BuildPhases
TheMacPortsWiki/FAQ
TheMacPortsWiki/GetMacPortsSource
TheMacPortsWiki/InstallingMacPorts
TheMacPortsWiki/ProblemHotlist
TheMacPortsWiki/TracTicketing
TheMacPortsWiki/UsingMacPortsQuickStart
WikiEngines
WikiName
WikiWikiWeb
YukiWiki
ヘルプ
整形ルール
要望など
原文: [[InstallingMacPorts - MacPorts:http://trac.macports.org/wiki/InstallingMacPorts]]~ * MacPorts のインストール [#r2bfd479] #contents //= 1. Install Xcode Tools = ** 1. Xcode Tools をインストールする [#c01b8635] // 1. Download and install the latest version of [http://developer.apple.com/tools/xcode/ Xcode Tools] // —do not install an older version from the OS X 10.4 install disk // or some ports may fail to install. // 2. Run the binary installer. // 3. Click Customize, expand the Applications category // and click the checkbox beside X11 SDK to add it to the default items. // 4. Click Install to install Xcode Tools and the X11 SDK. + 最新版の [[Xcode Tools>http://developer.apple.com/jp/technology/tools.html]] を ダウンロードして、インストールします。~ OS X 10.4 のインストールディスクから古いバージョン〔の Xcode Tools〕をインストールしないでください。 いくつかの ports で、インストールに失敗する場合があります。 + バイナリ・インストーラを起動します。 + 〔インストールの過程で〕Custamize をクリックします。 Applications category を展開して X11 SDK の横のチェックボックスにチェックを入れ、 デフォルト・アイテムに加えます。 + Install をクリックして、Xcode Tools と X11 SDK をインストールします。 //'''Notes:''' //Xcode Tools is neither installed nor updated via the Software Update utility. ''注意:'' Xcode Tools は、ソフトウェア・アップデート経由ではインストールもアップデートもされません。 //= 2. Install XWindows (X11) = ** 2. X Window (X11) をインストールする [#n6003ad4] //On OS X 10.4, Apple's X11 is an optional install //(MacPorts' X11 package is not recommended at this time). //If the application X11 is not present in /Applications/Utilities: OS X 10.4 では、アップルの X11 は追加インストールしなければなりません (現時点では、MacPorts の X11 パッケージは推奨されません)。~ もし、/アプリケーション/ユーティリティ(/Applications/Utilities)に X11 というアプリケーションがなければ、以下の手順で X11 をインストールしてください。 // 1. Insert the "Mac OS X Install Disk 1" and run the package named "Optional Installs". // 2. At the software selection window expand the Applications categoty // and click the checkbox beside X11 (and nothing else). // 3. Click Install to install X11. // 4. Drag the /Applications/Utilities/X11 icon to your dock // —you must open X11 before launching an X11 application. + インストールディスク "Mac OS X Install Disk 1" を挿入して、 "Optional Installs" という名前のパッケージを実行します。 + ソフトウェア選択画面で Application category を展開して、 X11(これだけです)の横のチェックボックスにチェックを入れます。 + Install をクリックして、X11 をインストールします。 + /アプリケーション/ユーティリティ/X11(/Applications/Utilities/X11)の アイコンをドックにドラッグ〔登録〕します。~ これは、X11 アプリケーションを起動する前に X11 を開いておく必要があるためです。 //'''Notes:''' // * XWindows (X11) is required for many MacPorts apps // and it is highly recommended that you install it // even if you don't plan to run X11 apps immediately. // * The X11SDK is also required to run X11 software, // but it is installed by default during the Xcode Tools install above. // If you wish to check to see if X11 (X11User) and X11SDK are installed, // look in /Library/Receipts for the files ''X11User.pkg'' and ''X11SDK.pkg''. // * OS X 10.3 users can optionally get the X11 software // from the [http://www.apple.com/support/downloads/x11formacosx.html Apple] download site. ''注意:'' - X Window (X11) は、多くの MacPorts アプリケーションが必要としますので、 X11 アプリケーションをすぐに利用する予定がなくても、インストールしておくことを強くお勧めします。 - X11 SDK もまた、X11 ソフトウェアを実行するのに必要とされますが、 これは上記の Xcode Tools をインストールする際にデフォルトでインストールされます。~ X11 (X11User) と X11 SDK がインストールされているかどうかを確認したい場合は、 /ライブラリ/Receipts (/Library/Receipts) フォルダ内で '''X11User.pkg''' と '''X11SDK.pkg''' というファイルを探してください。 - OS X 10.3 ユーザは、[[Apple>http://support.apple.com/downloads/X11_for_Mac_OS_X_1_0]] ダウンロードサイトから X11 ソフトウェアを別途入手できます。 //= 3. Set the shell environment = ** 3. シェル環境を設定する [#q3fe6d8f] //Setting the Unix shell environment is critical for MacPorts to function. MacPorts を機能させるためには、Unix シェル環境の設定が重要になります。 //== Requirements for the MacPorts' shell environment == *** MacPorts に必要なシェル環境 [#bbdcf566] //The MacPorts binary installer places a .profile file in your home directory // (view files preceded by a dot with 'ls -a'). // The contents of this ''~/.profile'' file adds the MacPorts paths // in front of the standard Unix paths for the default BASH shell. // This is done so that if you have utilities or libraries // from both MacPorts and OS X's standard install, // the MacPorts libraries will be run instead of the ones provided by Apple. MacPorts のバイナリ・インストーラは、.profile というファイルを あなたのホーム・ディレクトリに置きます (ドットで始まるファイルは 'ls -a' で見られます)。~ この '''~/.profile''' というファイルに書かれた MacPorts のパスが、 デフォルトの BASH シェルが利用する標準の Unix のパスの前に加えられます。~ これによって、〔同じ名前の〕ユーティリティやライブラリが MacPorts と OS X の通常インストールのそれぞれに存在した場合に、 アップルによって提供されたものではなく MacPorts のライブラリが動作するようになります。 //'''{{{export PATH=/opt/local/bin:/opt/local/sbin:$PATH}}}''' ''export PATH=/opt/local/bin:/opt/local/sbin:$PATH'' //You'll need to add this variable to your ''~/.profile'' to run X11 applications: X11 アプリケーションを動作させるために、'''~/.profile''' に以下の変数を加える必要があります。 //'''{{{export DISPLAY=:0.0}}}''' ''export DISPLAY=:0.0'' //So a basic ''~/.profile'' file will look like this: //{{{ //export PATH=/opt/local/bin:/opt/local/sbin:$PATH //export DISPLAY=:0.0 //}}} 以上から、基本的な '''~/.profile''' ファイルは以下のようになります。 export PATH=/opt/local/bin:/opt/local/sbin:$PATH export DISPLAY=:0.0 //'''Important Notes:''' ''重要な注意:'' // * To understand why MacPorts libraries are often installed when Apple has provided one, // see section "Why is MacPorts using its own libraries?" in the [wiki:FAQ]. // * Changes to ~/.profile do not take effect on the current shell session // — they take effect on new sessions so open a new shell session // and type 'env' to see the path and variable changes. // * Other profile files may take precedence over ~/.profile. // If you are using one of the following profile files in your home directory, // you will need to merge the contents of it into ~./profile, or vice versa // because the shell will ignore one of them: // * ''~/.bash_login'' // * ''~/.bash_profile'' - なぜアップルが提供しているライブラリを MacPorts が再度インストールすることがよくあるのかを理解するには、 [[FAQ>TheMacPortsWiki/FAQ]] の "どうして、MacPorts は自前のライブラリを使っているの?" というセクションを読んでください。 - ∼/.profile への変更は、実行中のシェル・セッションには適用されず、新しいセッションにおいて適用されます。~ パスや変数の変更を確認するには、新しいシェル・セッションを開いて、'env' とタイプしてください。 - 他の profile ファイルが、~/.profile よりも優先されることがあります。~ 以下の profile ファイルがホーム・ディレクトリにある場合は、 その内容を ~/.profile にマージするか、あるいはその逆のことをしてください。 シェルがそれらの一つを無視するからです。 -- '''~/.bash_login''' -- '''~/.bash_profile''' //== Verify the shell environment == *** シェル環境の検証 [#p7d5cd40] //To verify that your ~/.profile has set your shell environment: ~~/.profile がシェル環境を設定したことを検証するには、 // 1. Open a new terminal window // 2. Type the command: {{{env}}} + 新しくターミナル・ウィンドウを開きます。 + ''env'' というコマンドを打ちます。~ //Check to make sure the reported path begins with the MacPorts' paths as show above. 表示されたパスが、上記の MacPorts のパスで始まっていることを確認してください。 //Sample output of command {{{env}}}: //{{{ //TERM_PROGRAM=Apple_Terminal //TERM=xterm-color //SHELL=/bin/bash //TERM_PROGRAM_VERSION=133 //USER=mduling //__CF_USER_TEXT_ENCODING=0x1F6:0:0 //PATH=/opt/local/bin:/opt/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin //}}} ''env'' コマンドの出力サンプル: TERM_PROGRAM=Apple_Terminal TERM=xterm-color SHELL=/bin/bash TERM_PROGRAM_VERSION=133 USER=mduling __CF_USER_TEXT_ENCODING=0x1F6:0:0 PATH=/opt/local/bin:/opt/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin //== Options for the MacPorts' shell and X11 environment == *** MacPorts のシェルおよび X11 環境のオプション [#y6f868a8] //To set a default editor for use with the port command (e. g. 'port ed mysql5'), // add a variable EDITOR with the path of your favorite editor to the ''~/.profile'' file. port コマンド(例えば 'port ed musql5')と共に用いるデフォルトのエディタを 設定するには、~/.profile ファイルに好みのエディタへのパスを EDITOR 変数として追加してください。 //'''{{{export EDITOR=/usr/bin/pico}}}''' export EDITOR=/usr/bin/pico //A sample ''~/.profile'' with optional EDITOR variable set: //{{{ //export PATH=/opt/local/bin:/opt/local/sbin:$PATH //export DISPLAY=:0.0 //export EDITOR=/usr/bin/pico //}}} EDITOR 変数を設定した ''' ~/.prifile''' のサンプル: export PATH=/opt/local/bin:/opt/local/sbin:$PATH export DISPLAY=:0.0 export EDITOR=/usr/bin/pico //To launch X11 apps directly from an X11 window (instead of a terminal window), // you need to have the MacPorts paths imported into X11 sessions when they are opened. // This is a two step process. X11 アプリケーションを(ターミナル・ウィンドウからではなく)X11 window から直接立ち上げるには、 X11 セッション起動時に、MacPorts のパスを取り込む必要があります。 これには2段階の手順があります。 //First, tell X11 about your .profile file by editing the file // /etc/X11/xinit/xinitrc and add this line near the top. //{{{ //source ~/.profile //}}} まず、/etc/X11/xinit/xinitrc ファイルの始めの方に以下の行を追加し、 X11 にあなたの .profile ファイルを認識させます。 source ~/.profile //Now finish by making any subsequent X11 sessions opened using the menubar respect your .profile. そして、今後はあなたの .profile を反映して X11 セッションが開始されるように設定すれば完了です。 // 1. Open X11 and select "Customize Menu ..." from the Applications menu. // 2. Double-click the menu item "Terminal" and change: '''xterm''' to '''xterm -ls''' // 3. Click "Done" to save the change. + X11 を立ち上げ、Applications メニューから "Customize Menu ..." を選択します。 + "Terminal" というメニュー・アイテムをダブルクリックし、''xterm'' を ''xterm -ls'' に変更します。 + "Done" をクリックして変更を保存します。 //= 4. Install MacPorts = ** 4. MacPorts のインストール [#e108b72e] //=== Install MacPorts using the binary installer (to /opt/local/ only) === *** バイナリ・インストーラを用いて MacPorts をインストールする(/opt/local/ へのインストールのみ) [#xe7750da] // 1. Download the latest MacPorts .dmg disk image, currently [http://svn.macports.org/repository/macports/downloads/MacPorts-1.6.0/ version 1.6.0]. // 2. Run the binary installer. // 3. Perform the default “easy” install. + 最新の MacPorts の .dmg ディスク・イメージをダウンロードします。最新版は [[version 1.7.0>http://svn.macports.org/repository/macports/downloads/MacPorts-1.7.0/]] です。~ 〔Leopard では MacPorts-1.7.0-10.5-Leopard.dmg を、Tiger では MacPorts-1.7.0-10.4-Tiger.dmg を、Panther 以前では MacPorts-1.7.0-10.3-Panther.dmg を利用してください。〕 + バイナリ・インストーラを起動します。 + デフォルトの "easy" インストールを行います。 //'''Note:''' // * A MacPorts' selfupdate (see below) will automatically update to the latest release // if the binary .dmg image is behind the latest released tarball. ''注意:'' - バイナリが最新版ではない場合、MacPorts の [[selfupdate(下記参照)>#bbacefe5]]を実行すると、自動的に最新版にアップデートされます。 //=== Install MacPorts from source (to any path except /usr/local/) === *** MacPorts をソースからインストールする(/usr/local/ を除くあらゆるパスにインストール可能) [#vde57ce1] // 1. Download and unzip the latest MacPorts tarball from the [http://svn.macports.org/repository/macports/downloads/ MacPorts download area]. // 2. Perform these commands in a terminal window. //{{{ //cd ~/MacPorts-1.6.0/ //./configure --enable-readline //make //sudo make install //}}} + [[MacPorts のダウンロード・エリア>http://svn.macports.org/repository/macports/downloads/]]から最新の MacPorts の tarball をダウンロードし、展開します。 + ターミナルウィンドウで以下のコマンドを実行します。 cd ~/MacPorts-1.7.0/ ./configure --enable-readline make sudo make install //'''Note:''' // * To see why /usr/local is not a viable install location for MacPorts, see the [http://trac.macosforge.org/projects/macports/wiki/FAQ MacPorts FAQ] ''注意:'' - /usr/local に MacPorts をインストールしない理由については、 [[FAQ>TheMacPortsWiki/FAQ]] を参照してください。 //=== Install MacPorts from source as an unprivileged (non-root) user === *** MacPorts を管理者権限のない(non-root)ユーザとしてソースからインストールする [#v2296165] //If you don't have root on your machine, // or if you just prefer to install packages without becoming root, // the following steps will install MacPorts into ~/macports (tested on Leopard and Tiger). あなたがマシンの root 権限を持っていない場合や、root にならずにパッケージをインストールしたい場合は、 以下の手順で ~/macports に MacPorts をインストールしてください(Leopard と Tiger で検証済み)。 // * Download the source as bzip2 tarball from [http://svn.macports.org/repository/macports/downloads/ MacPorts download area] - [[MacPorts のダウンロード・エリア>http://svn.macports.org/repository/macports/downloads/]] から bzip2 tarball のソースをダウンロードします。 // * Run the following //{{{ // tar -jxf MacPorts-1.6.0.tar.bz2 && cd MacPorts-1.6.0 //}}} - 以下を実行します。 tar -jxf MacPorts-1.7.0.tar.bz2 && cd MacPorts-1.7.0 // * Note: For Leopard, you next need to apply the patch from http://trac.macports.org/changeset/32105. Then: - 注意:Leopard では、次に http://trac.macports.org/changeset/32105 のパッチを適用する必要があります〔訳注:version 1.6.0 ではこのパッチが必要でしたが、version 1.7.0 ではすでにパッチ適用済みのため、必要ありません〕。~ その後、以下を実行します。 //{{{ // PATH=/usr/bin:/usr/sbin:/bin:/sbin ./configure \ // --prefix=$HOME/macports \ // --enable-readline \ // --with-install-user=`id -un` \ // --with-install-group=`id -gn` \ // --x-includes=/usr/X11R6/include \ // --x-libraries=/usr/X11R6/lib \ // --with-tclpackage=$HOME/macports/share/macports/Tcl // // make // make install //}}} PATH=/usr/bin:/usr/sbin:/bin:/sbin ./configure \ --prefix=$HOME/macports \ --enable-readline \ --with-install-user=`id -un` \ --with-install-group=`id -gn` \ --x-includes=/usr/X11R6/include \ --x-libraries=/usr/X11R6/lib \ --with-tclpackage=$HOME/macports/share/macports/Tcl make make install // * Add something like the following to your Mac's ".bashrc": //{{{ // export PATH=$HOME/macports/bin:$HOME/macports/sbin:$PATH // export MANPATH=$HOME/macports/share/man:$MANPATH // export PERL5LIB=$HOME/macports/lib/perl5/5.8.8:$HOME/macports/lib/perl5/vendor_perl/5.8.8:$PERL5LIB //}}} - あなたの Mac の .bashrc に、以下のように追加します。 export PATH=$HOME/macports/bin:$HOME/macports/sbin:$PATH export MANPATH=$HOME/macports/share/man:$MANPATH export PERL5LIB=$HOME/macports/lib/perl5/5.8.8: \ $HOME/macports/lib/perl5/vendor_perl/5.8.8:$PERL5LIB //Note: ''do not'' set MANPATH here unless you have already set it elsewhere (or are running Leopard, which does so). // If you have not set MANPATH in another place, // and are running Tiger or earlier, omit the MANPATH line. // For more information about setting up the shell environment variables correctly, // please see [http://guide.macports.org/#installing.shell the Guide]. 注意:すでにどこか他の場所に MANPATH を設定している場合(または Leopard を利用している場合)を除き、ここに MANPATH を設定 '''しないで''' ください。~ もし他の場所に MANPATH を設定しておらず、かつ Tiger 以前を利用している場合は、MANPATH 行を省略します。~ 正しいシェル環境変数の設定についての詳細は、[[the Guide>http://guide.macports.org/#installing.shell]] (外部リンク・英語) を参照してください。 //Most ports install just fine unless they try to add themselves to the LaunchD // (e.g. most services, but you'd need root for most of them anyhow). // If you do run into a required port that tries to add itself as a startup item, // you can edit the Portfile (e.g. {{{port edit <portname>}}}) // and change {{{startupitem.create yes}}} to {{{startupitem.create no}}} ほとんどの ports は、上記を追加しなくても問題なく launchd にインストールできます (例えばほとんどのサービスは。しかし、いずれにせよ root 権限が必要になるでしょう)。 もし port を手動でスタートアップ・アイテムに加えたい場合は、 Portfile(例えば ''port edit <portname>'')の ''startupitem.create yes'' を ''startupitem.create no'' に変更します。 //=== Install MacPorts from a developer release === *** MacPorts をデベロッパー・リリースからインストールする [#x751d720] //Under construction. 工事中。 //'''Note:''' Developer releases contain untested code and may have bugs. Use at your own risk. ''注意:'' デベロッパー・リリースは未検証のコードを含み、バグがあるかもしれません。自己責任で利用してください。 //= 5. Update MacPorts via selfupdate = ** 5. MacPorts を selfupdate でアップデートする [#bbacefe5] //The 'port selfupdate' command must be run after a new MacPorts install, and frequently thereafter. // The command updates MacPorts with the latest port revisions, // and, if necessary, updates MacPorts to the latest release. 新規に MacPorts をインストールしたあと、そして今後も頻繁に、'port selfupdate' コマンドを実行しなければなりません。~ このコマンドは、MacPorts の最新のポート・リビジョンにアップデートし、 必要であれば MacPorts を最新のリリースにアップデートします。 // 1. Open a terminal window. // 2. Execute the MacPorts {{{selfupdate}}} command. + ターミナル・ウィンドウを開きます。 + MacPorts の ''selfupdate'' コマンドを実行します。 //{{{ //sudo port selfupdate //}}} //or for verbose output: //{{{ //sudo port -d selfupdate //}}} sudo port selfupdate もしくは、詳細を出力させたい方は、 sudo port -d selfupdate #br #hr #br - Xcode Toolsで「X11 SDKの横のチェックボックスをクリック」とありますが、選択できません。先に、X11をインストールしていれば、Xcode Toolsで「X11 SDK -- &new{2007-09-08 (土) 03:30:32}; - 先に、X11をインストールしていれば、Xcode Toolsで「X11 SDK -- &new{2007-09-08 (土) 03:31:28}; - 入力ミスしてしまい、すみません。先に、X11をインストールしていれば、Xcode ToolsのデフォルトインストールでX11 SDKもチェックされていました。 -- &new{2007-09-08 (土) 03:32:25}; #comment_nospam
タイムスタンプを変更しない
原文: [[InstallingMacPorts - MacPorts:http://trac.macports.org/wiki/InstallingMacPorts]]~ * MacPorts のインストール [#r2bfd479] #contents //= 1. Install Xcode Tools = ** 1. Xcode Tools をインストールする [#c01b8635] // 1. Download and install the latest version of [http://developer.apple.com/tools/xcode/ Xcode Tools] // —do not install an older version from the OS X 10.4 install disk // or some ports may fail to install. // 2. Run the binary installer. // 3. Click Customize, expand the Applications category // and click the checkbox beside X11 SDK to add it to the default items. // 4. Click Install to install Xcode Tools and the X11 SDK. + 最新版の [[Xcode Tools>http://developer.apple.com/jp/technology/tools.html]] を ダウンロードして、インストールします。~ OS X 10.4 のインストールディスクから古いバージョン〔の Xcode Tools〕をインストールしないでください。 いくつかの ports で、インストールに失敗する場合があります。 + バイナリ・インストーラを起動します。 + 〔インストールの過程で〕Custamize をクリックします。 Applications category を展開して X11 SDK の横のチェックボックスにチェックを入れ、 デフォルト・アイテムに加えます。 + Install をクリックして、Xcode Tools と X11 SDK をインストールします。 //'''Notes:''' //Xcode Tools is neither installed nor updated via the Software Update utility. ''注意:'' Xcode Tools は、ソフトウェア・アップデート経由ではインストールもアップデートもされません。 //= 2. Install XWindows (X11) = ** 2. X Window (X11) をインストールする [#n6003ad4] //On OS X 10.4, Apple's X11 is an optional install //(MacPorts' X11 package is not recommended at this time). //If the application X11 is not present in /Applications/Utilities: OS X 10.4 では、アップルの X11 は追加インストールしなければなりません (現時点では、MacPorts の X11 パッケージは推奨されません)。~ もし、/アプリケーション/ユーティリティ(/Applications/Utilities)に X11 というアプリケーションがなければ、以下の手順で X11 をインストールしてください。 // 1. Insert the "Mac OS X Install Disk 1" and run the package named "Optional Installs". // 2. At the software selection window expand the Applications categoty // and click the checkbox beside X11 (and nothing else). // 3. Click Install to install X11. // 4. Drag the /Applications/Utilities/X11 icon to your dock // —you must open X11 before launching an X11 application. + インストールディスク "Mac OS X Install Disk 1" を挿入して、 "Optional Installs" という名前のパッケージを実行します。 + ソフトウェア選択画面で Application category を展開して、 X11(これだけです)の横のチェックボックスにチェックを入れます。 + Install をクリックして、X11 をインストールします。 + /アプリケーション/ユーティリティ/X11(/Applications/Utilities/X11)の アイコンをドックにドラッグ〔登録〕します。~ これは、X11 アプリケーションを起動する前に X11 を開いておく必要があるためです。 //'''Notes:''' // * XWindows (X11) is required for many MacPorts apps // and it is highly recommended that you install it // even if you don't plan to run X11 apps immediately. // * The X11SDK is also required to run X11 software, // but it is installed by default during the Xcode Tools install above. // If you wish to check to see if X11 (X11User) and X11SDK are installed, // look in /Library/Receipts for the files ''X11User.pkg'' and ''X11SDK.pkg''. // * OS X 10.3 users can optionally get the X11 software // from the [http://www.apple.com/support/downloads/x11formacosx.html Apple] download site. ''注意:'' - X Window (X11) は、多くの MacPorts アプリケーションが必要としますので、 X11 アプリケーションをすぐに利用する予定がなくても、インストールしておくことを強くお勧めします。 - X11 SDK もまた、X11 ソフトウェアを実行するのに必要とされますが、 これは上記の Xcode Tools をインストールする際にデフォルトでインストールされます。~ X11 (X11User) と X11 SDK がインストールされているかどうかを確認したい場合は、 /ライブラリ/Receipts (/Library/Receipts) フォルダ内で '''X11User.pkg''' と '''X11SDK.pkg''' というファイルを探してください。 - OS X 10.3 ユーザは、[[Apple>http://support.apple.com/downloads/X11_for_Mac_OS_X_1_0]] ダウンロードサイトから X11 ソフトウェアを別途入手できます。 //= 3. Set the shell environment = ** 3. シェル環境を設定する [#q3fe6d8f] //Setting the Unix shell environment is critical for MacPorts to function. MacPorts を機能させるためには、Unix シェル環境の設定が重要になります。 //== Requirements for the MacPorts' shell environment == *** MacPorts に必要なシェル環境 [#bbdcf566] //The MacPorts binary installer places a .profile file in your home directory // (view files preceded by a dot with 'ls -a'). // The contents of this ''~/.profile'' file adds the MacPorts paths // in front of the standard Unix paths for the default BASH shell. // This is done so that if you have utilities or libraries // from both MacPorts and OS X's standard install, // the MacPorts libraries will be run instead of the ones provided by Apple. MacPorts のバイナリ・インストーラは、.profile というファイルを あなたのホーム・ディレクトリに置きます (ドットで始まるファイルは 'ls -a' で見られます)。~ この '''~/.profile''' というファイルに書かれた MacPorts のパスが、 デフォルトの BASH シェルが利用する標準の Unix のパスの前に加えられます。~ これによって、〔同じ名前の〕ユーティリティやライブラリが MacPorts と OS X の通常インストールのそれぞれに存在した場合に、 アップルによって提供されたものではなく MacPorts のライブラリが動作するようになります。 //'''{{{export PATH=/opt/local/bin:/opt/local/sbin:$PATH}}}''' ''export PATH=/opt/local/bin:/opt/local/sbin:$PATH'' //You'll need to add this variable to your ''~/.profile'' to run X11 applications: X11 アプリケーションを動作させるために、'''~/.profile''' に以下の変数を加える必要があります。 //'''{{{export DISPLAY=:0.0}}}''' ''export DISPLAY=:0.0'' //So a basic ''~/.profile'' file will look like this: //{{{ //export PATH=/opt/local/bin:/opt/local/sbin:$PATH //export DISPLAY=:0.0 //}}} 以上から、基本的な '''~/.profile''' ファイルは以下のようになります。 export PATH=/opt/local/bin:/opt/local/sbin:$PATH export DISPLAY=:0.0 //'''Important Notes:''' ''重要な注意:'' // * To understand why MacPorts libraries are often installed when Apple has provided one, // see section "Why is MacPorts using its own libraries?" in the [wiki:FAQ]. // * Changes to ~/.profile do not take effect on the current shell session // — they take effect on new sessions so open a new shell session // and type 'env' to see the path and variable changes. // * Other profile files may take precedence over ~/.profile. // If you are using one of the following profile files in your home directory, // you will need to merge the contents of it into ~./profile, or vice versa // because the shell will ignore one of them: // * ''~/.bash_login'' // * ''~/.bash_profile'' - なぜアップルが提供しているライブラリを MacPorts が再度インストールすることがよくあるのかを理解するには、 [[FAQ>TheMacPortsWiki/FAQ]] の "どうして、MacPorts は自前のライブラリを使っているの?" というセクションを読んでください。 - ∼/.profile への変更は、実行中のシェル・セッションには適用されず、新しいセッションにおいて適用されます。~ パスや変数の変更を確認するには、新しいシェル・セッションを開いて、'env' とタイプしてください。 - 他の profile ファイルが、~/.profile よりも優先されることがあります。~ 以下の profile ファイルがホーム・ディレクトリにある場合は、 その内容を ~/.profile にマージするか、あるいはその逆のことをしてください。 シェルがそれらの一つを無視するからです。 -- '''~/.bash_login''' -- '''~/.bash_profile''' //== Verify the shell environment == *** シェル環境の検証 [#p7d5cd40] //To verify that your ~/.profile has set your shell environment: ~~/.profile がシェル環境を設定したことを検証するには、 // 1. Open a new terminal window // 2. Type the command: {{{env}}} + 新しくターミナル・ウィンドウを開きます。 + ''env'' というコマンドを打ちます。~ //Check to make sure the reported path begins with the MacPorts' paths as show above. 表示されたパスが、上記の MacPorts のパスで始まっていることを確認してください。 //Sample output of command {{{env}}}: //{{{ //TERM_PROGRAM=Apple_Terminal //TERM=xterm-color //SHELL=/bin/bash //TERM_PROGRAM_VERSION=133 //USER=mduling //__CF_USER_TEXT_ENCODING=0x1F6:0:0 //PATH=/opt/local/bin:/opt/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin //}}} ''env'' コマンドの出力サンプル: TERM_PROGRAM=Apple_Terminal TERM=xterm-color SHELL=/bin/bash TERM_PROGRAM_VERSION=133 USER=mduling __CF_USER_TEXT_ENCODING=0x1F6:0:0 PATH=/opt/local/bin:/opt/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin //== Options for the MacPorts' shell and X11 environment == *** MacPorts のシェルおよび X11 環境のオプション [#y6f868a8] //To set a default editor for use with the port command (e. g. 'port ed mysql5'), // add a variable EDITOR with the path of your favorite editor to the ''~/.profile'' file. port コマンド(例えば 'port ed musql5')と共に用いるデフォルトのエディタを 設定するには、~/.profile ファイルに好みのエディタへのパスを EDITOR 変数として追加してください。 //'''{{{export EDITOR=/usr/bin/pico}}}''' export EDITOR=/usr/bin/pico //A sample ''~/.profile'' with optional EDITOR variable set: //{{{ //export PATH=/opt/local/bin:/opt/local/sbin:$PATH //export DISPLAY=:0.0 //export EDITOR=/usr/bin/pico //}}} EDITOR 変数を設定した ''' ~/.prifile''' のサンプル: export PATH=/opt/local/bin:/opt/local/sbin:$PATH export DISPLAY=:0.0 export EDITOR=/usr/bin/pico //To launch X11 apps directly from an X11 window (instead of a terminal window), // you need to have the MacPorts paths imported into X11 sessions when they are opened. // This is a two step process. X11 アプリケーションを(ターミナル・ウィンドウからではなく)X11 window から直接立ち上げるには、 X11 セッション起動時に、MacPorts のパスを取り込む必要があります。 これには2段階の手順があります。 //First, tell X11 about your .profile file by editing the file // /etc/X11/xinit/xinitrc and add this line near the top. //{{{ //source ~/.profile //}}} まず、/etc/X11/xinit/xinitrc ファイルの始めの方に以下の行を追加し、 X11 にあなたの .profile ファイルを認識させます。 source ~/.profile //Now finish by making any subsequent X11 sessions opened using the menubar respect your .profile. そして、今後はあなたの .profile を反映して X11 セッションが開始されるように設定すれば完了です。 // 1. Open X11 and select "Customize Menu ..." from the Applications menu. // 2. Double-click the menu item "Terminal" and change: '''xterm''' to '''xterm -ls''' // 3. Click "Done" to save the change. + X11 を立ち上げ、Applications メニューから "Customize Menu ..." を選択します。 + "Terminal" というメニュー・アイテムをダブルクリックし、''xterm'' を ''xterm -ls'' に変更します。 + "Done" をクリックして変更を保存します。 //= 4. Install MacPorts = ** 4. MacPorts のインストール [#e108b72e] //=== Install MacPorts using the binary installer (to /opt/local/ only) === *** バイナリ・インストーラを用いて MacPorts をインストールする(/opt/local/ へのインストールのみ) [#xe7750da] // 1. Download the latest MacPorts .dmg disk image, currently [http://svn.macports.org/repository/macports/downloads/MacPorts-1.6.0/ version 1.6.0]. // 2. Run the binary installer. // 3. Perform the default “easy” install. + 最新の MacPorts の .dmg ディスク・イメージをダウンロードします。最新版は [[version 1.7.0>http://svn.macports.org/repository/macports/downloads/MacPorts-1.7.0/]] です。~ 〔Leopard では MacPorts-1.7.0-10.5-Leopard.dmg を、Tiger では MacPorts-1.7.0-10.4-Tiger.dmg を、Panther 以前では MacPorts-1.7.0-10.3-Panther.dmg を利用してください。〕 + バイナリ・インストーラを起動します。 + デフォルトの "easy" インストールを行います。 //'''Note:''' // * A MacPorts' selfupdate (see below) will automatically update to the latest release // if the binary .dmg image is behind the latest released tarball. ''注意:'' - バイナリが最新版ではない場合、MacPorts の [[selfupdate(下記参照)>#bbacefe5]]を実行すると、自動的に最新版にアップデートされます。 //=== Install MacPorts from source (to any path except /usr/local/) === *** MacPorts をソースからインストールする(/usr/local/ を除くあらゆるパスにインストール可能) [#vde57ce1] // 1. Download and unzip the latest MacPorts tarball from the [http://svn.macports.org/repository/macports/downloads/ MacPorts download area]. // 2. Perform these commands in a terminal window. //{{{ //cd ~/MacPorts-1.6.0/ //./configure --enable-readline //make //sudo make install //}}} + [[MacPorts のダウンロード・エリア>http://svn.macports.org/repository/macports/downloads/]]から最新の MacPorts の tarball をダウンロードし、展開します。 + ターミナルウィンドウで以下のコマンドを実行します。 cd ~/MacPorts-1.7.0/ ./configure --enable-readline make sudo make install //'''Note:''' // * To see why /usr/local is not a viable install location for MacPorts, see the [http://trac.macosforge.org/projects/macports/wiki/FAQ MacPorts FAQ] ''注意:'' - /usr/local に MacPorts をインストールしない理由については、 [[FAQ>TheMacPortsWiki/FAQ]] を参照してください。 //=== Install MacPorts from source as an unprivileged (non-root) user === *** MacPorts を管理者権限のない(non-root)ユーザとしてソースからインストールする [#v2296165] //If you don't have root on your machine, // or if you just prefer to install packages without becoming root, // the following steps will install MacPorts into ~/macports (tested on Leopard and Tiger). あなたがマシンの root 権限を持っていない場合や、root にならずにパッケージをインストールしたい場合は、 以下の手順で ~/macports に MacPorts をインストールしてください(Leopard と Tiger で検証済み)。 // * Download the source as bzip2 tarball from [http://svn.macports.org/repository/macports/downloads/ MacPorts download area] - [[MacPorts のダウンロード・エリア>http://svn.macports.org/repository/macports/downloads/]] から bzip2 tarball のソースをダウンロードします。 // * Run the following //{{{ // tar -jxf MacPorts-1.6.0.tar.bz2 && cd MacPorts-1.6.0 //}}} - 以下を実行します。 tar -jxf MacPorts-1.7.0.tar.bz2 && cd MacPorts-1.7.0 // * Note: For Leopard, you next need to apply the patch from http://trac.macports.org/changeset/32105. Then: - 注意:Leopard では、次に http://trac.macports.org/changeset/32105 のパッチを適用する必要があります〔訳注:version 1.6.0 ではこのパッチが必要でしたが、version 1.7.0 ではすでにパッチ適用済みのため、必要ありません〕。~ その後、以下を実行します。 //{{{ // PATH=/usr/bin:/usr/sbin:/bin:/sbin ./configure \ // --prefix=$HOME/macports \ // --enable-readline \ // --with-install-user=`id -un` \ // --with-install-group=`id -gn` \ // --x-includes=/usr/X11R6/include \ // --x-libraries=/usr/X11R6/lib \ // --with-tclpackage=$HOME/macports/share/macports/Tcl // // make // make install //}}} PATH=/usr/bin:/usr/sbin:/bin:/sbin ./configure \ --prefix=$HOME/macports \ --enable-readline \ --with-install-user=`id -un` \ --with-install-group=`id -gn` \ --x-includes=/usr/X11R6/include \ --x-libraries=/usr/X11R6/lib \ --with-tclpackage=$HOME/macports/share/macports/Tcl make make install // * Add something like the following to your Mac's ".bashrc": //{{{ // export PATH=$HOME/macports/bin:$HOME/macports/sbin:$PATH // export MANPATH=$HOME/macports/share/man:$MANPATH // export PERL5LIB=$HOME/macports/lib/perl5/5.8.8:$HOME/macports/lib/perl5/vendor_perl/5.8.8:$PERL5LIB //}}} - あなたの Mac の .bashrc に、以下のように追加します。 export PATH=$HOME/macports/bin:$HOME/macports/sbin:$PATH export MANPATH=$HOME/macports/share/man:$MANPATH export PERL5LIB=$HOME/macports/lib/perl5/5.8.8: \ $HOME/macports/lib/perl5/vendor_perl/5.8.8:$PERL5LIB //Note: ''do not'' set MANPATH here unless you have already set it elsewhere (or are running Leopard, which does so). // If you have not set MANPATH in another place, // and are running Tiger or earlier, omit the MANPATH line. // For more information about setting up the shell environment variables correctly, // please see [http://guide.macports.org/#installing.shell the Guide]. 注意:すでにどこか他の場所に MANPATH を設定している場合(または Leopard を利用している場合)を除き、ここに MANPATH を設定 '''しないで''' ください。~ もし他の場所に MANPATH を設定しておらず、かつ Tiger 以前を利用している場合は、MANPATH 行を省略します。~ 正しいシェル環境変数の設定についての詳細は、[[the Guide>http://guide.macports.org/#installing.shell]] (外部リンク・英語) を参照してください。 //Most ports install just fine unless they try to add themselves to the LaunchD // (e.g. most services, but you'd need root for most of them anyhow). // If you do run into a required port that tries to add itself as a startup item, // you can edit the Portfile (e.g. {{{port edit <portname>}}}) // and change {{{startupitem.create yes}}} to {{{startupitem.create no}}} ほとんどの ports は、上記を追加しなくても問題なく launchd にインストールできます (例えばほとんどのサービスは。しかし、いずれにせよ root 権限が必要になるでしょう)。 もし port を手動でスタートアップ・アイテムに加えたい場合は、 Portfile(例えば ''port edit <portname>'')の ''startupitem.create yes'' を ''startupitem.create no'' に変更します。 //=== Install MacPorts from a developer release === *** MacPorts をデベロッパー・リリースからインストールする [#x751d720] //Under construction. 工事中。 //'''Note:''' Developer releases contain untested code and may have bugs. Use at your own risk. ''注意:'' デベロッパー・リリースは未検証のコードを含み、バグがあるかもしれません。自己責任で利用してください。 //= 5. Update MacPorts via selfupdate = ** 5. MacPorts を selfupdate でアップデートする [#bbacefe5] //The 'port selfupdate' command must be run after a new MacPorts install, and frequently thereafter. // The command updates MacPorts with the latest port revisions, // and, if necessary, updates MacPorts to the latest release. 新規に MacPorts をインストールしたあと、そして今後も頻繁に、'port selfupdate' コマンドを実行しなければなりません。~ このコマンドは、MacPorts の最新のポート・リビジョンにアップデートし、 必要であれば MacPorts を最新のリリースにアップデートします。 // 1. Open a terminal window. // 2. Execute the MacPorts {{{selfupdate}}} command. + ターミナル・ウィンドウを開きます。 + MacPorts の ''selfupdate'' コマンドを実行します。 //{{{ //sudo port selfupdate //}}} //or for verbose output: //{{{ //sudo port -d selfupdate //}}} sudo port selfupdate もしくは、詳細を出力させたい方は、 sudo port -d selfupdate #br #hr #br - Xcode Toolsで「X11 SDKの横のチェックボックスをクリック」とありますが、選択できません。先に、X11をインストールしていれば、Xcode Toolsで「X11 SDK -- &new{2007-09-08 (土) 03:30:32}; - 先に、X11をインストールしていれば、Xcode Toolsで「X11 SDK -- &new{2007-09-08 (土) 03:31:28}; - 入力ミスしてしまい、すみません。先に、X11をインストールしていれば、Xcode ToolsのデフォルトインストールでX11 SDKもチェックされていました。 -- &new{2007-09-08 (土) 03:32:25}; #comment_nospam
テキスト整形のルールを表示する