PhDP
PhDP

Reputation: 397

Xcode and input/output files

I have to put my input files directly in the root directory for xcode to see them, and the output files are always in the same root directly.

How can I configure xcode to change the input/output directories ?

Upvotes: 2

Views: 1556

Answers (1)

Paul R
Paul R

Reputation: 212979

Your application should never make any assumptions about the current working directory when it is launched. It will be different when launched with Xcode than when launched from a command line or from the Finder or via other means. You need to either use absolute paths for your input/output files (icky, but may be acceptable for "research" type code), or put them in some specific location, or have some other reliable way of defining the location.

Upvotes: 1

Related Questions