How to recompile PHP Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern) Come Celebrate our 10 Year Anniversary!How can I sort du -h output by sizeRecompile PHP *nixWhen I recompile Apache do I need to recompile PHP and recompile PHP's extensions?How do you restart php-fpm?How do I tell Git for Windows where to find my private RSA key?How to automate SSH login with password?Enable zip on PHP 5.1.6 without recompile“no input file specified” with apache/php after recompileDo you need to recompile PHP to use APC?How to correctly recompile PHP?

Multi tool use
Multi tool use

Fundamental Solution of the Pell Equation

How come Sam didn't become Lord of Horn Hill?

What's the meaning of "fortified infraction restraint"?

Do jazz musicians improvise on the parent scale in addition to the chord-scales?

If my PI received research grants from a company to be able to pay my postdoc salary, did I have a potential conflict interest too?

Circuit to "zoom in" on mV fluctuations of a DC signal?

Did MS DOS itself ever use blinking text?

What does this Jacques Hadamard quote mean?

Do wooden building fires get hotter than 600°C?

What causes the direction of lightning flashes?

Is it cost-effective to upgrade an old-ish Giant Escape R3 commuter bike with entry-level branded parts (wheels, drivetrain)?

Compare a given version number in the form major.minor.build.patch and see if one is less than the other

An adverb for when you're not exaggerating

How would a mousetrap for use in space work?

When the Haste spell ends on a creature, do attackers have advantage against that creature?

Withdrew £2800, but only £2000 shows as withdrawn on online banking; what are my obligations?

How can I use the Python library networkx from Mathematica?

Why aren't air breathing engines used as small first stages

Extracting terms with certain heads in a function

Significance of Cersei's obsession with elephants?

Generate an RGB colour grid

What would be the ideal power source for a cybernetic eye?

Why are there no cargo aircraft with "flying wing" design?

If a contract sometimes uses the wrong name, is it still valid?



How to recompile PHP



Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)
Come Celebrate our 10 Year Anniversary!How can I sort du -h output by sizeRecompile PHP *nixWhen I recompile Apache do I need to recompile PHP and recompile PHP's extensions?How do you restart php-fpm?How do I tell Git for Windows where to find my private RSA key?How to automate SSH login with password?Enable zip on PHP 5.1.6 without recompile“no input file specified” with apache/php after recompileDo you need to recompile PHP to use APC?How to correctly recompile PHP?



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








4















I have changed some settings in various things on my site and I am being told i need to "recompile PHP" via ssh.



can anybody tell me how to do that?



OOF, harsh - people wanna shut this one real fast.



Heres the situation. I have some nice preg_matches going on throughout my site, but the server I am on is throwing up errors left and right, complaining about my PCRE not being UTF-8 friendly.



After researching the problem, it seems the only way to make it friendly is by recompiling PHP with a few flags in the conditions.



And that is where I'm at.










share|improve this question















migrated from stackoverflow.com Jan 21 '10 at 6:59


This question came from our site for professional and enthusiast programmers.













  • 1





    Recompiling PHP is almost always a last resort. You need to talk more in detail about your situation in order to get at what you really need.

    – Ignacio Vazquez-Abrams
    Jan 21 '10 at 6:47











  • What OS? If it's a Linux distro, it's often easiest to start with the source package and modify it to add whatever extra options you need.

    – ZoogieZork
    Jan 21 '10 at 7:04











  • okay...so basically a fresh install?

    – johnnietheblack
    Jan 21 '10 at 7:06











  • Since you're modifying the source package for PHP, the result will be a new PHP package which you can use to install "over" your existing installation. This only works if PHP was originally installed via package, of course.

    – ZoogieZork
    Jan 21 '10 at 7:13

















4















I have changed some settings in various things on my site and I am being told i need to "recompile PHP" via ssh.



can anybody tell me how to do that?



OOF, harsh - people wanna shut this one real fast.



Heres the situation. I have some nice preg_matches going on throughout my site, but the server I am on is throwing up errors left and right, complaining about my PCRE not being UTF-8 friendly.



After researching the problem, it seems the only way to make it friendly is by recompiling PHP with a few flags in the conditions.



