bob@SU-SHASTA.ARPA (08/09/84)
Being quite familiar with porting between System V & 4.2bsd, here is my quick summary of problems: 1. Ioctl() [I have some IFDEFfed code to handle this that I will post to net.sources as part of my color curses package soon.] 2. Makefiles. System V's make is more powerful and in going to 4.2bsd they will need to be beefed up. In particular, single suffix rules will have to be converted to specific dependencies. The built-in rule .sh which copies thing.sh to thing for shell scripts (and data files) will also have to be changed to specific dependencies. 3. Names of include files containing particular defines and structs have been changed to protect the guilty. 4. Use of library routines only available on one of the systems. 5. More significant characters in variable names on 4.2bsd. 6. One musn't scan directories on 4.2bsd the way one does on System V. Lib- rary routines are supplied with 4.2bsd to use; versions of the library is available for System V. I suspect #2 will be your main problem in porting writer's workbench. Bob Toxen Silicon Graphics {decvax,ihnp4}!ucbvax!Shasta!olympus!bob
guy@rlgvax.UUCP (Guy Harris) (08/14/84)
> 2. Makefiles. System V's make is more powerful and in going to 4.2bsd they > will need to be beefed up. We have a version of the System III "make" (the System V "make" seems to differ only in a couple of small things like minor bug fixes) which runs under 4.2BSD, and also can automatically check files out of RCS; it's available if you have a System III or later license. > 4. Use of library routines only available on one of the systems. One of the most common instances of that problem is that "index" was renamed "strchr" and "rindex" was renamed "strrchr" in System n. The routines have identical functionality, so a "#define" or "-Dstrchr=index" should clear up that problem. > 5. More significant characters in variable names on 4.2bsd. If the code is going to or from a non-PDP-11 version of System V Release 2, this shouldn't be a problem as S5R2 on non-PDP-11 processors has "flexnames" as well. > 6. One musn't scan directories on 4.2bsd the way one does on System V. Lib- > rary routines are supplied with 4.2bsd to use; versions of the library is > available for System V. The libraries are, at worst, marked "Copyright ... Regents of the University of California"; I make a plea here (again) that all vendors of non-4.2BSD-based UNIX systems (including AT&T Technologies) include it in "libc" in their next release. (We have.) It makes a directory a reasonable abstraction, not only making it easier to move code between 4.2BSD and non-4.2BSD systems, but also makes it easier to deal with non-UNIX systems which may not even permit you to open a directory as a regular file. Furthermore, the routines incorporate the code needed to null-terminate file names and skip empty space in directories; how many times has that code been written? Guy Harris {seismo,ihnp4,allegra}!rlgvax!guy