Skip to content
This repository has been archived by the owner on Jan 2, 2021. It is now read-only.

Couldn't create build system & environment #288

Open
Nonepse opened this issue Jun 4, 2018 · 5 comments
Open

Couldn't create build system & environment #288

Nonepse opened this issue Jun 4, 2018 · 5 comments

Comments

@Nonepse
Copy link

Nonepse commented Jun 4, 2018

Running on macOS 10.13.4 with Xcode 9.4 installed, I get the following errors when trying to build my project:

$ ./xcbuild -workspace MyProject.xcworkspace
error: couldn't create build system
error: couldn't create build environment

Am I missing something?

@Ktwu
Copy link
Contributor

Ktwu commented Jun 4, 2018

I don't think you're missing anything; the build system and the build environment are defined by xcspec files, I believe, which should be hosted in your developer root (and therefore discoverable).

  1. When was the last time you could build your project with xcbuild? When did you last build xcbuild? What version of Xcode did you have then?
  2. Is MyProject.xcworkspace doing anything interesting? How'd you create it? If you create a vanilla (I assume iOS) workspace and try to build it, do you get the same errors?

@Nonepse
Copy link
Author

Nonepse commented Jun 5, 2018

Thanks for the reply @Ktwu. But mine won't be very helpful :(

  1. First time ever on this machine
  2. I first tried with a rather large project. Thinking it could be the issue, I tried with a vanilla one: same results

@lechium
Copy link

lechium commented Jun 10, 2018

i have the same problem and i /think/ i know what it is but not quite sute how to solve if.

using the xcode-select from the project prints out the following path

'private/var/db/xcode_select_link'

without the leading slash, and without that, its not a valid path. i just built and installed xcbuild for the first time today and haven ever successfully built anything with it because i get an identical error.

@lechium
Copy link

lechium commented Jun 11, 2018

follow up on this- the incorrect path was most certainly the problem for me. and was "solved" by doing

"ln -s /private private"

from my pwd in the command line. not sure how to properly fix it, but once i did this i could actually use xcbuild succesfully. bad path logic somewhere. not sure where.

@TBoys
Copy link

TBoys commented Nov 3, 2018

you should "export DEVELOPER_DIR=/Applications/Xcode.app" first

@MarkH MarkH mentioned this issue Jan 2, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants