Page MenuHomeFreeBSD

Bring back lang/julia
ClosedPublic

Authored by arrowd on Nov 25 2021, 10:06 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Feb 28, 9:30 PM
Unknown Object (File)
Feb 23 2024, 11:54 PM
Unknown Object (File)
Feb 21 2024, 11:04 AM
Unknown Object (File)
Feb 14 2024, 3:13 AM
Unknown Object (File)
Dec 24 2023, 3:17 PM
Unknown Object (File)
Dec 24 2023, 3:17 PM
Unknown Object (File)
Dec 24 2023, 3:17 PM
Unknown Object (File)
Dec 24 2023, 3:17 PM

Details

Summary

This is a very minimal port of lang/julia, there is no meta port and some knobs are removed for now.
This is based on a release candidate for julia but the next release should drop soon, and i will rebase asap.
I used lang/julia10 as a starting point but have made a number of changes, this is now based on v1.7.0-rc3

UPDATE: now on v1.7.0.

Test Plan

poudriere: testport succeed on my 12.2-release 12.3-release and 13.0-release on amd64.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

Sorry everyone, this is my first day with Phabricator and it is getting late and i am making mistakes.
I am going to quit here for the night and try again tomorrow.

lang/julia/Makefile
8

Isn't it possible to replace MASTER_SITES by USE_GITHUB?

35

This could be replaced by USES+=blaslapack

lang/julia/Makefile
8

Not at this moment, julia's build system will try to download its libs during the bulid stage.
By Downloading the full tar instead this is avoided.

lang/julia/Makefile
35

julia depends on openblas not blas,
did you mean USES+=blaslapack:openblas

lang/julia/Makefile
8

On second thought if i can patch julia's build system so that it wont call out during the build stage and use GH_TUPLE from ports to Download its libs in advance i can use USE_GITHUB, let me look in to this a bit further.

val_packett.cool added inline comments.
lang/julia/Makefile
8

If the /releases/ tarball is manually built to contain more vendored stuff than just the auto archive of a git tag, it is actually better to use this URL. e.g. I use this in net-im/fractal (though with gitlab). Do not switch to USE_GITHUB in that case!

tcberner added inline comments.
lang/julia/Makefile
43

^ wait what?

96

^ no need to specify the same port multiple times.

108

^ could be done more declaratively without an if, via NATIVE_MAKE_ARGS

lang/julia/pkg-plist
300

^you could think of adding 1.7 via a PLIST_SUB -- depending on how often this version is bumped, this could greatly reduce the churn on the plist.

Removed DESCR= ${.CURDIR}/../julia/pkg-descr

Change

.if ${PORT_OPTIONS:MNATIVE}
MAKE_ARGS+=	MARCH=native
.endif  # .if ${PORT_OPTIONS:MNATIVE}

to

NATIVE_MAKE_ARGS+=	MARCH=native
rizor.reardon_yahoo.com marked an inline comment as done and an inline comment as not done.Nov 28 2021, 8:04 PM
lang/julia/Makefile
103

^this should now no longer be required for the NATIVE option. You can move the variables up to the normal options block.

lang/julia/Makefile
158

^ this seems also to get removed in the DOCS-on target --- why not consolidate it?

rizor.reardon_yahoo.com set the repository for this revision to R11 FreeBSD ports repository.

Redundant suitesparse libs removed.
Unnecessary .include <bsd.port.options.mk> removed.
DOCS targets consolidated.
And pkg-plist refreshed.

Fixed man page.
Stop julia build system from making unused empty directory.
Refreshed pkg-plist

Somme portlint warnings.

lang/julia/Makefile
27

"LIB_DEPENDS" has to appear earlier.

83

use a tab (not space) after a variable name

133

contiguous blank lines (> 1 lines) found.

I just tested it in poudriere, and it builds fine, at least on amd64 / 14.0-CURRENT.

rizor.reardon_yahoo.com edited the summary of this revision. (Show Details)
rizor.reardon_yahoo.com edited the test plan for this revision. (Show Details)

Moved to version 1.7.0 and updated and fix Makefile pkg-plist and patches.

arrowd added inline comments.
lang/julia/Makefile
11

Mostly a nitpick, but how about

16

Can you put an explanation for ONLY_FOR_ARCHS in the comment? Why is it only available for amd64?

18

Another style nitpick: add another tab symbol to align 7z... line with BUILD_DEPENDS below.

114

I'm a bit confused by this check. We do have USES=blaslapack:openblas unconditionally, so it should always be available. Why perform compile-check?

rizor.reardon_yahoo.com added inline comments.
lang/julia/Makefile
114

The test is to see if openblas was built with the INTERFACE64 knob on or off and set julia to build accordingly.

I'd say this is looking fine.

This revision is now accepted and ready to land.Dec 7 2021, 6:14 AM
lang/julia/Makefile
39

Hard-coding this will break configure phase in case of different GCC_DEFAULT.

lang/julia/Makefile
39

what about GCC_VERSION?

This comment was removed by contact_shiori.com.br.
lang/julia/Makefile
39

Hard-coding this will break configure phase in case of different GCC_DEFAULT.

rizor.reardon_yahoo.com marked an inline comment as done.

Found a way to build with out hard-coded dependency on GCC10 and caught a couple of white space issues.

This revision now requires review to proceed.Dec 12 2021, 6:23 PM
lang/julia/Makefile
138

This could be put in a regular post-install target: $STRIP_CMD is only set to /usr/bin/strip when $WITH_DEVUG is not defined, else it is set to true.

Fix build with latest libgit2 with out breaking quarterly.

Remove post-install-DEBUG-off: and update post-install as suggested by thierry.

lang/julia/Makefile
128

Can' this be done without nested loop?

.for file in .codecov.yml .travis.yml appveyor.yml bors.toml .gitignore source-extracted .github
${FIND} ${STAGEDIR}${PREFIX}/${INSTALLDIR}/share/julia/stdlib/v${PORTVERSION:R} -name ${file}
.endfor
lang/julia/Makefile
45

How about doing the following changes about this variable:

  1. Rename it to JULIA to bring it in sync with pkg-plist substitution.
  2. Remove PKGNAMESUFFIX from its value, as it is empty anyways. Or did you intended to use DISTVERSIONSUFFIX?
  3. Remove the julia/ part from the beginning. Right now the path to Julia stuff contains /julia/julia/ twice.
lang/julia/Makefile
61

This is probably a no-op, since you don't define USE_GPL_LIBS anywhere. This should probably be changed to just USE_GPL_LIBS=0.

lang/julia/Makefile
60

Do we need DEBUG_VARS_OFF= FORCE_ASSERTIONS=0 for this to work properly?

lang/julia/Makefile
55

Why do we need the -stdlib=libc++ flag? This is default for our Clang anyways, however some users are using GCC to compile stuff. Wouldn't this flag cause problems in such case?

Why install under ${PREFIX}/julia at all? Maybe get rid of these JULIA/INSTALLDIR altogether?

Remove -stdlib=libc++and FORCE_ASSERTIONS=${FORCE_ASSERTIONS} and JULIA/INSTALLDIR and nested loop,
update pkg-plist and set USE_GPL_LIBS to 0.

arrowd edited reviewers, added: rizor.reardon_yahoo.com; removed: arrowd.

Landed in 6b461fe1192987ac36bd1c1af3d517b8e6497fc2 , thanks everyone who contributed to this.

This revision is now accepted and ready to land.Dec 29 2021, 11:44 AM

Its been a while since I used Phabricator ._.
Sorry for the noise.