powertop-2.9:ver.bump

This commit is contained in:
Rmys
2018-03-29 13:55:19 +03:00
parent 09f9b57cb9
commit e325d891a8
3 changed files with 54 additions and 1 deletions
+8
View File
@@ -6,11 +6,19 @@
from pisi.actionsapi import autotools from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools from pisi.actionsapi import pisitools
from pisi.actionsapi import shelltools
from pisi.actionsapi import libtools
from pisi.actionsapi import get from pisi.actionsapi import get
def setup(): def setup():
shelltools.system("sed -i 's:RUN-VERSION-SCRIPT-IN-GIT-REPOSITORY-ONLY:v2.9:' scripts/version")
shelltools.system("./autogen.sh")
autotools.configure() autotools.configure()
pisitools.dosed("libtool", " -shared ", " -Wl,-O1,--as-needed -shared ")
def build(): def build():
autotools.make() autotools.make()
@@ -0,0 +1,35 @@
diff --git a/src/parameters/persistent.cpp b/src/parameters/persistent.cpp
index 9a5688a..6a232cd 100644
--- a/src/parameters/persistent.cpp
+++ b/src/parameters/persistent.cpp
@@ -145,9 +145,6 @@ void save_parameters(const char *filename)
// printf("result size is %i, #parameters is %i \n", (int)past_results.size(), (int)all_parameters.parameters.size());
- if (!global_power_valid())
- return;
-
pathname = get_param_directory(filename);
file.open(pathname, ios::out);
@@ -156,12 +153,15 @@ void save_parameters(const char *filename)
return;
}
- map<string, int>::iterator it;
+ if (global_power_valid())
+ {
+ map<string, int>::iterator it;
- for (it = param_index.begin(); it != param_index.end(); it++) {
- int index;
- index = it->second;
- file << it->first << "\t" << setprecision(9) << all_parameters.parameters[index] << "\n";
+ for (it = param_index.begin(); it != param_index.end(); it++) {
+ int index;
+ index = it->second;
+ file << it->first << "\t" << setprecision(9) << all_parameters.parameters[index] << "\n";
+ }
}
file.close();
}
+11 -1
View File
@@ -12,12 +12,15 @@
<IsA>app:console</IsA> <IsA>app:console</IsA>
<Summary>Power consumption monitor</Summary> <Summary>Power consumption monitor</Summary>
<Description>PowerTOP is a Linux tool that finds the software component(s) that make your computer use more power than necessary while it is idle.</Description> <Description>PowerTOP is a Linux tool that finds the software component(s) that make your computer use more power than necessary while it is idle.</Description>
<Archive sha1sum="60da464a0c5d39c64b5d4a0e854bc6c480f8927a" type="targz">https://01.org/sites/default/files/downloads/powertop/powertop-2.8.tar.gz</Archive> <Archive sha1sum="12f5fc5f5cb776a08d11fac75114637b1c215fc6" type="targz">https://github.com/fenrus75/powertop/archive/v2.9.tar.gz</Archive>
<BuildDependencies> <BuildDependencies>
<Dependency>libnl-devel</Dependency> <Dependency>libnl-devel</Dependency>
<Dependency>ncurses-devel</Dependency> <Dependency>ncurses-devel</Dependency>
<Dependency>pciutils-devel</Dependency> <Dependency>pciutils-devel</Dependency>
</BuildDependencies> </BuildDependencies>
<Patches>
<Patch>powertop-2.7-always-create-params.patch</Patch>
</Patches>
</Source> </Source>
<Package> <Package>
@@ -39,6 +42,13 @@
</Package> </Package>
<History> <History>
<Update release="3">
<Date>2018-02-25</Date>
<Version>2.9</Version>
<Comment>Version bump.</Comment>
<Name>Pisi Linux Community</Name>
<Email>admin@pisilinux.org</Email>
</Update>
<Update release="2"> <Update release="2">
<Date>2017-04-05</Date> <Date>2017-04-05</Date>
<Version>2.8</Version> <Version>2.8</Version>