It looks complicated but it's all 3 mysql commands to get a complete table with whatever data you want from the winapi stats data in a nice table...
Take the attached file (it just strips some text) , create user as mysql user that has a db called winapi with CREATE TEMPORARY TABLE and select rights then run:
./tools/winapi/winapi_extract --pseudo-stub-statistics --no-verbose --no-progress >winapi_stats.txt php winapi_stats.php > winapi_stats,dat
mysql --execute=' CREATE TEMPORARY TABLE `winapi` ( `module` VARCHAR( 255 ) NOT NULL , `stubs` INT NOT NULL , `total_func` INT NOT NULL , `real_stub` INT NOT NULL , `psedo_stubs` INT NOT NULL , `forwards` INT NOT NULL , PRIMARY KEY ( `module` ) );
LOAD DATA LOCAL INFILE "winapi_stats,dat" REPLACE INTO TABLE winapi FIELDS TERMINATED BY "~" LINES TERMINATED BY "\n";
SELECT "Total" "Library", sum(total_func) "API Count",
(sum(total_func) - sum(stubs)) / sum(total_func) *100 "% implemented", sum(stubs) "Total Stubs", sum(real_stub), sum(psedo_stubs) FROM winapi UNION ALL SELECT module "Library", total_func "API Count", ( total_func - stubs ) / total_func *100 "% implemented", stubs "Total Stubs", real_stub, psedo_stubs FROM winapi; ' -u user -D winapi -H
/lostwages/templates/en/winapi_stats.html
comments?
p.s. sorry for the yahoo and the linewrap mess my mail dosn't send latly...
On Wed, 24 Mar 2004, hatky wrote:
It looks complicated but it's all 3 mysql commands to get a complete table with whatever data you want from the winapi stats data in a nice table...
[...]
comments?
Yeah, there's no need for a database. Right now Francois' soluions works perfectly fine without a DB, please don't use one. I say this is not acceptable, but is up to laxdragon, he's the website maintainer.
On Wed, 2004-03-24 at 14:19, Dimitrie O. Paun wrote:
On Wed, 24 Mar 2004, hatky wrote:
It looks complicated but it's all 3 mysql commands to get a complete table with whatever data you want from the winapi stats data in a nice table...
[...]
comments?
Yeah, there's no need for a database. Right now Francois' soluions works perfectly fine without a DB, please don't use one. I say this is not acceptable, but is up to laxdragon, he's the website maintainer.
I'd rather there wasn't a DB. I know it saved time and effort coding wise to do it this way. Future changes will require updates to the db, and that can't be automated the way the current scripts are.
On Wed, 24 Mar 2004, hatky wrote:
It looks complicated but it's all 3 mysql commands to get a complete table with whatever data you want from the winapi stats data in a nice table...
[...]
Maybe this is already done but it's not clear from the script to me.. doe sthe script filter out the Wine-only dlls? Otherwise the global statistics will be off.
Specifically, the following dlls should be ignored:
ole2prox ? ole2thk ? psapi ? twain_32 ? wine* x11drv
I'm not sure anymore for the dlls marked with a question mark.