🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
6 messages
6 total messages Started by Ofer Inbar Tue, 20 Dec 1994 18:48
nn port to DEC Alpha OSF/1 ?
#6908
Author: Ofer Inbar
Date: Tue, 20 Dec 1994 18:48
8 lines
1146 bytes
If anyone has gone through the pain of porting nn 6.5 to a DEC Alpha
running OSF/1, please let me know what you had to do.  I asked someone
who ported nn 6.4 to the Alpha, and he said it was not trivial.

  --  Cos (Ofer Inbar)  --  cos@cs.brandeis.edu
  --  WBRS (BRiS)  --  WBRS@binah.cc.brandeis.edu  WBRS@brandeis.bitnet
 Brandeis University Computer Science Department         (617) 736-2700
 415 South Street, Waltham MA, 02254-9110        System Admin: 736-2717
Re: nn port to DEC Alpha OSF/1 ?
#6906
Author: John P. Speno
Date: Wed, 21 Dec 1994 00:03
14 lines
1392 bytes
In <3d78td$1le@news.cs.brandeis.edu> cos@cs.brandeis.edu (Ofer Inbar) writes:

>If anyone has gone through the pain of porting nn 6.5 to a DEC Alpha
>running OSF/1, please let me know what you had to do.  I asked someone
>who ported nn 6.4 to the Alpha, and he said it was not trivial.

Pain? What pain? The only change I made was adding:

#define HAVE_STDLIB_H

to conf/s-osf.h. Follow the instructions and it works.
-- 
John P. Speno, speno@cc.swarthmore.edu, Swarthmore College Computing Center
	     "There is no wisdom greater than kindness."
Re: nn port to DEC Alpha OSF/1 ?
#6916
Author: Ofer Inbar
Date: Thu, 22 Dec 1994 17:36
55 lines
3713 bytes
speno@cc.swarthmore.edu (John P. Speno) writes:
>>If anyone has gone through the pain of porting nn 6.5 to a DEC Alpha
>>running OSF/1, please let me know what you had to do.  I asked someone
>>who ported nn 6.4 to the Alpha, and he said it was not trivial.
>
>Pain? What pain? The only change I made was adding:
>
>#define HAVE_STDLIB_H
>
>to conf/s-osf.h. Follow the instructions and it works.

Really?  I seem to be having a lot of trouble with inconsistencies
between the data types on the Alpha, and the assumptions nn makes
about types.  I tried adding HAVE_STDLIB_H, but it doesn't make much
of a difference.  I'm following the same instructions and general
procedures I have used to successfully install various versions of nn
6.4 and 6.5 on a variety of Sun, HP, Ultrix, Solbourne, and KSR
machines.  I noticed that the Alpha OSF/1 platform is *not* listed in
the documentations as one that nn is known to be compatible with, BTW.
Here's a typical make on the Alpha, using gcc:

