Date: Wed, 19 Jul 2000 07:48:51 -0500 (CDT) From: Mike Meyer <mwm@mired.org> To: doc@freebsd.org Subject: Porter's Handbook: Honoring PREFIX (15.12) and testing (2.4) Message-ID: <14709.41907.882392.26159@guru.mired.org>
next in thread | raw e-mail | index | archive | help
Hello all, Neither of the sections mentioned in the subject line talk about a simple test for honoring PREFIX/LOCALBASE that all ports should pass (but not all do, unfortunately :-(). This test has four steps: 1. make clean 2. make install PREFIX=/var/tmp/port-name 3. make deinstall Complaints about missing files indicate files that weren't properly installed according to PREFIX. 4. find /var/tmp/port-name -type f Shouldn't list any files. I haven't fully investigated how dependencies interact with this. In particular, some ports may need runtime dependencies installed with PREFIX=/var/tmp/port-name, which breaks the test for step 4 until all of them have been deinstalled as well. As a final note, the usage of PREFIX/LOCALBASE could be explained a bit better, along with adding X11BASE. According to my understanding, PREFIX is used to refer to where the current port is being installed; LOCALBASE is for things installed by non-X ports, and X11BASE for things installed by X ports. So the option -DPAGER=\"${PREFIX|/bin/less\" is actually wrong. Better wording for that would be: Also, refer to programs/files from other ports with the variables mentioned above, not explict pathnames. For instance, if your port requires the macro TOOL to be the full pathname to tool, use the compiler flag: -DTOOL=\"${LOCALBASE}/bin/tool\" unless it's an X tool, in which case use: -DTOOL=\"${X11BASE}/bin/tool\" instead of -DTOOL=\"/usr/local/bin/tool\". This way it will have a better chance of working if the system administrator has moved the whole '/usr/local' or '/usr/X11R6' tree somewhere else. Thanx, <mike To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?14709.41907.882392.26159>