Nios® II Software Developer Handbook

ID 683525
Date 8/28/2023
Public
Document Table of Contents

16.6.2. Object File Directory Tree

The makefile created by the Nios® II SBT creates a new directory tree for generated object files. To the extent possible, the object file directory tree retains the structure of the corresponding source directory.

For example, if you specify the path to a source file as

src/util/special/tools.c

the makefile places the corresponding object code in

obj/util/special/tools.o

The makefile does not create object directories outside the project directory root. If the source file path you specify is a relative path beginning with "..", the Nios® II SBT flattens the path name prior to creating the object directory structure.

For example, if you specify the path to a source file as

../special/tools.c

the makefile places the corresponding object code in

obj/tools.o

If you specify an absolute path to source files under Cygwin, the Nios® II SBT creates the obj directory structure as if you had used the Cygwin form of the path name. For example, if you specify the path to a source file as

c:/dev/app/special/tools.c

the Nios® II SBT places the corresponding object code in

obj/cygdrive/c/dev/app/special/tools.o