And that is where I'm at.










share|improve this question















migrated from stackoverflow.com Jan 21 '10 at 6:59


This question came from our site for professional and enthusiast programmers.













  • 1





    Recompiling PHP is almost always a last resort. You need to talk more in detail about your situation in order to get at what you really need.

    – Ignacio Vazquez-Abrams
    Jan 21 '10 at 6:47











  • What OS? If it's a Linux distro, it's often easiest to start with the source package and modify it to add whatever extra options you need.

    – ZoogieZork
    Jan 21 '10 at 7:04











  • okay...so basically a fresh install?

    – johnnietheblack
    Jan 21 '10 at 7:06











  • Since you're modifying the source package for PHP, the result will be a new PHP package which you can use to install "over" your existing installation. This only works if PHP was originally installed via package, of course.

    – ZoogieZork
    Jan 21 '10 at 7:13













4












4








4


1






I have changed some settings in various things on my site and I am being told i need to "recompile PHP" via ssh.



can anybody tell me how to do that?



OOF, harsh - people wanna shut this one real fast.



Heres the situation. I have some nice preg_matches going on throughout my site, but the server I am on is throwing up errors left and right, complaining about my PCRE not being UTF-8 friendly.



After researching the problem, it seems the only way to make it friendly is by recompiling PHP with a few flags in the conditions.



And that is where I'm at.










share|improve this question
















I have changed some settings in various things on my site and I am being told i need to "recompile PHP" via ssh.



can anybody tell me how to do that?



OOF, harsh - people wanna shut this one real fast.



Heres the situation. I have some nice preg_matches going on throughout my site, but the server I am on is throwing up errors left and right, complaining about my PCRE not being UTF-8 friendly.



After researching the problem, it seems the only way to make it friendly is by recompiling PHP with a few flags in the conditions.



And that is where I'm at.







linux php ssh






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jan 21 '10 at 7:01







johnnietheblack

















asked Jan 21 '10 at 6:46









johnnietheblackjohnnietheblack

2261410




2261410




migrated from stackoverflow.com Jan 21 '10 at 6:59


This question came from our site for professional and enthusiast programmers.









migrated from stackoverflow.com Jan 21 '10 at 6:59


This question came from our site for professional and enthusiast programmers.









  • 1





    Recompiling PHP is almost always a last resort. You need to talk more in detail about your situation in order to get at what you really need.

    – Ignacio Vazquez-Abrams
    Jan 21 '10 at 6:47











  • What OS? If it's a Linux distro, it's often easiest to start with the source package and modify it to add whatever extra options you need.

    – ZoogieZork
    Jan 21 '10 at 7:04











  • okay...so basically a fresh install?

    – johnnietheblack
    Jan 21 '10 at 7:06











  • Since you're modifying the source package for PHP, the result will be a new PHP package which you can use to install "over" your existing installation. This only works if PHP was originally installed via package, of course.

    – ZoogieZork
    Jan 21 '10 at 7:13












  • 1





    Recompiling PHP is almost always a last resort. You need to talk more in detail about your situation in order to get at what you really need.

    – Ignacio Vazquez-Abrams
    Jan 21 '10 at 6:47











  • What OS? If it's a Linux distro, it's often easiest to start with the source package and modify it to add whatever extra options you need.

    – ZoogieZork
    Jan 21 '10 at 7:04











  • okay...so basically a fresh install?

    – johnnietheblack
    Jan 21 '10 at 7:06











  • Since you're modifying the source package for PHP, the result will be a new PHP package which you can use to install "over" your existing installation. This only works if PHP was originally installed via package, of course.

    – ZoogieZork
    Jan 21 '10 at 7:13







1




1





Recompiling PHP is almost always a last resort. You need to talk more in detail about your situation in order to get at what you really need.

– Ignacio Vazquez-Abrams
Jan 21 '10 at 6:47





Recompiling PHP is almost always a last resort. You need to talk more in detail about your situation in order to get at what you really need.

– Ignacio Vazquez-Abrams
Jan 21 '10 at 6:47













What OS? If it's a Linux distro, it's often easiest to start with the source package and modify it to add whatever extra options you need.