cp xmakefile MF.c
/lib/cpp -DCOMPILER="gcc" -DPREPROC="/lib/cpp"  -DLDEBUG="-s "  -DCDEBUG="" -Iconf MF.c |  sed -e '1,/MAKE WILL CUT HERE/d'  -e '/^#/d'  -e '/^[ \f  ]$/d'  -e '/^[ \/]*[*]/d' |  sed -n -e '/^..*$/p' > ymakefile
rm -f MF.c
make  -f ymakefile all
gcc -Iconf -O -I/usr/include/bsd  -c nn.c
nn.c: In function `display_motd':
nn.c:660: warning: type mismatch in implicit declaration for built-in function `strcpy'
gcc -Iconf -O -I/usr/include/bsd  -c admin.c
admin.c: In function `group_admin':
admin.c:888: warning: type mismatch in implicit declaration for built-in function `strcpy'
admin.c:889: warning: type mismatch in implicit declaration for built-in function `strlen'
gcc -Iconf -O -I/usr/include/bsd  -c proto.c
gcc -Iconf -O -I/usr/include/bsd  -c global.c
global.c:684: warning: `va_start' redefined
/usr/local/lib/gcc-lib/alpha-dec-osf1.3/2.6.2/include/va-alpha.h:32: warning: this is the location of the previous definition
global.c: In function `mk_file_name':
global.c:462: warning: type mismatch in implicit declaration for built-in function `strlen'
global.c: In function `copy_str':
global.c:499: warning: type mismatch in implicit declaration for built-in function `strcpy'
global.c: In function `sys_error':
global.c:760: incompatible types in assignment
global.c:764: incompatible types in assignment
global.c: In function `sys_warning':
global.c:805: incompatible types in assignment
global.c:816: incompatible types in assignment
global.c: In function `log_entry':
global.c:846: incompatible types in assignment
*** Exit 1
Stop.

  --  Cos (Ofer Inbar)  --  cos@cs.brandeis.edu
  --  WBRS (BRiS)  --  WBRS@binah.cc.brandeis.edu  WBRS@brandeis.bitnet
 Brandeis University Computer Science Department         (617) 736-2700
 415 South Street, Waltham MA, 02254-9110        System Admin: 736-2717
Re: nn port to DEC Alpha OSF/1 ?
#6917
Author: Bill Tutt
Date: Thu, 22 Dec 1994 18:25
759 lines
23146 bytes
[ General problems with getting nn 6.5 &/or 6.4 to work under OSF/1 ditched]

I've had no trouble getting nn to work with OSF/1. In fact 
here are my relavent.h files:
config.h:

/**************************** NN CONFIGURATION ***************************
 *
 *	Configuration file for nn.
 *
 *	You must edit this file to reflect your local configuration
 *	and environment.
 *
 *	Before editing this file, read the licence terms in the README
 *	file and the installation guidelines in the INSTALLATION file.
 *
 *	(c) Copyright 1990, Kim F. Storm.  All rights reserved.
 */

#define	RELEASE 	"6.5"

#include <stdio.h>
#include <ctype.h>

/************************* DATABASE CONFIGURATION ***************************
 *
 *	Define NOV if you have access to .overview files in your news spool
 *	area and you want to use them rather than run nnmaster.
 *	If you use NNTP and your server is INN 1.4 or later with XOVER support
 *	and is generating .overview files there, you can use NOV over NNTP. In
 *	that case, make sure you define NNTP below as well.
 *
 *	IMPORTANT NOTE!
 *	The minute you define NOV, all bets are off regarding the
 * 	documentation!  There are NUMEROUS differences!
 */

#define NOV

/* Optional */
#define NOV_DIRECTORY "/usr/spool/news"

/*********************** NETWORK DEPENDENT DEFINITIONS **********************
 *
 *	Define NETWORK_DATABASE if you share the database through NFS on
 *	a network with different, non-compatible machines, e.g. SUNs and
 *	VAXen, or SUN-3 and SUN-4, or if you are using different compilers
 *	on the same architecture.
 *
 *	In a homogenous network, you can leave it undefined for higher
 *	performance (no data conversion is needed).
 *
 *	NETWORK_DATABASE is IGNORED if you are using NOV, as it has plain
 *	ascii files.  (Thank you Geoff!)
 */

/* #define NETWORK_DATABASE */


/********************************** NNTP *********************************
 *
 * 	Define NNTP to enable nntp support.  If you are not using NNTP,
 *	just leave the following NNTP_* definitions as they are - they
 *	will be ignored anyway.
 *
 *	With NNTP, the nnmaster still maintains a local database of
 *	all article headers for fast access (and because NNTP does not
 *	support nn - yet), while the articles are fetched from the
 *	nntp server when they are read or saved.
 *
 *	You may still share this database through NFS locally (see the
 *	description of NETWORK_DATABASE above) if you don't want to
 *	have separate nn databases on all your local systems.
 *
 *	Consult the file NNTP for further information on the use of NNTP.
 */

#define NNTP

/*
 *	Define NNTP_SERVER to the name of a file containing the name of the
 *	nntp server.
 *
 *	It is vital that both the nnmaster and all nn users on a machine
 *	uses the same nntp server, because the nn database is synchronized
 *	with a specific news active file.
 *
 *	If the file name does not start with a slash, it is relative to
 *	LIB_DIRECTORY defined below.
 *	NOTE: If you plan to use the included inews, it MUST be a full pathname
 */

#define NNTP_SERVER	"/usr/lib/nn/nntp_server"

/*
 *	Define NNTP_POST if you want nn to reject attempts to post via
 *	NNTP to a server, that disallows postings.
 *
 *	You should define this, if you use the NNTP based mini-inews for
 *	postings from NNTP clients.  If you use another mechanism, that
 *	does not involve NNTP, you should leave it undefined.
 */

#define NNTP_POST

/*
 *	NNTP's mini-inews seems to require that messages contain a complete
 *	header with Message-ID, Path, and Date fields which the normal inews
 *	generates itself.  If your mini-inews requires these headers to
 *	be present, define NNTP_MINI_INEWS_HEADER below.
 */

#undef NNTP_MINI_INEWS_HEADER	/* uses "broken" mini-inews */

/*
 *	Define NNTP_PATH_HOSTNAME to force a specific hostname into the
 *	Path: header generated when NNTP_MINI_INEWS_HEADER is defined.
 *	This is useful for multi-machine sites with one mail/news gateway.
 *
 *	If the string starts with a '/' it is taken as the name of a file
 *	from which the outgoing hostname should be read (at runtime).
 */

#define NNTP_PATH_HOSTNAME	"cs.simpson.edu" /**/


/***************** OPERATING SYSTEM DEPENDENT DEFINITIONS *******************
 *
 *  	Include the appropriate s- file for your system below.
 *
 *	If a file does not exist for your system, you can use
 *	conf/s-template.h as a starting point for writing you own.
 */

#include "s-ultrix.h"

/*
 *	Define DEFAULT_PAGER as the initial value of the 'pager' variable.
 *	nnadmin pipes shell command output though this command.
 */

/* #define DEFAULT_PAGER	"pg -n -s" */		/* system V */
#define DEFAULT_PAGER		"more"			/* bsd */

/*
 *	DEFAULT_PRINTER is the initial value of the 'printer' variable.
 *	nn's :print command pipes text into this command.
 */

#define DEFAULT_PRINTER	"lpr -p -JNEWS"	 	/* bsd */

/*
 * 	Define RESIZING to make nn understand dynamic window-resizing.
 * 	(It uses the TIOCGWINSZ ioctl found on most 4.3BSD systems)
 *	This should be defined in the conf/s-xxxxx.h file.
 *
 *	PLEASE DEFINE THIS IN YOUR conf/s-<os>.h FILE INSTEAD!!
 */

#define RESIZING	/**/

/*
 *	Include file configuration.  Most systems with an ANSI conformant C
 *	compiler should have these.  If you have them, you should use them!
 *
 *	Again, PLEASE DEFINE THESE IN YOUR conf/s-<os>.h FILE!
 *
 *	IF YOU HAVE THESE FILES, IT IS *VERY IMPORTANT* THAT YOU INCLUDE THEM
 */

/* Do you have /usr/include/string.h */
#define HAVE_STRING_H 

/* Do you have /usr/include/unistd.h */
#define HAVE_UNISTD_H

/* Do you have /usr/include/stdlib.h */
#define HAVE_STDLIB_H 

/* Do you have /usr/include/memory.h */
/* #define HAVE_MEMORY_H */

/* Do you have /usr/include/fcntl.h */
#define HAVE_FCNTL_H */

/********************** MACHINE DEPENDENT DEFINITIONS **********************
 *
 *	Include the appropriate m- file for your system below.
 *
 *	If a file does not exist for your system, you can use
 *	conf/m-template.h as a starting point for writing you own.
 */

#include "m-template.h"

/***************************** OWNERSHIP ***************************
 *
 *	Specify owner and group for installed files and programs.
 *
 *	The nnmaster will run suid/sgid to this owner and group.
 *
 *	The only requirements are that the ownership allows the
 *	nnmaster to READ the news related files and directories, and
 *	the ordinary users to read the database and execute the nn*
 *	programs.
 *
 *	Common choices are:  (news, news)  and   (your uid, your gid)
 */

#define OWNER	"news"
#define	GROUP	"news"


/**************************** LOCALIZATION ****************************
 *
 *	Specify where programs and files are installed.
 *
 *	BIN_DIRECTORY    - the location of the user programs (mandatory)
 *
 *	LIB_DIRECTORY	 - the location of auxiliary programs and files.
 *			   (mandatory UNLESS ALL of the following are defined).
 *
 *	MASTER_DIRECTORY - the location of the master program (on server)
 *			   (= LIB_DIRECTORY if undefined)
 *
 *	CLIENT_DIRECTORY - the location of auxiliary programs (on clients)
 *			   (= LIB_DIRECTORY if undefined)
 *
 *	HELP_DIRECTORY   - the location of help files, online manual, etc.
 *			   (= CLIENT_DIRECTORY/help if undefined)
 *
 *	CACHE_DIRECTORY	 - if NNTP is used, nn uses this central directory
 *			   to store working copies of articles on the local
 *			   system.  If not defined, it stores the articles
 *			   in each user's ~/.nn directory.
 *
 *	TMP_DIRECTORY    - temporary file storage.  Overriden by $TMPDIR.
 *			   (= /usr/tmp if undefined).
 *
 *	LOG_FILE         - the location of nn's log file.
 *			   (= LIB_DIRECTORY/Log if undefined).
 */

#define BIN_DIRECTORY	"/usr/bin"
#define LIB_DIRECTORY	"/usr/lib/nn"


/**************************** DATABASE LOCATION **************************
 *
 *	Specify where the nn database should be installed.
 *
 *	If none of the following symbols are defined, the database will
 *	be contained in the NEWS_DIRECTORY in a separate .nn directory for
 *	master files and in files named .nnx and .nnd in each group's
 *	spool directory.  To use this scheme, the OWNER specified above
 *	must have write permission on the news spool directories.
 *
 *	If you access news via NNTP, you will probably always have to
 *	give the database directory explicitly through DB_DIRECTORY
 *	(and DB_DATA_DIRECTORY), since the normal news spool directories 
 *	are probably not available on the local system.
 *	The exception may be if nnmaster runs directly on the nntp server.
 *
 *	To change the default behaviour, you can define the following
 *	symbols:
 *
 *	DB_DIRECTORY	   - the directory containing the master files.
 *
 *	DB_DATA_DIRECTORY  - the directory containing the per-group files
 *			     (default is DB_DIRECTORY/DATA if undefined).
 *
 *	DB_LONG_NAMES	   - use group's name rather than number when
 *			     building file names in DB_DATA_DIRECTORY.
 *	     (The file system must support long file names!!)
 */

#define DB_DIRECTORY	"/var/spool/nn"


/*************************** NEWS TRANSPORT **************************
 *
 *	Specify the location of your news programs and files
 *	You only need to specify these if you are not
 *	satisfied with the default settings.
 *
 *	NEWS_DIRECTORY	 	- The news spool directory.
 *				  Default: /usr/spool/news
 *
 *	NEWS_LIB_DIRECTORY	- The news lib directory.
 *				  Default: /usr/lib/news
 *
 *	INEWS_PATH		- The location of the inews program.
 *				  Default: NEWS_LIB_DIR/inews
 *
 *	RMGROUP_PATH		- The location of the rmgroup program.
 *				  Default: NEWS_LIB_DIR/{rm,del}group
 */

#define NEWS_DIRECTORY		"/var/spool/news"
#define NEWS_LIB_DIRECTORY	"/usr/lib/news"

#define INEWS_PATH		"/usr/lib/news/inews"


/*
 *	If no "Lines:" header field is present, NN can be made to
 *	count them itself.
 */

/* #define DONT_COUNT_LINES	1 */

/*************************** MAIL INTERFACE *************************
 *
 *	Specify a mailer that accepts a letter WITH a header IN THE TEXT.
 *
 * 	A program named 'recmail' program is normally delivered with
 *	the Bnews system, or you can use sendmail -t if you have it.
 *
 *	The contrib/ directory contains two programs which you might
 *	be able to use with a little tweaking.
 */

/* #define REC_MAIL	"/usr/lib/news/recmail"	*/	/* non-sendmail */
#define REC_MAIL	"/usr/lib/sendmail -t"		/* sendmail */


/*
 *	Define HAVE_ROUTING if your mailer understands domain based
 *	adresses (...@...) and performs the necessary rerouting (e.g.
 *	Sendmail or Smail).
 *
 *	Otherwise, nn will provide a simple routing facility using
 *      routing information specified in the file LIB_DIRECTORY/routes.
 */

#define HAVE_ROUTING			/* */

/*
 *	If HAVE_ROUTING is NOT defined, nn needs to know the name of
 * 	your host.  To obtain the host name it will use either of the
 *	'uname' or 'gethostname' system calls as specified in the s-
 *	file included above.
 *
 *	If neither 'uname' nor 'gethostname' is available, you must
 *	define HOSTNAME to be the name of your host.  Otherwise, leave
 *	it undefined (it will not be used anyway).
 */

/* #define HOSTNAME	"myhost" */	/* Not used if HAVE_ROUTING */

/*
 *	Define APPEND_SIGNATURE if you want nn to ask users to append
 *	~/.signature to mail messages (reply/forward/mail).
 *
 *	If the mailer defined in REC_MAIL automatically includes .signature
 *	you should not define this (it will fool people to include it twice).
 *
 *	I think 'recmail' includes .signature, but 'sendmail -t' doesn't.
 */

#define APPEND_SIGNATURE		/* */

/*
 *	BUG_REPORT_ADDRESS is the initial value of the bug-report-address
 *	variable which is used by the :bug command to report bugs in
 *	the nn software.  
 *	This address is currently set up as a mailing list, and it is
 *	intended that it will point to the current maintainer.
 */

#define BUG_REPORT_ADDRESS	"rassilon@cs.simpson.edu"


/*************************** DOCUMENTATION ***************************
 *
 * 	Specify directories for the user and system manuals
 *
 * 	Adapt this to your local standards; the manuals will be named
 * 		$(MAN_DIR)/program.$(MAN_SECTION)
 *
 *	USER_MAN	- nn, nntidy, nngrep, etc.
 *	SYS_MAN		- nnadmin
 *	DAEMON_MAN	- nnmaster
 */

#define USER_MAN_DIR 	"/usr/man/man1"
#define USER_MAN_SECTION 	"1"

#define SYS_MAN_DIR 	"/usr/man/man1"
#define SYS_MAN_SECTION 	"1m"

#define DAEMON_MAN_DIR 	"/usr/man/man8"
#define DAEMON_MAN_SECTION 	"8"


/************************** LOCAL POLICY *****************************
 *
 *	Define STATISTICS if you want to keep a record of how much
 *	time the users spend on news reading.
 *
 *	Sessions shorter than the specified number of minutes are not
 *	recorded (don't clutter up the log file).
 *
 *	Usage statistics is entered into the $LOG_FILE with code U
 */

#define STATISTICS	5  		/* minutes */

/*
 *	Define ACCOUNTING if you want to keep accumulated accounting
 *	based on the statistics in a separate 'acct' file.  In this
 *	case, the accounting figures will be secret, and not be
 *	written to the Log file.  And the users will not be able to
 *	"decrease" their own account.
 *
 *	See account.c for optional cost calculation parameters.
 */

/* #define ACCOUNTING */

/*
 *	Define AUTHORIZE if you want to restrict the use of nn to
 *	certain users or certain periods of the day.  Define both
 *	this and ACCOUNTING if you want to impose a usage quota
 *
 *	See account.c for implementing various access policies.
 */

/* #define AUTHORIZE */

/*
 *	Default folder directory
 */

#define FOLDER_DIRECTORY	"~/News"

/*
 *	Max length of authors name (in "edited" format).
 *	Also size of "Name" field on the article menus.
 *	You may want to increase this if your terminals are wider than
 *	80 columns.
 */

#define NAME_LENGTH 		16

/*
 *	Does your 'inews' program run immediately, or does it defer?
 *	If you have C-News, it can take minutes to find out if a post
 *	was accepted, whereas with INN, it only takes seconds.
 */

#define INEWS_IS_FAST		/* comment out for C-News */

/*
 *	Synchronous posting: If set this will cause NN to wait until a
 *	post or mail is *actually* finished.  If you want to NN's
 *	"Article posted" message to be *accurate*, then define this. 
 *	Warning: Do NOT define this if you are using C-News, or you will
 *	have to wait 60 seconds or more to find out if the post has been
 *	accepted.  You probably want this if you are using INN or posting
 *	via some sort of NNTP.
 */

#define SYNCHRONOUS_POSTING	/* comment out for C-News */

/*
 *	PUT_TIMESTAMP_IN_SCRIPTS
 *	Defining this causes the "inst" script to add identifying information
 *	to the beginning of the shell scripts.
 */
#define PUT_TIMESTAMP_IN_SCRIPTS

/*
 *	CONFIG_NUM_IN_VERSION
 *	Defining this will make NN announce itself including the build number
 *	like "NN version 6.5.xx #12", rather than "NN version 6.5.xx".
 */
#define CONFIG_NUM_IN_VERSION

/*
 *	NO_X_NEWSREADER
 *	Define this to disable the "X-Newsreader: " header in posts and mail
 *	Son-of-RFC1036 is rumoured to discourage this.
 */
/* #define NO_X_NEWSREADER */

/*
 *	ART_GREP
 *	Define this if you want to enable the "experimental" subject
 *	body search code.  On the "G" menu, there will be two extra
 *	choices: "b" body search unread, and "B" body search all.
 *	Choose your pattern, and you will be presented with a merged group
 *	containing the articles you chose.  There may still be bugs!
 *	WARNING:
 *	THIS WOULD BE *BAD* FOR NNTP SITES!  You don't want all your
 * 	users downloading the entire news database...
 */

/* #define ART_GREP */

/************************ CONFIGURATION COMPLETED ************************/

#include "global.h"


###########################################################################
m-template.h:
###########################################################################

/************** Machine (and compiler) dependent definitions. **************
 *
 *	Define appropriate types for the following ranges of integer
 *	variables.  These are processor & compiler dependent, but the
 *	distributed definitions will probably work on most systems.
 */


/* NOTE!!!!!!!!!!!! */
/* All I had to do basically was change long to int in the typedef of int32*/

/*      MACHINE TYPE	DEFINED TYPE		VALUE RANGE	*/

typedef unsigned char	int8;		/*        0 ..     255 */
typedef short		int16;		/*  -10,000 ..  10,000 */
typedef int		int32;		/* -100,000 .. 100,000 */
typedef unsigned int	uint32;		/* 	  0 ..  2^31-1 */


/*
 * 	Define NO_VARARGS if the varargs feature is not available.
 *
 *	Also define NO_VARARGS if the vprintf/vsprintf routines are not
 *	available (however, this will only by safe on some machines, like
 *	the VAX).
 *
 *	Defining NO_VARARGS in the m- file should only be done for
 *	architectures which does not support it in general, or where
 *	a majority of the systems available on that architecture
 *	doesn't have it.  Otherwise, it should be defined in the
 *	s- file, because this is primarily OS dependent.
 *
 *	NO_VARARGS can be overruled by defining HAVE_VARARGS in the s-
 *	file.
 */

/* #define NO_VARARGS /* unless HAVE_VARARGS */

/*
 *	Define STRCSPN if the strcspn() function is not available.
 */

/* #define STRCSPN 	/* */

/*
 *	Define NO_SIGINTERRUPT on BSD based systems which don't have
 *	a siginterrupt() function, but provides an SV_INTERRUPT flag
 *	in <signal.h>.
 */

/* #define NO_SIGINTERRUPT	/* */


#ifdef NETWORK_DATABASE

/*
 *	Define NETWORK_BYTE_ORDER if the machine's int32's are
 *	already in network byte order, i.e. m68k based.
 */

#define NETWORK_BYTE_ORDER	/* */

/*
 *	OTHERWISE provide the functions/macros ntohl/htonl to
 *	convert longs from and to network byte order
 */

#ifndef NETWORK_BYTE_ORDER

/*
 * Include appropriate files or define macroes or functions (include them
 * in data.c) to convert longs and shorts to and from network byte order.
 */

/*
 * This will work on most BSD based systems...
 */

#include <netinet/in.h>

/*
 * Otherwise, define something appropriate below
 */

#define htonl(l)	...	/* host long to network long */
#define ntohl(l)	...	/* network long to host long */

#endif	/* not NETWORK BYTE ORDER */

#endif	/* NETWORK DATABASE */

#############################################################################
s-ultrix.h
#############################################################################
/*
 *      This version is for ultrix systems
 *	From: dietrich@cernvax.cern.ch (dietrich wiegandt)
 */

#include "s-bsd4-2.h"

/*
 *      Define HAVE_VARARGS, Ultrix has vprintf, vsprintf as well
 */

#define HAVE_VARARGS

/*
 *      Ultrix signal handlers have type void (see signal.h)
 */

#define	SIGNAL_HANDLERS_ARE_VOID	/* */

#############################################################################
s-bsd4-2.h
#############################################################################
/*
 *	This version is for BSD 4.2 systems
 */
#define NO_SIGINTERRUPT 
/*
 *	Include header files containing the following definitions:
 *
 * 		off_t, time_t, struct stat
 */

#include <sys/types.h>
#include <sys/stat.h>


/*
 *	Define if your system has system V like ioctls
 */

#define	HAVE_TERMIO			/* */


/*
 *	Define to use terminfo database.
 *	Otherwise, termcap is used
 */

#undef	USE_TERMINFO			/* */

/*
 *	Specify the library (or libraries) containing the termcap/terminfo
 *	routines.
 *
 *	Notice:  nn only uses the low-level terminal access routines
 *	(i.e. it does not use curses).
 */

#define TERMLIB	-ltermlib

/*
 *	Define HAVE_STRCHR if strchr() and strrchr() are available
 */
#define HAVE_STRCHR
#ifdef USE_STRINGS_H
#undef USE_STRINGS_H
#include <strings.h>
#else
#include <string.h>
#endif

/* #undef HAVE_STRCHR			/* */

/*
 *	Define if a signal handler has type void (see signal.h)
 */

#define	SIGNAL_HANDLERS_ARE_VOID	/* */

/*
 *	Define if your system has BSD like job control (SIGTSTP works)
 */

#define HAVE_JOBCONTROL			/* */

/*
 *	Define if your system provides the "directory(3X)" access routines
 *
 *	If true, include the header file(s) required by the package below
 *	(remember that <sys/types.h> or equivalent is included above)
 *	Also typedef Direntry to the proper struct type.
 */

#define	HAVE_DIRECTORY			/* */

#include <dirent.h>			/* BSD */

typedef struct dirent Direntry;		/* BSD */

/*
 *	Define if your system has a mkdir() library routine
 */

#define	HAVE_MKDIR			/* */

/*
 *	Define if your system provides a BSD like gethostname routine.
 *	Otherwise, define HAVE_UNAME if uname() is avaiable.
 */

#define	HAVE_GETHOSTNAME	/* BSD systems */

/*
 *	Define HAVE_MULTIGROUP if system has simultaneous multiple group
 *	membership capability (BSD style).
 */

#define HAVE_MULTIGROUP

/*
 *	Define DETATCH_TERMINAL to be a command sequence which
 *	will detatch a process from the control terminal
 *	Also include system files needed to perform this HERE.
 *	If not possible, just define it (empty)
 */

#include <sys/file.h>	/* for O_RDONLY */
#include <sys/ioctl.h>	/* for TIOCNOTTY */

#define	DETATCH_TERMINAL \
    { int t = open("/dev/tty", O_RDONLY); \
	  if (t >= 0) ioctl(t, TIOCNOTTY, (int *)0), close(t); }


/*
 *	Specify where the Bourne Shell is.
 */

#define SHELL		"/bin/sh"

/*
 *	Specify the default mailer to be invoked by nnmail
 */

#define	MAILX	"/usr/ucb/Mail"		/* BSD */

/*
 *	Define the maximum length of any pathname that may occur
 */

#define	FILENAME 	256

#############################################################################

Bill Tutt
rassilon@cs.simpson.edu
Re: nn port to DEC Alpha OSF/1 ?
#6946
Author: Ofer Inbar
Date: Thu, 29 Dec 1994 22:30
94 lines
3701 bytes
rassilon@cs.simpson.edu (Bill Tutt) writes:
>I've had no trouble getting nn to work with OSF/1. In fact 
>here are my relavent.h files:

Thanks.  I tried the .h files you gave me, and it was an improvement,
although it still doesn't really work.  This one may be pretty easy to
fix, though...  I don't have time now, I will try again next week, but
I wanted to follow up before your article expired just in case... :)

During the make, I get a few of these (on several different files):
gcc -Iconf   -c macro.c
macro.c: In function `m_define':
macro.c:404: warning: cast to pointer from integer of different size

