Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support skipping non-essential parts of the build #1127

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Jul 6, 2020

  1. Support skipping non-essential parts of the build

    This significantly speeds up build times for projects which just want to use tdlib as-is.
    On a single core this should cut about 5 minutes; on 4 cores it cuts a bit more than a minute.
    All this for no measurable cost.
    
    Without skipping:
    $ cmake -DCMAKE_BUILD_TYPE=Release -DTD_SKIP_BENCHMARK=OFF -DTD_SKIP_TEST=OFF -DTD_SKIP_TG_CLI=OFF ..
    ( ... regular output ... )
    $ time /usr/bin/time make install -j4 DESTDIR=../../td_destdir
    ( ... regular output ... )
    1414.69user 55.66system 7:01.60elapsed 348%CPU (0avgtext+0avgdata 2752144maxresident)k
    0inputs+1210120outputs (0major+21767636minor)pagefaults 0swaps
    real	7m1,604s
    user	23m34,699s
    sys	0m55,665s
    
    With skipping:
    $ cmake -DCMAKE_BUILD_TYPE=Release -DTD_SKIP_BENCHMARK=ON -DTD_SKIP_TEST=ON -DTD_SKIP_TG_CLI=ON ..
    ( ... regular output ... )
    $ time /usr/bin/time make install -j4 DESTDIR=../../td_destdir
    ( ... regular output ... )
    1118.16user 42.62system 5:56.22elapsed 325%CPU (0avgtext+0avgdata 2751196maxresident)k
    0inputs+891912outputs (0major+17310062minor)pagefaults 0swaps
    real	5m56,230s
    user	18m38,163s
    sys	0m42,629s
    BenWiederhake committed Jul 6, 2020
    Configuration menu
    Copy the full SHA
    47e2d88 View commit details
    Browse the repository at this point in the history