Discussion:
[geda-user] garchive does not include symbols?
Abhijit Kshirsagar
2014-09-11 18:07:42 UTC
Permalink
I tried using garchive to package a project and found that
gschem-archive (in the tar.gz archive) is always empty
I've tried the example invocation (console output included below) but
symbols never make it into the archive.
This is on geda 1.9 (compiled from source), figured i'd ask around
before diving into python.

$> garchive -v -o ProjectArchive.tar.gz README page-1.sch page-2.sch
---- Now in CreateArchiveFileList.
---- Examining files listed on command line
---- Examining /home/proj-directory/README for inclusion in archive
---- Examining /home/proj-directory/page-1.sch for inclusion in archive
---- Examining /home/proj-directory/page-2.sch for inclusion in archive
---- Examining files listed in garchiverc
---- Examining /home/proj-directory/page-1.sch for inclusion in archive
---- Examining /home/proj-directory/page-2.sch for inclusion in archive
---- Now in GetLibraryPath.
---- Processing system resource file /usr/local/share/gEDA/system-gafrc
---- Processing local resource file /home/proj-directory/gschemrc
---- Now in CreateSchemFileList.
---- Now in CreateSymbolFileList.
---- Now in CreateSPICEFIleList.
---- Cd into /tmp for remainder of work.
---- Now in UpdateSchemFileList.
---- Now in SaveSymbols.
---- Now in SaveSPICEFiles.
---- Files to archive: gschemrc garchiverc gschem-files README
page-1.sch page-2.sch
---- Now in UpdateRC.
---- Creating archive in /tmp directory.
gzip: ProjectArchive.tar.gz already exists; do you wish to overwrite (y or n)? y
---- Moving archive into local directory.
/home/proj-directory/ProjectArchive.tar.gz already exists. Overwrite? [y/N] y
gEDA archive /home/proj-directory/ProjectArchive.tar.gz created successfully!

Abhijit
Алексей Харьковский
2014-09-11 18:35:35 UTC
Permalink
For including symbols in project you can using library section patch and
utilities.
This patch make possible to create schematic files with library sections
which includes all used symbols.
By lib_sec_utils.py you may extracted symbols from schematic file, replace,
rename and etc.
Try and vote : https://bugs.launchpad.net/geda/+bug/1290129
Post by Abhijit Kshirsagar
I tried using garchive to package a project and found that
gschem-archive (in the tar.gz archive) is always empty
I've tried the example invocation (console output included below) but
symbols never make it into the archive.
This is on geda 1.9 (compiled from source), figured i'd ask around
before diving into python.
$> garchive -v -o ProjectArchive.tar.gz README page-1.sch page-2.sch
---- Now in CreateArchiveFileList.
---- Examining files listed on command line
---- Examining /home/proj-directory/README for inclusion in archive
---- Examining /home/proj-directory/page-1.sch for inclusion in archive
---- Examining /home/proj-directory/page-2.sch for inclusion in archive
---- Examining files listed in garchiverc
---- Examining /home/proj-directory/page-1.sch for inclusion in archive
---- Examining /home/proj-directory/page-2.sch for inclusion in archive
---- Now in GetLibraryPath.
---- Processing system resource file /usr/local/share/gEDA/system-gafrc
---- Processing local resource file /home/proj-directory/gschemrc
---- Now in CreateSchemFileList.
---- Now in CreateSymbolFileList.
---- Now in CreateSPICEFIleList.
---- Cd into /tmp for remainder of work.
---- Now in UpdateSchemFileList.
---- Now in SaveSymbols.
---- Now in SaveSPICEFiles.
---- Files to archive: gschemrc garchiverc gschem-files README
page-1.sch page-2.sch
---- Now in UpdateRC.
---- Creating archive in /tmp directory.
gzip: ProjectArchive.tar.gz already exists; do you wish to overwrite (y or n)? y
---- Moving archive into local directory.
/home/proj-directory/ProjectArchive.tar.gz already exists. Overwrite? [y/N] y
gEDA archive /home/proj-directory/ProjectArchive.tar.gz created successfully!
Abhijit
Abhijit Kshirsagar
2014-09-11 19:44:24 UTC
Permalink
For including symbols in project you can using library section patch and utilities.
Wow.. didn't realise the depth of the problem. Will need to read
through that discussion.

BTW: Figured out why garchive wasn't working - it wasn't reading the
per-user config from ~/.gEDA/gafrc
Once i added that it worked fine. I'll work on a patch over the
weekend. Its still not archiving the symbols from /usr/local/share/...
, I'll need to figure out why.

Is there a simple way of getting gschem to read the config files,
parse the schematic, and tell me where it would pull the symbols from?
Guess I could always do that in python, but with so many config files
(local gafrc and gschemrc, per user and system wide) it'd be great if
gschem could be persuaded to do it...

Thanks,
Abhijit
Алексей Харьковский
2014-09-12 16:10:59 UTC
Permalink
Is there a simple way of getting gschem to read the config files,
Post by Abhijit Kshirsagar
parse the schematic, and tell me where it would pull the symbols from?
Guess I could always do that in python, but with so many config files
(local gafrc and gschemrc, per user and system wide) it'd be great if
gschem could be persuaded to do it...
Symbols read by libgeda from always paths descripted in all rc-files.
Patch add this feature to libgeda, therefore it works in all projects,
which uses libgeda. Gshhem create file and add "----library section----" to
the end of it. All parts of GEDA project (exampls gsch2pcb) works with such
files too.

lib_sec_utils.py - python script worked with schematic file. It can save
symbols from -----library section---- of sch file to current dir or replace
symbol in ---------library section----- from current dir or other path or
can delete symbol from ---------library section-----or delete all symbols
and library section too for obtaining fully compatible sch-file with other
geda versions (without library section).

This script can be friends with gschem GUI by user schemma dialogs and
menus, but I did not know how.
Abhijit Kshirsagar
2014-09-19 05:28:25 UTC
Permalink
Not sure i follow.. Can someone break it down for me?
Abhijit
Алексей Харьковский
2014-09-19 17:14:17 UTC
Permalink
It works for me...
***@work ~ $ gschem --version
gEDA 1.9.0 (g55f875b)
Post by Abhijit Kshirsagar
Not sure i follow.. Can someone break it down for me?
Abhijit
Loading...