2ec3187 test: compile test-utmp.c only if UTMP is enabled

1 file Authored by Torsten Hilbrich a year ago, Committed by bluca a year ago,
    test: compile test-utmp.c only if UTMP is enabled
    
    When compiling with -D utmp=false the compilation fails with:
    
    ../../git/systemd/src/test/test-utmp.c: In function ‘test_dump_run_utmp’:
    ../../git/systemd/src/test/test-utmp.c:21:9: error: cleanup argument not a function
       21 |         _unused_ _cleanup_(utxent_cleanup) bool utmpx = false;
          |         ^~~~~~~~
    ../../git/systemd/src/test/test-utmp.c:23:17: error: implicit declaration of function ‘utxent_start’ [-Werror=implicit-function-declaration]
       23 |         utmpx = utxent_start();
          |                 ^~~~~~~~~~~~
    
    any many other errors
    
    Add a conditional to compile test-utmp.c only if ENABLE_UTMP is true.
    
    (cherry picked from commit 41cac2a8b98fc5faebe942c697b17e109822342d)
    
        
file modified
+2 -1