Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

halide #2559

Merged
merged 8 commits into from
Mar 11, 2017
Merged

halide #2559

merged 8 commits into from
Mar 11, 2017

Conversation

minrk
Copy link
Member

@minrk minrk commented Mar 6, 2017

cc @jrk
cc @arokem who opened #752

closes #752

need to avoid compiling with env clang++ on macOS
needs a Makefile patch to respect LDFLAGS
@conda-forge-linter
Copy link

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipes/halide) and found it was in an excellent condition.

- toolchain
- clangdev
- llvmdev
- zlib # [linux]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not use this on Mac too?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added it because the build was failing on Linux without it, but OK on Mac. Now that I think about it, this should be a build and run dep on both. Fixed now.

test:
requires:
- toolchain
- zlib # [linux]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above. Why not Mac also?

simplejson is a simple, fast, complete, correct and extensible
JSON <http://json.org> encoder and decoder for Python 2.5+ and
Python 3.3+. It is pure Python code with no dependencies, but includes
an optional C extension for a serious speed boost.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be updated or removed. Seems to be the same as the example.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

whoops, thanks.


extra:
recipe-maintainers:
- jrk
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you ok with being a maintainer here, @jrk?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW, I was sitting next to @jrk while making this. I asked and he said yes :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe you. 😄

build:
- toolchain
- clangdev
- llvmdev
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will we need some run time library as a run dependency then?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Guessing not as we don't use these to compile the code. Though I'm a little fuzzy on what they are being used for currently.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang is used to parse some things at build time, and llvm gets statically linked (effectively), so these are not runtime dependencies. There are no runtime dependecies for the static lib, and only zlib for the dylib.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, forgot about the static libraries in llvmdev/clangdev.

@@ -0,0 +1,10 @@
if [[ $(uname) == "Darwin" ]]; then
# don't use clang++ from the env
export CXX=c++
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Guessing this shouldn't be needed here.

Copy link
Member Author

@minrk minrk Mar 10, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

toolchain sets CXX=clang++, which normally resolves to /usr/bin/clang++. When clangdev is installed in conda, the version in the env will be used instead of the version toolchain normally expects. This doesn't work (I haven't investigated why, but the conda-packaged clang can't build the library). An equivalent fix would be setting it to /usr/bin/clang++.

If toolchain set export CXX=/usr/bin/clang++ so that it always pointed to the same compiler regardless of what's in the env, this wouldn't be necessary.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a good point. Should we open a PR at the toolchain and discuss? 😉

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -0,0 +1,16 @@
if [[ $(uname) == "Darwin" ]]; then
# don't use clang++ from the env
export CXX=c++
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting. Maybe we should discuss the pros and cons of this choice as it pertains to Halide.

generator_test();

return 0;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: A terminal newline would be nice here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

@jakirkham
Copy link
Member

Very excited to see Halide being added to conda-forge.

Not super familiar with the build process for Halide so may be asking some naive questions above. Mainly they focus on how and with what we build Halide and what that means for the package and how it can be used.

test:
requires:
- toolchain
- zlib
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Guessing we can drop this, zlib, as it is already a run time dependency.

@jakirkham
Copy link
Member

There are some minor changes, but they can be saved for the feedstock. Especially as this is passing on all CIs. 🎉

@jakirkham jakirkham merged commit a7b38e2 into conda-forge:master Mar 11, 2017
@jakirkham
Copy link
Member

Thanks @minrk.

minrk added a commit to minrk/toolchain-feedstock that referenced this pull request Mar 11, 2017
ensures that enabling toolchain specifies a specific compiler on the system, and not the one that may be installed in the env with the same name, unless explicitly requested.

This is the right thing to do for halide (conda-forge/staged-recipes#2559 (comment)), but may not be what people want in general. When people install gcc as a build dep (and toolchain), do they expect the one in the env to be used by default without being explicitly selected? Should they?
@minrk minrk deleted the halide branch March 11, 2017 05:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants