BoatX
BoatX

Reputation: 173

What is purpose of TARGET_ARCH variable in Makefiles

I have noticed that in Implicit Rules in Gnu Make is variable $(TARGET_ARCH) for example :

$(LINK.o) $^ $(LOADLIBES) $(LDLIBS) -o $@
LINK.o = $(CC) $(LDFLAGS) $(TARGET_ARCH)

I supposed that this variable is needed for cross compilation, but I haven't found any information about it in Gnu Make documentation.

Upvotes: 11

Views: 3982

Answers (1)

sager89
sager89

Reputation: 980

I agree that it's probably meant for cross-compilation. The variable TARGET_ARCH has no default value - it's there for end-users to define as they see fit.

Upvotes: 3

Related Questions