The offending line in this case is:
    return type == 0 ? (char *)macro[cur_m] : (char *)(K_MACRO | cur_m);

It finally dies on this:
gcc -Iconf   -c dir.c
dir.c: In function `list_directory':
dir.c:57: warning: assignment from incompatible pointer type
dir.c:58: dereferencing pointer to incomplete type
*** Exit 1
Stop.

It might work if I just went through and changed all the casts...
But there's probably some other type inconsistency I'd cause then.

>config.h:

>#define NOV

Hmm, I'm compiling without NOV, I wonder if that makes a difference
here.

>/* #define NETWORK_DATABASE */

On the other hand, I do need NETWORK_DATABASE...

>#define NNTP

Yup, both of us are using NNTP.

>#include "s-ultrix.h"

Strange that you're working from s-ultrix.h rather than the supplied
s-osf1.h, which is what I first tried.  Any reason for that?  Anyway,
I tried your s-ultrix.h this time.

>#include "m-template.h"

Again, any reason you started from the template rather than the
supplied m-alpha.h?  Anyway, I tried your m- file this time.

>m-template.h:

>/* NOTE!!!!!!!!!!!! */
>/* All I had to do basically was change long to int in the typedef of int32*/

>/*      MACHINE TYPE	DEFINED TYPE		VALUE RANGE	*/

>typedef unsigned char	int8;		/*        0 ..     255 */
>typedef short		int16;		/*  -10,000 ..  10,000 */
>typedef int		int32;		/* -100,000 .. 100,000 */
>typedef unsigned int	uint32;		/* 	  0 ..  2^31-1 */

The supplied m-alpha.h already had this.

> *	Define NETWORK_BYTE_ORDER if the machine's int32's are
> *	already in network byte order, i.e. m68k based.
> */

>#define NETWORK_BYTE_ORDER	/* */

Hmmm, the supplied m-alpha.h specifically had this:

#ifdef NETWORK_DATABASE
#undef NETWORK_BYTE_ORDER
#include <netinet/in.h>
#endif  /* NETWORK DATABASE */

Does anyone know what the byte sex of an Alpha's int is?

>Bill Tutt
>rassilon@cs.simpson.edu

Thanks for your help.

Anyone else got ideas?

  --  Cos (Ofer Inbar)  --  cos@cs.brandeis.edu
  --  WBRS (BRiS)  --  WBRS@binah.cc.brandeis.edu  WBRS@brandeis.bitnet
 Brandeis University Computer Science Department         (617) 736-2700
 415 South Street, Waltham MA, 02254-9110        System Admin: 736-2717
Re: nn port to DEC Alpha OSF/1 ?
#6948
Author: Bill Tutt
Date: Sat, 31 Dec 1994 06:56
90 lines
3715 bytes
In <3dvda7$c5q@news.cs.brandeis.edu> cos@cs.brandeis.edu (Ofer Inbar) writes:

>rassilon@cs.simpson.edu (Bill Tutt) writes:
>>I've had no trouble getting nn to work with OSF/1. In fact 
>>here are my relavent.h files:

>Thanks.  I tried the .h files you gave me, and it was an improvement,
>although it still doesn't really work.  This one may be pretty easy to
>fix, though...  I don't have time now, I will try again next week, but
>I wanted to follow up before your article expired just in case... :)

>During the make, I get a few of these (on several different files):
>gcc -Iconf   -c macro.c
>macro.c: In function `m_define':
>macro.c:404: warning: cast to pointer from integer of different size

