Skip to content

Commit

Permalink
lshw: fix built-in version info
Browse files Browse the repository at this point in the history
Currently lshw says its version is "unknown". Make it report the current
package version instead.

(cherry picked from commit e570198)
  • Loading branch information
bjornfor committed Sep 30, 2017
1 parent 4da6934 commit f50e146
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pkgs/tools/system/lshw/default.nix
Expand Up @@ -19,6 +19,12 @@ stdenv.mkDerivation rec {
sha256 = "147wyr5m185f8swsmb4q1ahs9r1rycapbpa2548aqbv298bbish3";
})];

# Fix version info.
preConfigure = ''
sed -e "s/return \"unknown\"/return \"${version}\"/" \
-i src/core/version.cc
'';

buildInputs = lib.optionals withGUI [ gtk2 pkgconfig sqlite ];

makeFlags = [ "PREFIX=$(out)" ];
Expand Down

0 comments on commit f50e146

Please sign in to comment.