rmyorston / pdpmake

Public domain POSIX make
https://frippery.org/make
Other
103 stars 10 forks source link

Allow ENABLE_FEATURE_MAKE_POSIX_202X by itself #25

Closed samboy closed 1 year ago

samboy commented 1 year ago

This patch allows pdpmake to compile with ENABLE_FEATURE_MAKE_POSIX_202X but ENABLE_FEATURE_MAKE_EXTENSIONS disabled.

The block this is relevant for is this block in make.c:

#if ENABLE_FEATURE_MAKE_EXTENSIONS || ENABLE_FEATURE_MAKE_POSIX_202X
        // Reset flag to detect duplicate prerequisites
        if (!quest && !(np->n_flag & N_DOUBLE)) {
                for (rp = np->n_rule; rp; rp = rp->r_next) {
                        for (dp = rp->r_dep; dp; dp = dp->d_next) {
                                dp->d_name->n_flag &= ~N_MARK;
                        }
                }
        }
#endif