– ZoogieZork
Jan 21 '10 at 7:04





What OS? If it's a Linux distro, it's often easiest to start with the source package and modify it to add whatever extra options you need.

– ZoogieZork
Jan 21 '10 at 7:04













okay...so basically a fresh install?

– johnnietheblack
Jan 21 '10 at 7:06





okay...so basically a fresh install?

– johnnietheblack
Jan 21 '10 at 7:06













Since you're modifying the source package for PHP, the result will be a new PHP package which you can use to install "over" your existing installation. This only works if PHP was originally installed via package, of course.

– ZoogieZork
Jan 21 '10 at 7:13





Since you're modifying the source package for PHP, the result will be a new PHP package which you can use to install "over" your existing installation. This only works if PHP was originally installed via package, of course.

– ZoogieZork
Jan 21 '10 at 7:13










2 Answers
2






active

oldest

votes


















1














Begin by figuring out how to connect to your server via ssh. Then use wget to download the latest php sources. cd into the directory with the unzipped files. Run configure with the options you want, then run make.



Here is the official FAQ: http://php.net/manual/en/faq.build.php






share|improve this answer

























  • Hmmm... better edit my post. The site is down.

    – Nathan Osman
    Jan 21 '10 at 7:09











  • There. A new working link!

    – Nathan Osman
    Jan 21 '10 at 7:16











  • thanks george:) sorry on the delay for checkin you as answer

    – johnnietheblack
    Jan 21 '10 at 17:35


















0














We have many roads that lead to Rome. If you want to recompile PHP, then you should first check your server. Which OS are you using? Which PHP version? Are there any Bundled PHP Extension you want to use?... and so on.



Recompiling PHP in general is like this:



  • searching for the official PHP source code

  • invoking ./configure. For example like this: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
    See a full list of configure options: https://www.php.net/manual/en/configure.about.php


  • invoking make


  • invoking make install

Please have a look at these tutorials:



Official tutorial (PHP is installed as an Apache2 module):
https://www.php.net/manual/en/install.unix.apache2.php (See step 5.)



You could also check at the offical github page.
https://github.com/php/php-src



Unofficial tutorial:
http://www.softwareprojects.com/resources/programming/t-how-to-recompile-php-with-gd-support-on-a-live-serv-1572.html






