From b580667107013204e89f953277a5224523d7e797 Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Mon, 29 Aug 2011 23:15:15 +0000 Subject: [PATCH] Fixed an issue when linking with -lossaudio outside NetBSD --- src/makefile.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/makefile.c b/src/makefile.c index 141d2cf..7e53dda 100644 --- a/src/makefile.c +++ b/src/makefile.c @@ -13,7 +13,8 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ /* TODO: - * - only check the PREFS_n flags inside a wrapper around fputs()/fprintf() */ + * - only check the PREFS_n flags inside a wrapper around fputs()/fprintf() + * - use "$(RM)" instead of "$(RM) --" on NetBSD < 5.0 */ @@ -528,7 +529,7 @@ static void _binary_ldflags(Configure * configure, FILE * fp, NULL }; char const * libs_sunos[] = { "dl", "ossaudio", "ws2_32", NULL }; char const * libs_win32[] = { "dl", "ossaudio", NULL }; - char buf[10]; + char buf[16]; char const ** libs; String * p; String * q; @@ -1439,6 +1440,7 @@ static int _write_distclean(Configure * configure, FILE * fp) if(configure->prefs->flags & PREFS_n) return 0; fputs("\ndistclean:", fp); + /* only depend on the "clean" target if we do not have subfolders */ if((subdirs = config_get(configure->config, "", "subdirs")) == NULL) fputs(" clean\n", fp); else @@ -1447,6 +1449,7 @@ static int _write_distclean(Configure * configure, FILE * fp) " && $(MAKE) distclean) || exit; done\n", fp); _clean_targets(configure->config, fp); } + /* FIXME do not erase targets that need be distributed */ if(config_get(configure->config, "", "targets") != NULL) fputs("\t$(RM) -- $(TARGETS)\n", fp); return 0;