rminnich@super.ORG (Ronald G Minnich) (03/22/90)
In article <7009@uhccux.uhcc.hawaii.edu> steven@uhccux.UUCP () writes: >When I install X11, it puts the executables and libraries in /usr/bin/X11 and >/usr/lib respectively. In other words, it puts these files in the file systems >that aren't available via nfs mounts. Thus making it usable for only one >system. Also, It is filling up the / and /usr file systems. Time i did this. This is the result of work Dan Kopetzki and I have done at SRC. I can't post the actual diffs cause they are on an isolated network. sorry. First off, make a copy of the entire tree using the very nice lndir.sh script. Do one tree per architecture. Then make a special directory somewhere (call it localmods or something) and in this directory place all the files that are different. There are so few that I didn't even preserve the hierarchy. Then in your shadow soft link trees delete links from the shadow tree to the source tree for each changed file, and ln -s to the localmods file instead. For example, you might have after the lndir.sh XR4.sun3/mit/lib/Xt/Imakefile -> /usr/local/src/XR4/mit/lib/Xt/Imakefile Since we need to change this makefile, rm XR4.sun3/blah blah blah and ln -s /usr/local/src/XR4.localmods/Imakefile.Xt \\ /usr/local/src/XR4.sun3/mit/lib/Xt/Imakefile anyways, For the rest of this letter assume that your destination directory is /usr/local. lib is /usr/local/lib/X11R4, bin is /usr/local/bin/X11R4, include is /usr/local/include/X11R4. Since /usr/local/lib/X11R4 corresponds (roughly) to /usr/lib, there is a directory in /usr/local/lib/X11R4 called X11. .so and .sa files go in /usr/local/include/X11R4, other stuff like config in /usr/local/include/X11R4/X11. --- in mit/lib/Xt/Imakefile fix FS_DEFINES FS_DEFINES= -DXFILESEARCHPATHDEFAULT=\"/usr/local/lib/X11R4/X11/%T/%N%S:\ <any-other-places>\" add a SpecialSharedAndDebuggedObjectRule for Intrinsic.o. Just copy the line for Initialize.o, and change APP_DEFINES to FS_DEFINES Everywhere else you see a fule for Initalize.o, make a corresponding rule for Intrinsic.o, with the same replacement for FS_DEFINES --- in the mit/rgb/Imakefile, add the lines: #ifdef DefaultFontPath SITE_FONT_PATH = -DCOMPILEDDEFAULTFONTPATH=\"DefaultFontPath\" #else SITE_FONT_PATH = #endif #ifdef DefaultRGBDataBase SITE_RGB_DB=\"DefaultRGBDataBase\" #else SITE_RGB_DB= #endif SITE_DEFINES = $(SITE_FONT_PATH) $(SITE_RGB_DB) $(SITE_DISPLAY_CLASS) SpecialObjectRule(rgb.o, $(IRULESRC)/Imake.tmpl, $(SITE_DEFINES) SpecialObjectRule(showrgb.o, $(IRULESRC)/Imake.tmpl, $(SITE_DEFINES) Note that in your site.def you must now define DefaultFontPath (i.e. /usr/local/lib/X11R4/X11/fonts) and DefaultRGBDataBase) --- in mit/clients/twm: in twm.h fix the definition of BITMAPS. I was getting tired at this point so i did not fix it right, but do it via site.def. in parse.c, fix the definition of SYSTEM_INIT_FILE --- site.def Define ExtraLibraries (i assume you want shared libraries) as, e.g., #ifndef ExtraLibraries #define ExtraLibraries /usr/local/lib/X11R4 #endif #ifndef UsrLibDir #define UsrLibDir /usr/local/lib/X11R4 #endif #ifndef BinDir #define BinDir /usr/local/bin/X11R4 #endif #ifndef IncRoot #define IncRoot /usr/local/include/X11R4 #endif #ifndef DefaultRGBDataBase #define <blah blah> #endif #ifndef ManDirectoryRoot #define <blah blah> #endif --- It is some measure of how good a job the X guys did that it is this easy. That is it. I have NO X stuff in /usr, not even soft links. I don't run ldconfig, or set LD_ENV_PATH. Why the -L switch works has me mystified; ldd on oclock reports dependencies on libs in /usr/local/lib/X11R4, but strings /usr/local/bin/X11R4/oclock shows *no* strings with a local in them! Where the info is stored is something of a mystery. Let me know if i can help further. Dan and I have done work on contrib too; I will send something on that later when my typing fingers are less tired. ron -- rminnich@super.org
narten@leah.Albany.Edu (Thomas Narten) (03/22/90)
In article <22726@metropolis.super.ORG> rminnich@super.ORG (Ronald G Minnich) writes: >in mit/lib/Xt/Imakefile >fix FS_DEFINES >FS_DEFINES= -DXFILESEARCHPATHDEFAULT=\"/usr/local/lib/X11R4/X11/%T/%N%S:\ ><any-other-places>\" Seems to me that a better fix here would be to use $(LIBDIR) instead of the hardcoded path name. This will grab the LIBDIR defined in site.def, making the fix work regardless of where you install your X libraries and binaries. In fact, although perhaps not necessary, I defined the default path as follows, mirroring the definition in the header file we want to override. -DXFILESEARCHPATHDEFAULT=\"$(LIBDIR)/%L/%T/%N%S:$(LIBDIR)/%l/%T/%N%S:$(LIBDIR)/%T/%N%S\" -- Thomas Narten narten@cs.albany.edu
rminnich@super.ORG (Ronald G Minnich) (03/23/90)
In article <22726@metropolis.super.ORG> ME writes: >has me mystified; ldd on oclock reports >dependencies on libs in /usr/local/lib/X11R4, >but strings /usr/local/bin/X11R4/oclock shows *no* strings with a local >in them! Where the info is stored is something of a mystery. And Rusty pointed out to me to run strings -a. Sheesh, why didn't I just do that before. Well, anyone, strings - on a sun shows the path... thanks, ron -- rminnich@super.org