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

Change $JULIA_DIR to $JULIA_PREFIX #10517

Closed
wants to merge 1 commit into from
Closed

Change $JULIA_DIR to $JULIA_PREFIX #10517

wants to merge 1 commit into from

Conversation

spacewander
Copy link

@stevengj
Copy link
Member

Looks fine to me, modulo my comment.


gcc -o test -I$JULIA_DIR/include/julia -L$JULIA_DIR/usr/lib -ljulia test.c
# $JULIA_PREFIX/lib is the directory where libjulia lies in
Copy link
Member

Choose a reason for hiding this comment

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

This comment looks a bit odd ("where libjulia lies in" is non-idiomatic), and also doesn't explain the -I flag. It would be better to integrate the explanation into the text, not into the code example. Maybe remove the comment and change the text to:

For instance, when Julia is installed to ``$JULIA_PREFIX/bin`` (where you are
responsible for defining the ``JULIA_PREFIX`` variable appropriately) , its header
file ``julia.h`` is installed in ``$JULIA_PREFIX/include`` and its library ``libjulia`` is
installed in ``$JULIA_PREFIX/lib`` (by default). In this case, one can compile the
above ``test.c`` program with gcc using::

@spacewander
Copy link
Author

:) Ok, I will update it.

@ViralBShah
Copy link
Member

Is the build failure relevant? If not, perhaps we can merge.

@ViralBShah ViralBShah added the docs This change adds or pertains to documentation label Mar 29, 2015
@@ -33,9 +33,9 @@ We start with a simple C program that initializes Julia and calls some Julia cod
return 0;
}

In order to build this program you have to put the path to the Julia header into the include path and link against ``libjulia``. For instance, when Julia is installed to ``$JULIA_DIR``, one can compile the above test program ``test.c`` with gcc using::
In order to build this program you have to put the path to the Julia header into the include path and link against ``libjulia``. For instance, when Julia is installed to ``$JULIA_PREFIX/bin`` (where you are responsible for defining the ``JULIA_PREFIX`` variable appropriately) , its header file ``julia.h`` is installed in ``$JULIA_PREFIX/include`` and its library ``libjulia`` is installed in ``$JULIA_PREFIX/lib`` (by default). In this case, one can compile the above ``test.c`` program with gcc using::
Copy link
Member

Choose a reason for hiding this comment

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

you have an extra space before a ,. There should also be a comma after "In order to build this program".

While I am nitpicking, probably the paragraph should be consistent about "you" vs. "one" — pick one and use it consistently.

@ararslan
Copy link
Member

No longer relevant, as this environment variable has since been renamed.

@ararslan ararslan closed this Mar 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs This change adds or pertains to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants