Module Name: src
Committed By: rillig
Date: Thu Feb 4 19:50:29 UTC 2021
Modified Files:
src/usr.bin/make: arch.c
Log Message:
make: merge duplicate code in Arch_FindLib
No functional change. Furthermore, this only affects builds that
explicitly disable LIBRARIES in config.h.
To generate a diff of this commit:
cvs rdiff -u -r1.194 -r1.195 src/usr.bin/make/arch.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/usr.bin/make/arch.c
diff -u src/usr.bin/make/arch.c:1.194 src/usr.bin/make/arch.c:1.195
--- src/usr.bin/make/arch.c:1.194 Sat Jan 23 10:48:49 2021
+++ src/usr.bin/make/arch.c Thu Feb 4 19:50:29 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: arch.c,v 1.194 2021/01/23 10:48:49 rillig Exp $ */
+/* $NetBSD: arch.c,v 1.195 2021/02/04 19:50:29 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -126,7 +126,7 @@
#include "config.h"
/* "@(#)arch.c 8.2 (Berkeley) 1/2/94" */
-MAKE_RCSID("$NetBSD: arch.c,v 1.194 2021/01/23 10:48:49 rillig Exp $");
+MAKE_RCSID("$NetBSD: arch.c,v 1.195 2021/02/04 19:50:29 rillig Exp $");
typedef struct List ArchList;
typedef struct ListNode ArchListNode;
@@ -975,7 +975,7 @@ Arch_FindLib(GNode *gn, SearchPath *path
#ifdef LIBRARIES
Var_Set(TARGET, gn->name, gn);
#else
- Var_Set(TARGET, gn->path == NULL ? gn->name : gn->path, gn);
+ Var_Set(TARGET, GNode_Path(gn), gn);
#endif
}