share|improve this answer

























    Your Answer








    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "2"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f104892%2fhow-to-recompile-php%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    1














    Begin by figuring out how to connect to your server via ssh. Then use wget to download the latest php sources. cd into the directory with the unzipped files. Run configure with the options you want, then run make.



    Here is the official FAQ: http://php.net/manual/en/faq.build.php






    share|improve this answer

























    • Hmmm... better edit my post. The site is down.

      – Nathan Osman
      Jan 21 '10 at 7:09











    • There. A new working link!

      – Nathan Osman
      Jan 21 '10 at 7:16











    • thanks george:) sorry on the delay for checkin you as answer

      – johnnietheblack
      Jan 21 '10 at 17:35















    1














    Begin by figuring out how to connect to your server via ssh. Then use wget to download the latest php sources. cd into the directory with the unzipped files. Run configure with the options you want, then run make.



    Here is the official FAQ: http://php.net/manual/en/faq.build.php






    share|improve this answer

























    • Hmmm... better edit my post. The site is down.

      – Nathan Osman
      Jan 21 '10 at 7:09











    • There. A new working link!

      – Nathan Osman
      Jan 21 '10 at 7:16











    • thanks george:) sorry on the delay for checkin you as answer

      – johnnietheblack
      Jan 21 '10 at 17:35













    1












    1








    1







    Begin by figuring out how to connect to your server via ssh. Then use wget to download the latest php sources. cd into the directory with the unzipped files. Run configure with the options you want, then run make.



    Here is the official FAQ: http://php.net/manual/en/faq.build.php






    share|improve this answer















    Begin by figuring out how to connect to your server via ssh. Then use wget to download the latest php sources. cd into the directory with the unzipped files. Run configure with the options you want, then run make.



    Here is the official FAQ: http://php.net/manual/en/faq.build.php







    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited Jan 21 '10 at 7:15

























    answered Jan 21 '10 at 7:04









    Nathan OsmanNathan Osman

    1,94562745




    1,94562745












    • Hmmm... better edit my post. The site is down.

      – Nathan Osman
      Jan 21 '10 at 7:09











    • There. A new working link!

      – Nathan Osman
      Jan 21 '10 at 7:16











    • thanks george:) sorry on the delay for checkin you as answer

      – johnnietheblack
      Jan 21 '10 at 17:35

















    • Hmmm... better edit my post. The site is down.

      – Nathan Osman
      Jan 21 '10 at 7:09











    • There. A new working link!

      – Nathan Osman
      Jan 21 '10 at 7:16











    • thanks george:) sorry on the delay for checkin you as answer

      – johnnietheblack
      Jan 21 '10 at 17:35
















    Hmmm... better edit my post. The site is down.

    – Nathan Osman
    Jan 21 '10 at 7:09





    Hmmm... better edit my post. The site is down.

    – Nathan Osman
    Jan 21 '10 at 7:09













    There. A new working link!

    – Nathan Osman
    Jan 21 '10 at 7:16





    There. A new working link!

    – Nathan Osman
    Jan 21 '10 at 7:16













    thanks george:) sorry on the delay for checkin you as answer

    – johnnietheblack
    Jan 21 '10 at 17:35





    thanks george:) sorry on the delay for checkin you as answer

    – johnnietheblack
    Jan 21 '10 at 17:35













    0














    We have many roads that lead to Rome. If you want to recompile PHP, then you should first check your server. Which OS are you using? Which PHP version? Are there any Bundled PHP Extension you want to use?... and so on.



    Recompiling PHP in general is like this:



    • searching for the official PHP source code

    • invoking ./configure. For example like this: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
      See a full list of configure options: https://www.php.net/manual/en/configure.about.php


    • invoking make


    • invoking make install

    Please have a look at these tutorials:



    Official tutorial (PHP is installed as an Apache2 module):
    https://www.php.net/manual/en/install.unix.apache2.php (See step 5.)



    You could also check at the offical github page.
    https://github.com/php/php-src



    Unofficial tutorial:
    http://www.softwareprojects.com/resources/programming/t-how-to-recompile-php-with-gd-support-on-a-live-serv-1572.html






    share|improve this answer





























      0














      We have many roads that lead to Rome. If you want to recompile PHP, then you should first check your server. Which OS are you using? Which PHP version? Are there any Bundled PHP Extension you want to use?... and so on.



      Recompiling PHP in general is like this:



      • searching for the official PHP source code

      • invoking ./configure. For example like this: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
        See a full list of configure options: https://www.php.net/manual/en/configure.about.php


      • invoking make


      • invoking make install

      Please have a look at these tutorials:



      Official tutorial (PHP is installed as an Apache2 module):
      https://www.php.net/manual/en/install.unix.apache2.php (See step 5.)



      You could also check at the offical github page.
      https://github.com/php/php-src



      Unofficial tutorial:
      http://www.softwareprojects.com/resources/programming/t-how-to-recompile-php-with-gd-support-on-a-live-serv-1572.html






      share|improve this answer



























        0












        0








        0







        We have many roads that lead to Rome. If you want to recompile PHP, then you should first check your server. Which OS are you using? Which PHP version? Are there any Bundled PHP Extension you want to use?... and so on.



        Recompiling PHP in general is like this:



        • searching for the official PHP source code

        • invoking ./configure. For example like this: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
          See a full list of configure options: https://www.php.net/manual/en/configure.about.php


        • invoking make


        • invoking make install

        Please have a look at these tutorials:



        Official tutorial (PHP is installed as an Apache2 module):
        https://www.php.net/manual/en/install.unix.apache2.php (See step 5.)



        You could also check at the offical github page.
        https://github.com/php/php-src



        Unofficial tutorial:
        http://www.softwareprojects.com/resources/programming/t-how-to-recompile-php-with-gd-support-on-a-live-serv-1572.html






        share|improve this answer















        We have many roads that lead to Rome. If you want to recompile PHP, then you should first check your server. Which OS are you using? Which PHP version? Are there any Bundled PHP Extension you want to use?... and so on.



        Recompiling PHP in general is like this:



        • searching for the official PHP source code

        • invoking ./configure. For example like this: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
          See a full list of configure options: https://www.php.net/manual/en/configure.about.php


        • invoking make


        • invoking make install

        Please have a look at these tutorials:



        Official tutorial (PHP is installed as an Apache2 module):
        https://www.php.net/manual/en/install.unix.apache2.php (See step 5.)



        You could also check at the offical github page.
        https://github.com/php/php-src



        Unofficial tutorial:
        http://www.softwareprojects.com/resources/programming/t-how-to-recompile-php-with-gd-support-on-a-live-serv-1572.html







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Apr 12 at 9:12

























        answered Apr 12 at 9:03









        JulianJulian

        1013




        1013



























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Server Fault!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f104892%2fhow-to-recompile-php%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            OW6pI,BmmrR1q MKn512M,YnxxwBKBNCmmX5GhG ZDAu kuNYPab4EjHVgXH yhJT9qH,wtSx HgX8
            u08 Swh,Saq92,lf88aq1ZzTB ikj,NP AtR2MJqIAMI2DDXZ4 OxqmmGdIYOOvmkXLK3lk,sZeuC8dvZecgOpUaZICXdN,Fn3,rz

            Popular posts from this blog

            RemoteApp sporadic failureWindows 2008 RemoteAPP client disconnects within a matter of minutesWhat is the minimum version of RDP supported by Server 2012 RDS?How to configure a Remoteapp server to increase stabilityMicrosoft RemoteApp Active SessionRDWeb TS connection broken for some users post RemoteApp certificate changeRemote Desktop Licensing, RemoteAPPRDS 2012 R2 some users are not able to logon after changed date and time on Connection BrokersWhat happens during Remote Desktop logon, and is there any logging?After installing RDS on WinServer 2016 I still can only connect with two users?RD Connection via RDGW to Session host is not connecting

            Vilaño, A Laracha Índice Patrimonio | Lugares e parroquias | Véxase tamén | Menú de navegación43°14′52″N 8°36′03″O / 43.24775, -8.60070

            Cegueira Índice Epidemioloxía | Deficiencia visual | Tipos de cegueira | Principais causas de cegueira | Tratamento | Técnicas de adaptación e axudas | Vida dos cegos | Primeiros auxilios | Crenzas respecto das persoas cegas | Crenzas das persoas cegas | O neno deficiente visual | Aspectos psicolóxicos da cegueira | Notas | Véxase tamén | Menú de navegación54.054.154.436928256blindnessDicionario da Real Academia GalegaPortal das Palabras"International Standards: Visual Standards — Aspects and Ranges of Vision Loss with Emphasis on Population Surveys.""Visual impairment and blindness""Presentan un plan para previr a cegueira"o orixinalACCDV Associació Catalana de Cecs i Disminuïts Visuals - PMFTrachoma"Effect of gene therapy on visual function in Leber's congenital amaurosis"1844137110.1056/NEJMoa0802268Cans guía - os mellores amigos dos cegosArquivadoEscola de cans guía para cegos en Mortágua, PortugalArquivado"Tecnología para ciegos y deficientes visuales. Recopilación de recursos gratuitos en la Red""Colorino""‘COL.diesis’, escuchar los sonidos del color""COL.diesis: Transforming Colour into Melody and Implementing the Result in a Colour Sensor Device"o orixinal"Sistema de desarrollo de sinestesia color-sonido para invidentes utilizando un protocolo de audio""Enseñanza táctil - geometría y color. Juegos didácticos para niños ciegos y videntes""Sistema Constanz"L'ocupació laboral dels cecs a l'Estat espanyol està pràcticament equiparada a la de les persones amb visió, entrevista amb Pedro ZuritaONCE (Organización Nacional de Cegos de España)Prevención da cegueiraDescrición de deficiencias visuais (Disc@pnet)Braillín, un boneco atractivo para calquera neno, con ou sen discapacidade, que permite familiarizarse co sistema de escritura e lectura brailleAxudas Técnicas36838ID00897494007150-90057129528256DOID:1432HP:0000618D001766C10.597.751.941.162C97109C0155020