-
Notifications
You must be signed in to change notification settings - Fork 90
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
Fix --enabled-shared for configure #1984
Conversation
Automatically set the target to the shared object, if we are building the shared object. This removes the need to call `make shared` after configuring with `--enable-shared`.
Very nice, thanks @dschwoerer ! 🎉 It's might also be possible to use the gold linker to speed things up further. I did attempt this awhile ago: https://github.com/boutproject/BOUT-dev/tree/use-gold-travis We probably want at least one Travis build to build static instead of shared. There can be issues of differences in symbol visibility between static/shared, so it would be good to try and catch these if possible. |
Any preferences on which job should be static? |
Ideally we'd have it be a separate job, but that's probably a waste of resources! Let's make the GCC7 job static, for lack of an obvious choice. Also, does |
I don't think |
Yeah, missing backtraces don't matter so much, as I'll likely just run it locally in gdb anyway.
Sounds reasonable! |
Coverage tests are failing:
Push tests don't run the coverage jobs which is why they pass. I'm a bit confused because we definitely have |
Need modified make.config.in
@@ -300,7 +300,7 @@ $(SOURCEC:%.cxx=%.o): $(LIB)
$(TARGET): | $(DIRS)
$(TARGET): makefile $(BOUT_CONFIG_FILE) $(OBJ) $(SUB_LIBS)
@echo " Linking" $(TARGET)
- @$(LD) $(LDFLAGS) -o $(TARGET) $(OBJ) $(SUB_LIBS) $(BOUT_LIBS)
+ @$(LD) -o $(TARGET) $(OBJ) $(SUB_LIBS) $(BOUT_LIBS) $(LDFLAGS)
checklib:
ifneq ("$(CHANGED)foo", "foo") This is to make sure A second issue is that in the current form,
|
* Add $(LDFLAGS) to the so creation * LIB_A should be created as static archive, never the so * If creating the lib fails, we don't want to keep the broken lib * LDFLAGS should be at the end when linking
Thanks for finding these issues 👍 |
Thanks for sorting this out 🎉 Just to note that there were a bunch of unrelated changes to |
Yes, I sometimes try to minimise the changes, but not always. If this is something that bothers you, I can try to pay more attention / use whatever autoconf we determine as official one ... |
It's tricky because there's not been an official Having said that, someone has secured funding to try and release 2.70 hopefully soonish. To be honest, unintended changes are not a major problem, it's just tricky to work out if a change has been "forward" or "backward"! |
Hi It seems like I'm unable to configure after this change, although it looks like it's working fine in 958f685 (the Now
yields
Trying something similar to the travis script (as far as I'm able to read from the travis build)
and even
yields the same. I'm running on a |
I tried on ubuntu:latest, but was not able to reproduce the issue.
I did:
apt-get update
apt-get install git make mpich-dev # failed
apt-get install git make # not needed
sudo apt-get install python3 python3-distutils python3-pip python3-numpy
python3-netcdf4 python3-scipy mpich libmpich-dev libfftw3-dev
libnetcdf-dev libnetcdf-cxx-legacy-dev git g++ make # failed
apt-get install python3 python3-distutils python3-pip python3-numpy
python3-netcdf4 python3-scipy mpich libmpich-dev libfftw3-dev
libnetcdf-dev libnetcdf-cxx-legacy-dev git g++ make
git clone https://github.com/boutproject/BOUT-dev/ && cd /BOUT-dev &&
git checkout next && ./configure # no error
Not sure why it broke for you ...
|
Oh, sorry @dschwoerer. I mixed my github action running on My dev environment is basically Reading from the Do you think this error is compiler related?
|
you wouldn't happen to have instructions on how to build all deps?
|
There is gcc 9.3, which is a bug fix release for 9.2, so wouldn't hurt to upgrade. However, I strongly doubt we are doing any thing that has a fair chance of triggering a bug during configure -.- I guess I never tested the case where native |
I tried again, but couldn't get gcc on alpine to work:
However, gcc fails with
And without a compiler I cannot even build & install any missing dependencies -.- |
Thanks for helping out @dschwoerer. Running
works without throwing the errors you mention above. Could it be that you are missing the |
Yes, that was the issue.
Can you share the image? I don't have that much spare CPU time to build
all dependencies ...
|
I think I can reproduce. The issue is due to dash not supporting +=
Will submit a fix, thanks for reporting.
|
Awesome 🥳, thanks 🎉. docker pull loeiten/bout_dev:latest |
Fix #1126
Switch all builds to shared object. That decreases the build time. (roughly 5 mins for each build, total ~30 min)
Disabling debug infos also should help decrease the sizes, and thus build time. However, not as strong of an effect as I hoped.