>The offending line in this case is:
>    return type == 0 ? (char *)macro[cur_m] : (char *)(K_MACRO | cur_m);

>It finally dies on this:
>gcc -Iconf   -c dir.c
>dir.c: In function `list_directory':
>dir.c:57: warning: assignment from incompatible pointer type
>dir.c:58: dereferencing pointer to incomplete type
>*** Exit 1
>Stop.

>It might work if I just went through and changed all the casts...
>But there's probably some other type inconsistency I'd cause then.

>>config.h:

>>#define NOV

>Hmm, I'm compiling without NOV, I wonder if that makes a difference
>here.

Could, I dont know.. I havent tried using nn 6.5.0b3 with network_database

>>/* #define NETWORK_DATABASE */

>On the other hand, I do need NETWORK_DATABASE...

>>#define NNTP

>Yup, both of us are using NNTP.

>>#include "s-ultrix.h"

>Strange that you're working from s-ultrix.h rather than the supplied
>s-osf1.h, which is what I first tried.  Any reason for that?  Anyway,
>I tried your s-ultrix.h this time.


>>#include "m-template.h"

>Again, any reason you started from the template rather than the
>supplied m-alpha.h?  Anyway, I tried your m- file this time.

Yes, there is a reason for that.. I got 6.4.18 working by modifying
s-ultrix.h and m-template.h to fit OSF/1's needs, and me being extremely
lazy didnt notice said s-osf1.h and m-alpha.h.


>> *	Define NETWORK_BYTE_ORDER if the machine's int32's are
>> *	already in network byte order, i.e. m68k based.
>> */

>>#define NETWORK_BYTE_ORDER	/* */

>Hmmm, the supplied m-alpha.h specifically had this:

>#ifdef NETWORK_DATABASE
>#undef NETWORK_BYTE_ORDER
>#include <netinet/in.h>
>#endif  /* NETWORK DATABASE */

>Does anyone know what the byte sex of an Alpha's int is?

Hmm... I'ld go with what m-alpha.h says for NETWORK_BYTE_ORDER
Like I said, all I did was basically bring in the files from my nn-6.4.18 
source tree.

Let me know how it turns out.

(Now if only nn didnt take so long to start.  Reading an active file with
10,000 newsgroups in it over a 56k link is no party. :( )

Bill Tutt
rassilon@cs.simpson.edu
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads