diff options
Diffstat (limited to 'pkgtools/cwrappers/files/bin/normalise-ld.c')
-rw-r--r-- | pkgtools/cwrappers/files/bin/normalise-ld.c | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/pkgtools/cwrappers/files/bin/normalise-ld.c b/pkgtools/cwrappers/files/bin/normalise-ld.c index aefcad07e5d..666a84d0dee 100644 --- a/pkgtools/cwrappers/files/bin/normalise-ld.c +++ b/pkgtools/cwrappers/files/bin/normalise-ld.c @@ -1,7 +1,7 @@ -/* $NetBSD: normalise-ld.c,v 1.2 2015/04/19 14:30:07 jperkin Exp $ */ +/* $NetBSD: normalise-ld.c,v 1.3 2017/06/11 19:34:43 joerg Exp $ */ /*- - * Copyright (c) 2009 Joerg Sonnenberger <joerg@NetBSD.org>. + * Copyright (c) 2009, 2017 Joerg Sonnenberger <joerg@NetBSD.org>. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -36,6 +36,23 @@ #include "common.h" void +operation_mode_ld(struct arglist *args) +{ + struct argument *arg; + + current_operation_mode = mode_link_executable; + TAILQ_FOREACH(arg, args, link) { + if (arg->val[0] != '-') + continue; + if (strcmp(arg->val, "-shared") == 0 || + strcmp(arg->val, "-Bshareable") == 0) { + current_operation_mode = mode_link_shared; + continue; + } + } +} + +void normalise_ld(struct arglist *args) { struct argument *arg, *arg2, *arg3; |