Mercurial > flash_v2
changeset 1482:111c2191e6f5
* ecos.db: Add 'hardware' attribute to CYGPKG_DEVS_ETH_ARM_KS32C5000.
* ecosadmin.tcl: Delete empty directories in the repository following
eCos package removal. Read the hardware attribute from package records
in ecos.db.
| author | jld |
|---|---|
| date | Fri, 30 Jan 2004 10:26:17 +0000 |
| parents | ba7fea8efa2f |
| children | dc0016c597aa |
| files | host/tools/configtool/standalone/wxwin/mainwin.cpp packages/ChangeLog packages/ecos.db packages/ecosadmin.tcl |
| diffstat | 4 files changed, 27 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/host/tools/configtool/standalone/wxwin/mainwin.cpp +++ b/host/tools/configtool/standalone/wxwin/mainwin.cpp @@ -552,7 +552,7 @@ void ecMainFrame::OnAbout(wxCommandEvent // ecAboutDialog dialog(this, ecID_ABOUT_DIALOG, _("About eCos Configuration Tool")); // dialog.ShowModal(); wxString msg; - msg.Printf("eCos Configuration Tool %s (%s %s)\n\nCopyright (c) Red Hat, Inc. 1998-2002\nCopyright (c) John Dallaway 2003\nCopyright (C) eCosCentric Limited 2004", ecCONFIGURATION_TOOL_VERSION, __DATE__, __TIME__); + msg.Printf("eCos Configuration Tool %s (%s %s)\n\nCopyright (c) Red Hat, Inc. 1998-2002\nCopyright (c) John Dallaway 2003\nCopyright (c) eCosCentric Limited 2004", ecCONFIGURATION_TOOL_VERSION, __DATE__, __TIME__); wxMessageBox(msg, _("About eCos Configuration Tool"), wxICON_INFORMATION | wxOK); }
--- a/packages/ChangeLog +++ b/packages/ChangeLog @@ -1,3 +1,11 @@ +2004-01-30 John Dallaway <jld@ecoscentric.com> + + * ecos.db: Add 'hardware' attribute to CYGPKG_DEVS_ETH_ARM_KS32C5000. + + * ecosadmin.tcl: Delete empty directories in the repository following + eCos package removal. Read the hardware attribute from package records + in ecos.db. + 2004-01-19 Nick Garnett <nickg@calivar.com> * ecos.db: Added FAT12/16 filesystem packages.
--- a/packages/ecos.db +++ b/packages/ecos.db @@ -11,6 +11,7 @@ ## ------------------------------------------- ## This file is part of eCos, the Embedded Configurable Operating System. ## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. +## Copyright (C) 2004 eCosCentric Limited ## ## eCos is free software; you can redistribute it and/or modify it under ## the terms of the GNU General Public License as published by the Free @@ -1343,6 +1344,7 @@ package CYGPKG_DEVS_ETH_ARM_EDB7XXX { package CYGPKG_DEVS_ETH_ARM_KS32C5000 { alias { "Samsung KS32C5000 ethernet driver" eth_ks32c5000 } + hardware directory devs/eth/arm/ks32c5000 script ks32c5000_eth.cdl description "Ethernet driver for Samsung ks32c5000/S3c4510."
--- a/packages/ecosadmin.tcl +++ b/packages/ecosadmin.tcl @@ -19,6 +19,7 @@ ## This file is part of eCos, the Embedded Configurable Operating System. ## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. ## Copyright (C) 2003 John Dallaway +## Copyright (C) 2004 eCosCentric Limited ## ## eCos is free software; you can redistribute it and/or modify it under ## the terms of the GNU General Public License as published by the Free @@ -555,6 +556,7 @@ proc ecosadmin::read_data { silentflag } set_package_data "$name,alias" "" set_package_data "$name,versions" "" set_package_data "$name,dir" "" + set_package_data "$name,hardware" 0 set ::current_package $name eval $body set ::current_package "" @@ -599,10 +601,13 @@ proc ecosadmin::read_data { silentflag } } } + proc hardware { } { + set_package_data "$::current_package,hardware" 1 + } + proc description { str } { } proc disable { str } { } proc enable { str } { } - proc hardware { } { } proc script { str } { } proc set_value { str1 str2 } { } } @@ -1036,7 +1041,16 @@ proc ecosadmin::filter_old_packages { ol if { [ catch { file delete -force -- $package_dir } message ] != 0 } { # issue a warning if package deletion failed - this is not fatal ecosadmin::warning $message - } + } + set dir [ file dirname $package_dir ] + while { [ llength [ glob -nocomplain -- [ file join $dir "*" ] ] ] == 0 } { + # the parent of the deleted directory is now empty so delete it + if { [ catch { file delete -- $dir } message ] != 0 } { + # issue a warning if empty directory deletion failed - this is not fatal + ecosadmin::warning $message + } + set dir [ file dirname $dir ] + } } }
