GithubHelp home page GithubHelp logo

PHP DEBUG versions about docker-phpfarm HOT 12 CLOSED

splitbrain avatar splitbrain commented on July 18, 2024
PHP DEBUG versions

from docker-phpfarm.

Comments (12)

eugenesia avatar eugenesia commented on July 18, 2024 1

Thanks @splitbrain I tried the fpoirotte branch with Dockerfile-Jessie, it seems to work fine and indicates it's NOT a debug build:

root@3c002eedf6bb:/phpfarm/inst/php-5.3.29/bin# ./php --version
PHP 5.3.29 (cli) (built: Mar 22 2017 12:00:29)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2014 Zend Technologies
    with Xdebug v2.2.7, Copyright (c) 2002-2015, by Derick Rethans

I'll try the Dockerfile-Wheezy version next.

from docker-phpfarm.

splitbrain avatar splitbrain commented on July 18, 2024

No idea what z-ray is. The builds include xdebug and enable it by default. I guess it should be possible to disable xdebug through a local php.ini as described in the documentation.

from docker-phpfarm.

inquam avatar inquam commented on July 18, 2024

z-ray is a zend extension to php that gives you information about the request like function calls, memory consumption, db querys etc. http://www.zend.com/en/products/server/z-ray

x-debug doesn't require a debug build of PHP as far as I can recall? I have added it to non debug builds of php before. As far as I recall the debug symbols of php are only needed to debug php itself, when you work on the core for instance develop your own extensions etc.

from docker-phpfarm.

splitbrain avatar splitbrain commented on July 18, 2024

Hmm I'm not explicitly enable any debug flags: https://github.com/splitbrain/docker-phpfarm/blob/master/phpfarm/custom-options.sh

And the options set by phpfarm do not to do either: https://github.com/cweiske/phpfarm/blob/master/src/options.sh

What makes you think they are compiled with debug symbols? Does phpinfo() mention it?

from docker-phpfarm.

inquam avatar inquam commented on July 18, 2024

Running bash on the image and checking the versions of the built php versions.

 root@4d1efc6c58e2:/phpfarm/inst/php-5.6.29/bin# pwd
 /phpfarm/inst/php-5.6.29/bin
 root@4d1efc6c58e2:/phpfarm/inst/php-5.6.29/bin# ./php -v
 PHP 5.6.29 (cli) (built: Mar 10 2017 14:52:01) (DEBUG)
 Copyright (c) 1997-2016 The PHP Group
 Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
     with Xdebug v2.4.1, Copyright (c) 2002-2016, by Derick Rethans

As you can see it's clearly marked as (DEBUG)

from docker-phpfarm.

splitbrain avatar splitbrain commented on July 18, 2024

Hmm weird. I guess we need some --no-debug build flag or something? Pull request welcome.

from docker-phpfarm.

inquam avatar inquam commented on July 18, 2024

No that doesn't seem to be a valid flag. The environment variable DEBUG can also make sure debug builds are built. But can't see that being set anywhere either.

from docker-phpfarm.

eugenesia avatar eugenesia commented on July 18, 2024

I think the PHPFarm compile script is the one that inserted the --enable-debug flag? See https://github.com/cweiske/phpfarm/blob/master/src/compile.sh#L116

That flag seems to be hardcoded in compile.sh and cannot be overridden using custom options files, so you probably have to modify the PHPFarm compile script.

There is another more updated fork of the PHPFarm script here https://github.com/fpoirotte/phpfarm . This allows you to disable the --enable-debug flag using the version string, see https://github.com/fpoirotte/phpfarm#special-flags-in-version-strings . You may wish to use that instead?

I might create a version of this repo using the more updated PHPFarm script if I have time, but don't hold your breath!

from docker-phpfarm.

splitbrain avatar splitbrain commented on July 18, 2024

That fork looks interesting. I'm looking into it right now... it does not work right out of the box as replacement, so I have to figure out what to adjust.

from docker-phpfarm.

splitbrain avatar splitbrain commented on July 18, 2024

I just pushed a branch that makes use of the fork. Took me a while but it seems to work now. Could you try it before I merge it into master?

from docker-phpfarm.

inquam avatar inquam commented on July 18, 2024

I'll check it out. I manually made it strip --enable-debug from the compile.sh script and that worked fine to. But I'll give your fork a go asap.

from docker-phpfarm.

eugenesia avatar eugenesia commented on July 18, 2024

Hi @splitbrain I tried the fpoirotte branch with Dockerfile-Wheezy. The build took a long time 😂 but I loaded index.php for the different PHP versions and all reported NO debug build. I also tested with PHP CLI, see below.

root@11d77e36344b:/phpfarm/inst/php-5.2/bin# ./php --version
PHP 5.2.17 (cli) (built: Mar 23 2017 10:16:18)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
    with Xdebug v2.2.7, Copyright (c) 2002-2015, by Derick Rethans

I guess we're good to go?

from docker-phpfarm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.