1

I'm new to Ubuntu (2 weeks trial & error) but quickly learning. I'm running Windows Subsystem for Linux (WSL) on Windows 10 Home edition with 18.04.3 LTS (Bionic Beaver). GUI working fine via LXDE and UBUNTU-DESKTOP up and running. All software and packages up to date as per standard repositories via synaptic.

I have installed CMAKE-GUI latest version and successfully compiled and installed with that program and the console an app "eccodes" latest version. Now I want to adjust my environment variables so I can run the latest version of this app, instead of the older version installed.

I have gone over related threads here and there and here and checked-out the official manual here; https://help.ubuntu.com/community/EnvironmentVariables

So I added a .sh file in /etc/profile.d named "extra_parameters_Herman.sh"

And put in the line

export ECCODES_PATH=/tmp/build_eccodes.2.14.1

When I run printenv after logging off/on I get (snippet)

.. ECCODES_PATH=/tmp/build_eccodes.2.14.1 ..

But my Ubuntu doesn't buy it. I'm still at eccodes version 2.6 instead of 2.14. A screenshot of the target directory is included.

I have tried for a day now and got stuck. So any help is appreciated!

screenshot eccodes folder

Herman
  • 11
  • What do you mean by "doesn't buy it"? How are you running the app and/or the subsystem when it doesn't get this setting? – tripleee Nov 21 '19 at 12:02
  • For what it's worth /etc/profile.d is for all shells, not just Bash, so you should not use export variable=value syntax. Instead, put just variable=value and then export variable on a separate line. – tripleee Nov 21 '19 at 12:03
  • @triplee thanks for the super swift reply! The eccodes app works with console commands like: grib_copy infile.grb outfile.grb but could you please be more specific how to define the path using variable-value and export variable using an example? That would be much appreciated! – Herman Nov 21 '19 at 12:07
  • That doesn't seem to attempt to answer the question in my first comment. You should probably [edit] your question to explain how exactly you run those commands if not from within an environment where printenv does what you expected. – tripleee Nov 21 '19 at 12:09
  • Fair point on how to run the app. To test I just run the command grib_copy out_new.grb2 out_new6.grb and the out_new6.grb file got created as it should, thanks! But I'm still puzzled why synaptic shows the old version of the app and not the new version. – Herman Nov 21 '19 at 12:26
  • 1
    Synaptic (and apt, and dpkg) don't know about software that you install from source (unless you use something like checkinstall to create a local .deb package and install that) – steeldriver Nov 21 '19 at 12:41
  • @Steelddriver thanks for that disclaimer, I missed that info. My app works as it should but the package version info is not updated. Thanks both posters for the help. This can question be closed. – Herman Nov 21 '19 at 12:59

0 Answers0