This commit is contained in:
Ludovic Jacomme 2002-04-04 13:43:26 +00:00
parent d57d6f4f62
commit 4ecbd81b66
6 changed files with 330 additions and 0 deletions

View File

@ -0,0 +1 @@
SUBDIRS = src man1

View File

@ -0,0 +1,32 @@
dnl Process this file with autoconf to produce a configure script.
AC_INIT(src/alcbanner.c)
ALCBANNER_MAJOR_VERSION=1
ALCBANNER_MINOR_VERSION=1
ALCBANNER_VERSION=$ALCBANNER_MAJOR_VERSION.$ALCBANNER_MINOR_VERSION
AC_SUBST(ALCBANNER_MAJOR_VERSION)
AC_SUBST(ALCBANNER_MINOR_VERSION)
AC_SUBST(ALCBANNER_VERSION)
# For automake.
VERSION=$ALCBANNER_VERSION
PACKAGE=alcbanner
dnl Initialize automake stuff
AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
dnl Checks for programs.
AC_PROG_CC
AC_PROG_MAKE_SET
dnl Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AM_ALLIANCE
AC_OUTPUT([
Makefile
man1/Makefile
src/Makefile
])

View File

@ -0,0 +1,2 @@
man_MANS = alcbanner.1
EXTRA_DIST = $(man_MANS)

View File

@ -0,0 +1,105 @@
.\"
.\" This file is part of the Alliance CAD System
.\" Copyright (C) Laboratoire LIP6 - Département ASIM
.\" Universite Pierre et Marie Curie
.\"
.\" Home page : http://www-asim.lip6.fr/alliance/
.\" E-mail support : mailto:alliance-support@asim.lip6.fr
.\"
.\" This progam 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 Software Foundation; either version 2 of the License, or (at your
.\" option) any later version.
.\"
.\" Alliance VLSI CAD System is distributed in the hope that it will be
.\" useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
.\" Public License for more details.
.\"
.\" You should have received a copy of the GNU General Public License along
.\" with the GNU C Library; see the file COPYING. If not, write to the Free
.\" Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
.\"
.\"
.\" Tool : alcbanner front end
.\" Date : 1996,97
.\" Author : Czo <Olivier.Sirol@lip6.fr>
.\"
.TH ALCBANNER 1 "October 1, 1997" "ASIM/LIP6" "ALLIANCE USER COMMANDS"
.SH NAME
\fBalcbanner\fP \- Display a standardized banner for Alliance tools
.so man1/alc_origin.1
.SH SYNOPSIS
.TP
\f4alcbanner\fR \fItool toolversion purpose copyrightdates\fR
.SH DESCRIPTION
\f4alcbanner\fR display on \f4stdout\fP a standardized banner for the Alliance
tools.
This is a compiled version of the \f4alliancebanner\fR(2) function.
.SH EXAMPLE
.RS
\f4alcbanner GenPat 3.1 "Procedural GENeration of test PATterns" 1991\fR
.RE
will display :
.ft 4
.nf
@@@@ @ @@@@@@@
@@ @@ @@ @@ @
@@ @ @@ @@ @@
@@ @@@@@ @@@ @@@ @@ @@ @@@@ @@
@@ @ @ @@@ @ @@ @@ @@ @ @@@@@@@@
@@ @@@@@ @@ @@ @@ @@ @@@@@ @@ @@ @@
@@ @ @@ @@@@@@@@@ @@ @@ @@ @@@@@ @@
@@ @ @@ @@ @@ @@ @@ @@ @@ @@
@@ @@ @@ @ @@ @@ @@ @@ @@ @@
@@ @@ @@ @@ @@ @@ @@ @@ @@@ @@ @
@@@@ @@@@ @@@@ @@@@ @@@@@@ @@@@ @@ @@@@
Procedural GENeration of test PATterns
Alliance CAD System 3.2b, genpat 3.1
Copyright (c) 1991-1997, ASIM/LIP6/UPMC
E-mail support: alliance-support@asim.lip6.fr
.fi
.ft R
.SH SEE ALSO
.PP
.BR mbk(1)
.BR alliancebanner (3).
.SH DIAGNOSTICS
The output is centered for a 80 columns screen, so it can be used on most
display easilly, and not found at execution time.
\f4alliancebanner: Error: Resulting size bigger than 80 columns not allowed\fR
.RS
The \fItool\fR argument must be such that its resulting size isn't wider that
80 culumns.
This means, since the character set is proportional, that the longest name
to be output is about 8 characters long.
.RE
\f4alliancebanner: Error: Character out of [0-9A-Za-z] range\fR
.RS
The \fItool\fR parameter has a non allowed character in it.
For simplicity purposes, only numbers and letters are accepted.
.RE
.so man1/alc_bug_report.1

