Re: Compiling 2.1.13

Andreas Kostyrka (andreas@ag.or.at)
Mon, 25 Nov 1996 09:30:33 +0100 (MET)

On Sat, 23 Nov 1996, Matthew Jacob wrote:

> >
> >This isn't my experience. I also have just downloaded 2.1.13, set the
> >ARCH to alpha, and the compile failed (missing various headers,
> >timespecbits.h, etc.).
>
> I haven't seen that.
Funny thing: I've upgraded my RH 3.0.3 AXP to RH 4.0, and I'm getting
exactly the same behaviour out of the small test program below
>
> > I'm using a newly upgraded RedHat 4.0,
>
> However, header files for the kernel are supposed to be self-contained.
> If you have RH 4.0, you may have paid for it, so I suppose you should
> ask EWT or someone at RedHAT*.
That doesn't work here :(, as I've burnt my own CD :)

Andreas
P.S.: My small test program: (It's nice to map for 1 Terabyte file areas
:) )
P.P.S.: I could get it to compile under AXP, by doing a manual gcc -E, and
then just compiling the code from main(...) on.
#include <unistd.h>
#include <sys/mman.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>

#ifndef MAP_FAILED
#define MAP_FAILED ((void *)-1)
#endif

main(int argc,char **argv) {
int blocksize;
int numfiles;
int handle=-1;
char filename[256];
int i;
char *p;

blocksize=atoi(argv[1])*1024;
numfiles=atoi(argv[2]);

for(i=0;i<numfiles;i++) {
#if defined(ONE_FILE)||defined(ONE_OPEN)
strcpy(filename,"file-one");
#else
sprintf(filename,"file.%04d",i);
#endif
#if defined(ONE_OPEN)
if(handle==-1) {
#endif
handle=open(filename,O_RDWR|O_CREAT,0666);
lseek(handle,blocksize-1,SEEK_SET);
write(handle,"X",1);
#if defined(ONE_OPEN)
}
#endif
p=mmap(NULL,blocksize-1,PROT_READ|PROT_WRITE,MAP_SHARED,handle,0);
if(p==MAP_FAILED) {
perror("mmap()");
return 1;
}
/* printf("%03d: %p\n",i,p); */
#if !defined(ONE_OPEN)
close(handle);
#endif
}


}

--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com



Feedback | Store | News | Support | Product Errata | About Us | Linux Info | Search | JumpWords
No Frames | Show Frames

Copyright © 1995-1997 Red Hat Software. Legal notices