Install Nginx, PHP-FPM, MySQL and phpMyAdmin on OS X Yosemite

Recently my APM(Apache+PHP+MariaDB) installation from macPorts broken down. So is the perfect time to get rid of the web server stack and replace it with Nginx and PHP-FPP as FastCGI implementation. Below you can read how to setup Nginx, PHP-FPM, MySQL and PhpMyAdmin on OS X 10.10 (Yosemite).

Xcode

First of all, get the last Xcode version via Mac App Store (or at this time, from Developer Member Page). As soon as you have finished the download, open Xcode and agree to the license and click install on the first window how will open.
Continuar a ler

If the programmer is stupid…

If the programmer is stupid, modern compilers like CLang and GCC can ignore and/or interpret stupid code who you can make and the assembly output will be clean.

In the line below are written a main function with some stupid code.

int main(int argc, char** argv)
{
    int sum = 0;

    for (int i = 0; i < 10; i++)
    {
        sum += i;
    }

    return sum;
}

And the output should be something like this. (this code not contain directives, unused labels and comments that are not comments line)

main: # @main
    movl $45, %eax
    ret

The compiler knows the result will be 45, and the only thing who will appears on assembly is the return with the number 45.