prog-install.rst
author Oleksandr Gavenko <gavenkoa@gmail.com>
Mon, 02 Mar 2009 21:04:37 +0200
changeset 42 2146aa2221c0
permissions -rw-r--r--
prog install
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
42
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     1
-*- mode: outline; coding: utf-8 -*-
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     2
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     3
* Linux.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     4
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     5
Вообще используем систему пакетов, но если в репозиториях дистрибутива нет
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     6
соотведствующего пакета см. рецепты ниже.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     7
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     8
** Без прав root.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     9
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    10
Лучшим решением, если у Вас нету прав root, будет установить ее в домашнем
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    11
каталоге. Тут дело личных предпочтений. У меня это ~/usr.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    12
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    13
Если программа в бинарном виде - просто распаковываем:
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    14
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    15
  $ cd /your/temp/dir
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    16
  $ gzip -d -c prog.tar.gz | tar xf -
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    17
  $ mv prog/* ~/usr
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    18
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    19
Если программу придестя собирать из исходников,
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    20
почти всегда можно указать ключ --prefix:
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    21
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    22
  $ configure --prefix=$HOME/usr
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    23
  $ make
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    24
  $ make install
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    25
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    26
Обычно run-инсталляторы разархивируют содержимое в $PWD/<prog-name>.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    27
В любом случае
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    28
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    29
  $ ./nvidia-driver-1.2.9.run --help
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    30
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    31
** С правами root.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    32
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    33
Если вы root то по Linux FHS ставим в /opt.
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    34
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    35
Смотри:
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    36
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    37
  http://en.wikipedia.org/wiki/Filesystem_Hierarchy_Standard
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    38
2146aa2221c0 prog install
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    39
Не забываем обновить переменную окружения PATH!