rpms/geda-gnetlist/FC-6 geda-gnetlist-20061020-backend-list.patch, NONE, 1.1 geda-gnetlist.spec, 1.5, 1.6
Chitlesh GOORAH (chitlesh)
fedora-extras-commits at redhat.com
Sat Jan 13 16:06:47 UTC 2007
Author: chitlesh
Update of /cvs/extras/rpms/geda-gnetlist/FC-6
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv8049/FC-6
Modified Files:
geda-gnetlist.spec
Added Files:
geda-gnetlist-20061020-backend-list.patch
Log Message:
auto-import geda-gnetlist-20061020-2 on branch FC-6 from geda-gnetlist-20061020-2.src.rpm
geda-gnetlist-20061020-backend-list.patch:
--- NEW FILE geda-gnetlist-20061020-backend-list.patch ---
? gnetlist.log
? src/gnetlist.log
Index: docs/gnetlist.1
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gnetlist/docs/gnetlist.1,v
retrieving revision 1.4
diff -u -3 -r1.4 gnetlist.1
--- docs/gnetlist.1 21 Jan 2006 21:48:24 -0000 1.4
+++ docs/gnetlist.1 9 Nov 2006 17:42:37 -0000
@@ -93,7 +93,7 @@
Verbose mode on. This mode gives as much feedback to the user as possible. (optional)
.TP 8
.B -g guile_procedure
-Specify the guile procedure which is executed to create the netlist.
+Specify the guile procedure which is executed to create the netlist. Use "-g help" to display a list of available backends.
.TP 8
.B -o output_filename
Specify the filename which will contain the netlist generated by gnetlist. If this option is not specified the default filename is "output.net".
Index: src/gnetlist.c
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gnetlist/src/gnetlist.c,v
retrieving revision 1.53
diff -u -3 -r1.53 gnetlist.c
--- src/gnetlist.c 7 Sep 2006 02:41:28 -0000 1.53
+++ src/gnetlist.c 9 Nov 2006 17:42:37 -0000
@@ -21,6 +21,9 @@
#include <stdio.h>
#include <sys/param.h>
+#include <sys/types.h>
+#include <errno.h>
+#include <dirent.h>
#ifdef HAVE_STRING_H
#include <string.h>
#endif
@@ -28,6 +31,7 @@
#include <unistd.h>
#endif
+
#include <libgeda/libgeda.h>
#include "../include/globals.h"
@@ -37,6 +41,8 @@
#include <dmalloc.h>
#endif
+#define BACKEND_LIST_COLS 3
+
void gnetlist_quit(void)
{
s_clib_free();
@@ -48,6 +54,53 @@
g_slist_free (backend_params);
}
+/** @brief Prints a list of all installed gnetlist backends to standard output.
+ *
+ * @param current Pointer to the toplevel struct.
+ */
+void gnetlist_backends(TOPLEVEL *current)
+{
+ DIR *schemedir;
+ struct dirent *entry;
+ char *filename;
+ int n;
+
+ schemedir=opendir(current->scheme_directory);
+ if(schemedir==NULL) {
+ fprintf(stderr, "\nERROR! Can't open directory %s: %s\n",
+ current->scheme_directory,
+ strerror(errno));
+ return;
+ }
+
+ printf("List of available backends:\n\n");
+
+ n=1;
+ while(1) {
+ entry=readdir(schemedir);
+ if(entry==NULL) break;
+
+ filename=strdup(entry->d_name);
+
+ if(g_str_has_prefix(filename, "gnet-")&&
+ g_str_has_suffix(filename, ".scm")) {
+
+ /* strip the suffix */
+ filename[strlen(filename)-4]='\0';
+ /* and skip the prefix */
+ printf("%-25s", &filename[5]);
+ if(n>=BACKEND_LIST_COLS) {
+ printf("\n");
+ n=0;
+ }
+ n++;
+ }
+
+ free(filename);
+ }
+ printf("\n");
+}
+
void main_prog(void *closure, int argc, char *argv[])
{
int i;
@@ -139,6 +192,13 @@
s_rename_init();
+ if(guile_proc!=NULL) {
+ if(!strcmp(guile_proc, "help")) {
+ gnetlist_backends(pr_current);
+ exit(0);
+ }
+ }
+
i = argv_index;
while (argv[i] != NULL) {
gchar *filename;
Index: src/parsecmd.c
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gnetlist/src/parsecmd.c,v
retrieving revision 1.24
diff -u -3 -r1.24 parsecmd.c
--- src/parsecmd.c 16 Jul 2006 02:11:31 -0000 1.24
+++ src/parsecmd.c 9 Nov 2006 17:42:37 -0000
@@ -72,7 +72,8 @@
printf(" -l filename Load scheme file before loading backend\n");
printf(" -m filename Load scheme file after loading backend,\n");
printf(" but still before executing procedure\n");
- printf(" -g proc Scheme procedure to execute\n");
+ printf(" -g proc Scheme procedure to execute.\n");
+ printf(" Use '-g help' to list available backends.\n");
printf(" -o filename Output netlist filename\n");
printf(" -c string Execute string as a scheme script\n");
printf(" -O option Pass the given option to the backend\n");
Index: geda-gnetlist.spec
===================================================================
RCS file: /cvs/extras/rpms/geda-gnetlist/FC-6/geda-gnetlist.spec,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- geda-gnetlist.spec 3 Nov 2006 20:13:38 -0000 1.5
+++ geda-gnetlist.spec 13 Jan 2007 16:06:17 -0000 1.6
@@ -2,7 +2,7 @@
Name: geda-gnetlist
Version: 20061020
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: Netlister for the gEDA project
Group: Applications/Engineering
@@ -11,8 +11,9 @@
URL: http://www.geda.seul.org/tools/gnetlist/index.html
Source: ftp://ftp.geda.seul.org/pub/geda/devel/%{version}/%{name}-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+Patch0: geda-gnetlist-20061020-backend-list.patch
-BuildRequires: libgeda-devel, libstroke-devel, geda-symbols
+BuildRequires: libgeda-devel, libstroke-devel, geda-symbols, groff
Requires: geda-symbols
%description
@@ -29,7 +30,31 @@
%prep
%setup -q
+%patch0 -p0
+
+# use of guile-1.6
+cp -p configure configure.guile16
+sed -i "s|guile|guile-1.6|" configure
+sed -i "s|guile-1.6-config|guile-config-1.6|" configure src/create_proto
+sed -i "s|guile-1.6-tools|guile-tools-1.6|" configure
+sed -i "s|ac_cv_lib_guile-1.6|ac_cv_lib_guile|" configure
+sed -i "s|-lguile-1.6|-lguile16|" configure
+sed -i "s|guile-1.6version|guileversion|" configure
+sed -i "s|#include <libguile-1.6.h>|#include <libguile16.h>|" configure
+
+# v20061020 : file: include/libgeda.h
+# Keep timestamps for files not needed to be modified
+for f in `find . -name \*.h -or -name \*.c` ; do
+ if grep -q libguile $f ; then
+ sed -i.guile16 -e 's|libguile.h|libguile16.h|' $f
+ fi
+ if grep -q 'guile/' $f ; then
+ sed -i 's|guile/\(.*\)h|guile16/\1h|' $f
+ fi
+done
+
%build
+
%configure --with-docdir=%{gedadocdir}
%{__make} %{?_smp_mflags}
@@ -74,6 +99,11 @@
%{gedadocdir}/man/gnetlist.html
%Changelog
+* Mon Jan 08 2007 Chitlesh Goorah <chitlesh at fedoraproject.org> - 20061020-2
+- rebuilt under compat-guile-16
+- gnetlist patch that adds "-g help" option
+- added groff to BR
+
* Thu Nov 02 2006 Chitlesh Goorah <chitlesh at fedoraproject.org> - 20061020-1
- Upstream release 20061020
More information about the fedora-extras-commits
mailing list