Conversation
bddcf93 to
ff6119f
Compare
|
@MartinNowak: can we move forward with this? https://travis-ci.org/dlang/dmd/jobs/276138166 (especially when it's already existent) |
|
Doesn't this mean that dub could get out of date on the host machine? |
ff6119f to
dbed996
Compare
|
Thanks for your pull request, @wilzbach! Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. |
You meant that you have an old D compiler and still want to use the newest DUB? Well, definitely a use case, but downloading a newer DUB yourself isn't that difficult ... The point of this issue / PR was that on the CI machines we essentially download DUB twice and in particular the download from code.dlang.org is problematic as code.dlang.org has longer downtimes fairly regularly. |
|
We could add explicit installs for e.g. |
MartinNowak
left a comment
There was a problem hiding this comment.
Looks OKish, but could be done nicer I guess.
How about adding a install() function and call install_compiler and install_dub from there? Also now you construct binpath twice (though one instance is named bin_path).
|
|
||
| if [ "$HAS_DUB_INCLUDED" -eq 0 ] ; then | ||
| install_dub | ||
| fi |
There was a problem hiding this comment.
Why do you use a version based approach below, and a path based approach here?
dbed996 to
41156d8
Compare
|
Okay I finally found time to rebase this again and reduce its size. Now there's no version checking anymore and it solely checks whether the DMD/LDC release comes with a DUB binary. |
41156d8 to
a810ff7
Compare
a810ff7 to
255fe46
Compare
- often interpreted as CWD with obviously problematic effects
- use ${parameter:+word} substitution to only add `:`
when PATH is not empty (not null)
| export LD_LIBRARY_PATH="$ROOT/$1/$libpath:\${LD_LIBRARY_PATH:-}" | ||
| export PATH="${DUB_BIN_PATH}${DUB_BIN_PATH:+:}$ROOT/$1/$binpath\${PATH:+:}\${PATH:-}" | ||
| export LIBRARY_PATH="$ROOT/$1/$libpath\${LIBRARY_PATH:+:}\${LIBRARY_PATH:-}" | ||
| export LD_LIBRARY_PATH="$ROOT/$1/$libpath\${LD_LIBRARY_PATH:+:}\${LD_LIBRARY_PATH:-}" |
There was a problem hiding this comment.
A trailing : means that ld.so would load shared libraries from the current working directory, thus hiding system wide shared libraries :o.
|
Changed a few things, could you have a look @wilzbach. |
CI was failing with: -> I escaped the parameter 😉
Wow good catch. I like the |
Can't reproduce this. Added tests for it to let Travis verify this.
Added a check. My main motivation was really just to avoid unnecessary downloads on Travis
Now the
dubfolders shouldn't been written to theactivatescripts anymore.Sorry about that :/