krytarowski added a comment.

Actually I think that we can handle two cases witch a combination of proposals:

- native mode
- cross mode

For the native mode we go for something like:

  #if defined(__NetBSD__)
  #define NATIVE_TARGET LLD_NETBSD
  #else
  ...

and for cross mode read `argv[0]` to detect target triple in program name.

If `argv[0] == ld` we assume native mode and set target to native, otherwise 
try to parse target from `argv[0]`, if the target is not parsable bail out with 
error.

This way we can transplant cc driver information into lld.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D56215/new/

https://reviews.llvm.org/D56215



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to