mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-23 00:43:28 +00:00
* Replace pkg-message about setting BABEL_DIR with a wrapper script
that does. * Remove misleading full path name from usage message. * Improve fgets() usage. * Add converters category. * Improve pkg-comment and pkg-descr.
This commit is contained in:
parent
1c4d2ad037
commit
9aee951f75
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=50855
@ -7,8 +7,8 @@
|
||||
|
||||
PORTNAME= babel
|
||||
PORTVERSION= 1.6
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= biology
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= biology converters
|
||||
MASTER_SITES= http://smog.com/chem/babel/files/ \
|
||||
http://www.ccl.net/cca/software/UNIX/babel/ \
|
||||
ftp://ccl.osc.edu/pub/chemistry/software/UNIX/babel/
|
||||
@ -18,14 +18,18 @@ MAINTAINER= ports@FreeBSD.org
|
||||
|
||||
MAKE_ARGS= CC="${CC}" CFLAGS="${CFLAGS}"
|
||||
|
||||
post-build:
|
||||
${SED} -e 's%@PREFIX@%${PREFIX}%g' \
|
||||
${FILESDIR}/babel.sh >${WRKSRC}/babel.sh
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/babel ${PREFIX}/bin
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/babel ${PREFIX}/libexec
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/babel.sh ${PREFIX}/bin/babel
|
||||
@${MKDIR} ${PREFIX}/share/babel
|
||||
${INSTALL_DATA} ${WRKSRC}/*.lis ${PREFIX}/share/babel
|
||||
.if !defined(NOPORTDOCS)
|
||||
@${MKDIR} ${PREFIX}/share/doc/babel
|
||||
${INSTALL_DATA} ${WRKSRC}/README.1ST ${PREFIX}/share/doc/babel
|
||||
.endif
|
||||
@${SED} -e 's:/usr/local:${PREFIX}:' ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
6
biology/babel/files/babel.sh
Normal file
6
biology/babel/files/babel.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
# $FreeBSD$
|
||||
|
||||
export BABEL_DIR=${BABEL_DIR-@PREFIX@/share/babel}
|
||||
|
||||
exec @PREFIX@/libexec/babel "$@"
|
@ -1,14 +1,17 @@
|
||||
--- menus.c.orig Tue Jan 21 23:52:36 1997
|
||||
+++ menus.c Mon Dec 22 14:29:37 1997
|
||||
|
||||
$FreeBSD$
|
||||
|
||||
--- menus.c.orig Tue Jan 21 16:52:36 1997
|
||||
+++ menus.c Sun Nov 18 16:43:32 2001
|
||||
@@ -63,9 +63,9 @@
|
||||
}
|
||||
}
|
||||
printf("Input file name : ");
|
||||
- gets(InfileName);
|
||||
+ fgets(InfileName, BUFF_SIZE - 1, stdin);
|
||||
+ fgets(InfileName, BUFF_SIZE, stdin);
|
||||
printf("Keywords : ");
|
||||
- gets(InputKeywords);
|
||||
+ fgets(InputKeywords, BUFF_SIZE - 1, stdin);
|
||||
+ fgets(InputKeywords, BUFF_SIZE, stdin);
|
||||
|
||||
if (strlen(InputKeywords) < 1)
|
||||
strcpy(InputKeywords,"KEYWORDS GO HERE");
|
||||
@ -17,23 +20,21 @@
|
||||
}
|
||||
printf("Output file name : ");
|
||||
- gets(OutfileName);
|
||||
+ fgets(OutfileName, BUFF_SIZE - 1, stdin);
|
||||
+ fgets(OutfileName, BUFF_SIZE, stdin);
|
||||
if (has_keywords)
|
||||
{
|
||||
printf("Keywords : ");
|
||||
- gets(OutputKeywords);
|
||||
+ fgets(OutputKeywords, BUFF_SIZE - 1, stdin);
|
||||
+ fgets(OutputKeywords, BUFF_SIZE, stdin);
|
||||
if (strlen(OutputKeywords) < 1)
|
||||
strcpy(OutputKeywords,"KEYWORDS GO HERE");
|
||||
}
|
||||
@@ -167,8 +167,8 @@
|
||||
@@ -167,7 +167,7 @@
|
||||
while (done == FALSE)
|
||||
{
|
||||
printf("Choice : ");
|
||||
- gets(choice_string);
|
||||
- for (i = 0; i < (int) strlen(choice_string); i++)
|
||||
+ fgets(choice_string, 99, stdin);
|
||||
+ for (i = 0; i < ((int) strlen(choice_string) - 1) ; i++)
|
||||
+ fgets(choice_string, sizeof(choice_string), stdin);
|
||||
for (i = 0; i < (int) strlen(choice_string); i++)
|
||||
{
|
||||
if (!isdigit(choice_string[i]))
|
||||
choice = 0;
|
||||
|
22
biology/babel/files/patch-convert.c
Normal file
22
biology/babel/files/patch-convert.c
Normal file
@ -0,0 +1,22 @@
|
||||
|
||||
$FreeBSD$
|
||||
|
||||
--- convert.c.orig Sun Nov 18 16:44:25 2001
|
||||
+++ convert.c Sun Nov 18 16:44:54 2001
|
||||
@@ -28,6 +28,7 @@
|
||||
static warning wstr;
|
||||
|
||||
static char *program_name;
|
||||
+extern char *__progname;
|
||||
int use_title = FALSE;
|
||||
|
||||
#ifdef MSDOS
|
||||
@@ -47,7 +48,7 @@
|
||||
#endif
|
||||
|
||||
babel_init();
|
||||
- program_name = argv[0];
|
||||
+ program_name = __progname;
|
||||
if (argc == 1)
|
||||
{
|
||||
usage();
|
@ -1 +1 @@
|
||||
Conversion program among various molecular file formats
|
||||
Converts among various molecular file formats
|
||||
|
@ -1,6 +1,6 @@
|
||||
Babel is a conversion program which is able to convert among dozens of
|
||||
molecular file formats.
|
||||
Babel is developed by Dolata Group, Department of Chemistry,
|
||||
Arizona University and Ohio State University.
|
||||
Babel is a program designed to interconvert a number of file formats
|
||||
currently used in molecular modeling. Babel is capable of assigning
|
||||
hybridization, bond order, and connectivity when these elements are
|
||||
not present in the input file.
|
||||
|
||||
WWW: http://smog.com/chem/babel/
|
||||
|
@ -1,6 +0,0 @@
|
||||
*********************************************************
|
||||
* Please set the env variable BABEL_DIR to *
|
||||
* /usr/local/share/babel before running babel. *
|
||||
* For example, put the next line in your .cshrc file: *
|
||||
* setenv BABEL_DIR /usr/local/share/babel *
|
||||
*********************************************************
|
@ -1,4 +1,6 @@
|
||||
@comment $FreeBSD$
|
||||
bin/babel
|
||||
libexec/babel
|
||||
share/babel/element.lis
|
||||
share/babel/new.lis
|
||||
share/babel/quanta.lis
|
||||
|
Loading…
Reference in New Issue
Block a user