View File

@ -0,0 +1,10 @@
## Process this file with automake to produce Makefile.in
bin_PROGRAMS = alcbanner
CFLAGS = @ALLIANCE_CFLAGS@ -DALLIANCE_VERSION=\"@ALLIANCE_VERSION@\"
alcbanner_LDADD = @ALLIANCE_LIBS@ \
-lMut
alcbanner_SOURCES = alcbanner.c

View File

@ -0,0 +1,180 @@
/*
* This file is part of the Alliance CAD System
* Copyright (C) Laboratoire LIP6 - Département ASIM
* Universite Pierre et Marie Curie
*
* Home page : http://www-asim.lip6.fr/alliance/
* E-mail support : mailto:alliance-support@asim.lip6.fr
*
* This progam 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 Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* Alliance VLSI CAD System is distributed in the hope that it will be
* useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
* Public License for more details.
*
* You should have received a copy of the GNU General Public License along
* with the GNU C Library; see the file COPYING. If not, write to the Free
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/*
*
* Tool : alcbanner front end
* Date : 1996,97
* Author : Czo <Olivier.Sirol@lip6.fr>
*/
#ident "$Id: alcbanner.c,v 1.1 2002/04/04 13:43:26 ludo Exp $"
/*
* ####===========================================================####
* ## ##
* ## Include Files ##
* ## ##
* ####===========================================================####
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
/* for getopt #include <getopt.h> would be best */
#include <unistd.h>
extern char *optarg;
extern int optind, opterr, optopt;
#include MUT_H
/*
* ####===========================================================####
* ## ##
* ## Constants ##
* ## ##
* ####===========================================================####
*/
/*
* ####===========================================================####
* ## ##
* ## Types ##
* ## ##
* ####===========================================================####
*/
/*
* ####===========================================================####
* ## ##
* ## Variables ##
* ## ##
* ####===========================================================####
*/
char * BAN_Program_name;
/*
* ####===========================================================####
* ## ##
* ## Functions ##
* ## ##
* ####===========================================================####
*/
/*================================================================####
* Fpt Usage
*
*/
void
ban_usage ()
{
printf ("\
Usage : \n\
%s \"ToolName\" \"ToolVersion\" \"ToolPurpose\" \"ToolDate\" \n\
\n\
", BAN_Program_name);
}
/*================================================================####
* Main
*
*/
int
main (argc, argv)
int argc;
char *argv[];
{
int parsed_option;
int arguments_left;
char * ToolName;
char * ToolVersion;
char * ToolPurpose;
char * ToolDate;
mbkenv ();
BAN_Program_name = mbkstrdup (argv[0]);
while ((parsed_option = getopt (argc, argv, "h")) != -1)
{
/* printf("Val renv : '%c' pour '%c' \n",parsed_option, optopt); */
switch (parsed_option)
{
case 'h':
default:
ban_usage ();
fprintf ( stderr, "## %s ERROR : Bad command line.\n" , BAN_Program_name);
EXIT (1);
break;
}
}
/* Apres process des switches il reste des command line arguments */
/* numerotes argv[optind+i] avec i=0..arguments_left-1 */
arguments_left = argc - optind;
if (arguments_left != 4)
{
ban_usage ();
fprintf ( stderr, "## %s ERROR : Need 4 args on command line.\n" , BAN_Program_name);
EXIT (1);
}
else
{
ToolName = mbkstrdup (argv[optind ]);
ToolVersion = mbkstrdup (argv[optind + 1]);
ToolPurpose = mbkstrdup (argv[optind + 2]);
ToolDate = mbkstrdup (argv[optind + 3]);
}
alliancebanner (ToolName,
ToolVersion,
ToolPurpose,
ToolDate,
ALLIANCE_VERSION);
return (0);
}