PHP.mk документација

Инсталација

Почист и полокален преглед на PHP референцата, со задржана структура од PHP.net и подобра читливост за примери, секции и белешки.

gnupg.installation.php PHP.net прокси Преводот е вчитан
Оригинал на PHP.net
Патека gnupg.installation.php Локална патека за оваа страница.
Извор php.net/manual/en Оригиналниот HTML се реупотребува и локално се стилизира.
Режим Прокси + преведен приказ Кодовите, табелите и белешките остануваат читливи во истиот тек.
Инсталација

Референца за `gnupg.installation.php` со подобрена типографија и навигација.

gnupg.installation.php

Инсталација

repository and is no longer bundled with PHP as of PHP 8.4.0 Инсталација на PECL екстензииInformation for installing this PECL extension may be found in the manual chapter titled » https://pecl.php.net/package/gnupg.

Белешки од корисници 10 белешки

Г. Т
пред 4 години
On Ubuntu 20, this is provided via `php-gnupg` (or with a specific version `php8.1-gnupg`)

To install:

`apt install php-gnupg`
5spaceman
пред 2 години
To install on laravel sail:
<?php
sail publish
?>
Add to your Dockerfile:
<?php
    && apt-get update && apt-get upgrade -y \
    && apt-get install -y gcc-multilib libc-dev bzip2 libgpg-error-dev libassuan-dev \
    && apt-get install -y build-essential \
    && curl -sSn -o gnupg.tar.bz2 $GNUPG_URL \
    && mkdir gnupg \
    && tar -xf gnupg.tar.bz2 --directory gnupg \
    && (cd gnupg/gpgme-* && ./configure) \
    && (cd gnupg/gpgme-* && make && make install) \
    && pecl install gnupg 
?>
Add to your php.ini under [php]
<?php
extension=gnupg.so
?>
Finally:
<?php
sail build --no-cache
?>
Check you can see gnupg under modules when you run:
<?php
sail php -m
?>
Доминик Зомер
пред 13 години
For Ubuntu 12.04, these are the steps:
1. Install packages: gnupg libgpg-error-dev libassuan-dev
2. Download GPGME library from ​http://www.gnupg.org/download/index.en.html#gpgme
3. Extract, then run
   configure
   make && sudo make install
4. Install PECL extension
   sudo pecl install gnupg
5. Add to php.ini
   extension=gnupg.so
При успешно извршување, оваа функција враќа шифриран текст. При неуспех, оваа функција враќа
пред 11 години
I tried followings on Debian Squeeze and it worked fine

apt-get install libgpgme11-dev
pecl install gnupg

create a new file under conf.d folder and add following lines 

; configuration for gnupg module
extension=gnupg.so

Reload apache configuration
/etc/init.d/apache2 reload 

Check PHP Info and you should see gnupg

Hope this helps.
[email protected]
12 години пред
For the folks in Debian Wheezy who are having a bit of trouble
heres a link to to a .deb file ( I use it ) for amd64 users

http://users.on.net/~cam.metzke/Debian%20Packages/Wheezy/gnupg/PECL-gnupg/

Anyway I built it for the community, hope it helps :)
[email protected]
пред 17 години
Quick installation guide on Fedora 10:

Needed:
- c++ compiler
- php-pear
- gnupg
- libgpg-error
- gpgme
- gpgme-devel
- php-devel

Install with:
$ pecl install gnupg

Add an entry to /etc/php.ini:
extension=gnupg.so

Restart Apache > you're done.
[email protected]
пред 14 години
Here are instructions for how to resolve the issue where you encounter this error:

/usr/include/gpgme.h:80:2: error: #error GPGME was compiled with _FILE_OFFSET_BITS = 64, please see the section "Largefile support (LFS)" in the GPGME manual.

This is a result of the gnupg extension currently lacking largefile support. The solution is fairly simple.

pecl download gnupg
tar -zxf gnupg-1.3.2.tgz
cd gnupg-1.3.2

Open the file config.m4 in an editor, and add "AC_SYS_LARGEFILE" to a new line at the very end of the file, then save.

phpize
./configure
make
make install

Now simply add extension=gnupg.so to your php.ini, and the extension should work.
Џејн Доу
12 години пред
Hi - 

By default on Ubuntu 12.04 LTS gnupg needs to write to .gnupg in the home directory of the user running PHP (so for a web site this is www-data). You might need to make a ~/.gnupg for www-data and chown/chmod it correctly or everything will fail.
Хит
пред 15 години
On Debian 5.05 (Lenny) I needed to install libgpgme11-dev
[email protected]
пред 17 години
After spending so much time I could only install it on Linux and not Windows. There is very little instructions on the net about installation of this module, so I am going to write a small instructions that should help a straightforward installation on Linux without so much trouble.

Step 1: you will need a C++ compiler on your machine. For being sure try this command in the terminal:
<?php
sudo apt-get install g++
?>
Obviously you need GnuPG itself, so try:
<?php
sudo apt-get install gnupg
?>
Step 2: you will need "Libgpg-Error" downloaded and installed on your machine. 
2-1: Download the code from http://www.gnupg.org/download/#libgpg-error
2-2: Extract it to a directory. In the terminal, change the directory to the Libgpg-error directory.
2-3: Configure the package for building and installation with below command:
<?php
./configure
?>
2-4: In the same directory make it with below command:
<?php
sudo make
?>
2-5: In the same directory install it with below command:
<?php
sudo make install
?>

Step 3: you will need "GnuPG Made Easy" (GPGME) downloaded and installed on your machine. Some sources will tell you that you can "apt-get install" it, but actually you cannot. So do it like the latter:
3-1: Download the source code from http://www.gnupg.org/download/#gpgme
3-2: Extract it to a directory. In the terminal, change the directory to the GPGME directory.
3-3: Configure the package for building and installation with below command:
<?php
./configure
?>
3-4: In the same directory make it with below command:
<?php
sudo make
?>
3-5: In the same directory install it with below command:
<?php
sudo make install
?>

Step 4: Given that you have a LAMP server already and have php installed, you will need "pear" and "php source codes". To add them use below commands:
<?php
sudo apt-get install php5-dev
sudo apt-get install php-pear
?>

Step 5: Now you can install GNU Privacy Guard for php using PECL command:
<?php
 sudo pecl install gnupg
?>
На оваа страница

Автоматски outline од активната документација.

Насловите ќе се појават тука по вчитување.

Попрегледно читање

Примерите, changelog табелите и user notes се визуелно издвоени за да не се губат во долгата содржина.

Брз совет Користи го outline-от Скокни директно на главните секции од активната страница.
Извор Оригиналниот линк останува достапен Кога ти треба целосен upstream context, отвори го PHP.net во нов tab.