Re: BSD make vs. GNU make
On Tuesday 17 April 2007 13:15:08 Bill Campbell wrote: The gmake program has many extensions which tend to be used in the gnu automake, autoconf, libtools system. I suspect that gmake will work with most non-gnu Makefiles, but the reverse is not true. This suspicion is not necessarily true. That is something I learned the hard way back when I was in college. I was doing all my development on FreeBSD in my dorm room but the target machine was Linux. Because I was naive, I didn't concern myself with which make I was using. And I hand created a Makefile for my project. I did this in my room and I was referencing the documentation for PMake (/usr/share/doc/psd/12.make) as recommended by the man page. The time of the week comes to move to the lab environment... and I copied my files there and saw a bug. So I started fixing it and ended up on a roll where I wrote a large portion of code. I saved the code, exited vi, and ran make. Well, some syntax in my Makefile and gmake did not agree. And rather than just erroring nicely, it zeroed out my source file and then errored out. I'd lost well over an hour of work which I never really did recreate to my recollection of it. Even though I have saved religiously while working, I have never bothered to commit the changed to the repository so it was all lost. Had I stayed in vi and run make in a subshell or committed my changes... well, can't go back and make better choices now. I've since moved on and that project collects digital dust somewhere... along with the circuit board it was meant to control. I wish I had kept the original Makefile so I know exactly what I did. But at the time I was so panicked that I rewrote it to work with gmake and just remembered to use gmake in my room as well. Anyway, I am rambling. We can't make the assumption that gmake is backwards compatible with any other form of make. Actually, we can demonstrate that it's not the case by trying to use gmake with ports... you will find that it fails with an error. At least with ports it's nondestructive. :) -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: vim port not upgrading
On Tuesday 27 March 2007 09:40:09 Michael P. Soulier wrote: I tried to upgrade vim, and I get a lot of these. ... The number on the left just keeps going up and it just keeps spinning it wheels. Any suggestions? As you have most likely noticed by now, it stopped at 7.0.214, which is the minor version of vim. Actually it's a patch version. vim applies a series of patches to the original source instead of constantly releasing a large file including all the source. It makes patching fairly easy and saves some bandwidth for them. Just let it run... it will get them all and your build will complete. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: rc.d scripts
Does anyone know how to make a script in /etc/rc.d run last? For instance I want dhclient to be the last script in /etc/rc.d/ to run. Any help is much appreciated. This may have already been answered by others, but I believe just rename the script with a prefix of z for example: zmyscript.sh or zzmyscript to make it very last beyond the first one with a z. It works for me. I have my suspicions regarding this working as you describe. As the order isn't related to the filename but to the REQUIRE tags inside the file. It is actually a non-trivial thing to make something run last. It seems like it should be easy but the system doesn't work that way. For example, adding a requirement for bgfsck (which was also last on my system when I did this) moved bgfsck down the list... and still left dhclient 4th from last. In fact, it took the addition of: # REQUIRE: bgfsck bsnmpd bridge bluetooth to actually make it the last thing run. And that is not a sure thing either... as soon as the system is updated it is likely to change. You could edit /etc/rc and add a skip for dhclient (to prevent it from being run) and then a couple lines to get just it (with rcorder -k) at the very end of /etc/rc to execute it at the very end. You would need to add a keyword declaration in /etc/rc.d/dhclient It's extremely non-standard but if absolutely required, it would work. Or there probably are other ways. Still, the exact order of scripts [under the current system] is not meant to be fixed and static. It is meant to be flexible so things can be added and removed without worry. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: where are /usr/local/etc/rc.d init scripts run from?
On Saturday 23 December 2006 18:15, Michael P. Soulier wrote: I was looking in /etc/rc, and it's obvious to see where the /etc/rc.d scripts are run from. skip=-s nostart [ `/sbin/sysctl -n security.jail.jailed` -eq 1 ] skip=$skip -s nojail files=`rcorder ${skip} /etc/rc.d/* 2/dev/null` for _rc_elem in ${files}; do run_rc_script ${_rc_elem} ${_boot} done So rcorder is run over /etc/rc.d/*. When is the same done for /usr/local/etc/rc.d/*? Thanks, Mike They are called from /etc/rc.d/localpkg if they are the old style. The directories searched are defined with local_startup (which defaults to: /usr/local/etc/rc.d /usr/X11R6/etc/rc.d). The new style scripts are found in /etc/rc as well. You may want to look at the find_local_scripts_new() function in /etc/rc.subr to see how some of this functions. There is some trickery here because we have to do this in more than one step. Since /usr/local/etc/rc.d/ may not be on a mounted filesystem until we run through some of the earlier scripts. [/etc/rc:98-118] # Now that disks are mounted, for each dir in $local_startup # search for init scripts that use the new rc.d semantics. # case ${local_startup} in [Nn][Oo] | '') ;; *) find_local_scripts_new ;; esac files=`rcorder ${skip} /etc/rc.d/* ${local_rc} 2/dev/null` _skip_early=1 for _rc_elem in ${files}; do case $_skip_early in 1) case $_rc_elem in */${early_late_divider})_skip_early=0 ;; esac continue ;; esac run_rc_script ${_rc_elem} ${_boot} done ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: where are /usr/local/etc/rc.d init scripts run from?
So rcorder is not used for the rc scripts in /usr/local/etc/rc.d? That explains much, since I have a runsvstat.sh script needed to start runit, and a script to start one of its services starts with an 'm' and is executing first, which I don't want. Why is rcorder not used on these files as well? It's such a good system. I was unintentionally confusing in my answer. Sorry about that. If your startup script is in the old style, it will be handled by /etc/rc.d/localpkg when that is called during the boot process. That is ONLY if it's the old style. If it is part of the new style, it will be sorted *correctly* by rcorder with the other scripts in /etc/rc.d/. I have to highlight correctly because for your script to actually be handled correctly it must appear in the order after the $early_late_divider (which is probably mountcritical but could be NETWORKING if you're running a jail or something else if it's redefined by your environment). Typically, as long as your script appears after mountcritical, it will be handled correctly. If you read /etc/rc carefully, you will see that rcorder is run twice. The first time with just the scripts in /etc/rc.d/ and then it starts processing those. This is the bit of code you included. But, if you look, it breaks that look at the $early_late_divider and then goes down to the block I pointed out (starting on line 98 in my system). In this case it finds all the new style scripts in the ${local_startup} directories and then uses rcorder to resort all the scripts in /etc/rc.d/ with the new style scripts from those directories. Then code then loops again (this time ignoring scripts) until it hits the $early_late_divider and then runs all the scripts after that. If your script appears earlier than that, it will be sorted into the section of scripts which won't be run. In practice, this should not be a problem. If your script is not being run correctly... you need to investigate /etc/rc.subr and try and understand why it is not seeing it as a new style script or if some other mistake is being made. find_local_scripts_new is the function that does this (line 1392 on my system) and is where I would look. I hope this is a little more clear. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Ports maintainer
On Tuesday 31 October 2006 21:43, Miguel Vazquez Gocobachi wrote: Hi there! I am interesting to be a ports maintainer for FreeBSD project. What need I do? Thanks a lot. Miguel Find a port that needs a maintainer and take over it or find a program not in ports and bring it in. There are many ports that need people to maintain them. Subscribe to the ports mailing list and you'll see occasional posts about ports which are unmaintained and broken. It's not very hard... do that and be familiar with the porter's handbook and you'll find something in no time. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Newbie Experience
On Tuesday 12 September 2006 06:16, Jeff Rollin wrote: I let a lot of BSD comments about Linux go unpunished, but this one has always got me. BSD had to be *almost totally rewritten* to avoid ATT licensing issues... added to the fact that I wouldn't be surprised if it's hard to find a single line of code IRIX, Solaris et al these days share between themselves and with V7. Not only that, but I understand that a lot of Unix sysadmins download the GNU tools as well, because (among other things) they do nifty things like being able to unzip, gunzip or bunzip a tarball before untarring it. And the amount of software available from people like KDE to install in FreeBSD is staggering. I find the phrase almost totally rewritten to be misleading. It is true that the majority of the OS had been rewritten by the time of the lawsuit. That is what happens as hardware and software changes. You'd vomit if you had a V7 kernel on modern hardware (even if you got all the hardware supported the internals were designed for a different time period). The code had evolved slowly over time from the base of where it had started. By the time the lawsuit was brought up and the licensing issues went to court only 0.016% of the files had to be removed and another 0.388% of them had to add copyright notices. I hardly find needing to rewrite less than half a percent (0.404%) of the operating system as a total rebuild. Along with that less than half a percent was a legal order to not use the name Unix but the 99.59% of code that was Unix one moment didn't suddenly cease to exist or change forms when that name was removed. The lawsuit was settled in January 1994, largely in Berkeley's favor. Of the 18,000 files in the Berkeley distribution, only 3 had to be removed and 70 modified to show USL copyright notices. A further condition of the settlement was that USL would not file further lawsuits against users and distributors of the Berkeley-owned code in the upcoming 4.4BSD release. [From: http://en.wikipedia.org/wiki/Berkeley_Software_Distribution#Net.2F2_and_legal_troubles but easily found elsewhere as well if one investigates.] Does the OS have any original code left in it? I certainly hope not but the pedigree is there. It started from the original code and changed a little bit at a time. Even though FreeBSD can't be called Unix today, it evolved from Unix. Linux arose from ideas as presented in the POSIX standard and GNU community. I agree that Linux is not an emulator. It is just a different interpretation of Unix. Solaris is different, BSD is different, AIX is different, etc. While some did evolve from the actual roots and Linux didn't... I do not believe that is reason alone to snub Linux. Anyway, all modern day Unix systems have different code than the original Unix systems. It's part of the reality of software. As for the GNU tools, yes most sysadmins use some of them (although not always). I know that BSD tar handles gzip and bzip2 just fine ( -z and -j respectively). So I know I wouldn't download gtar just for that feature. And I don't even consider it that large of a feature. If I had a tar which lacked it, I could certainly still manage that with one command line. GNU utilities have their benefits. Mainly, in my experience, that they're fairly common in the open source world and often you need them to use something which is created by them. I've had to download gawk and gsed before just to install a program without rewriting all the awk and sed code in it to be posix compliant, for example. I do have KDE on several computers I maintain for people and use a lot of software outside the base install. Once everything is setup... and for the most part, the difference between using BSD or Linux is minor. It's not anywhere near the difference between using Windows and Mac (for example). -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Newbie Experience
In brief, the installation process is just awful. After multiple attempts on an admittedly older machine (Pentium II 266Mhz, 256KB ram, 30GB hard drive, S3 Virge graphics card), I was able to get the FreeBSD OS installed, but could not configure Gnome or KDE properly. The documentation is sketchy at best. I had to learn about X11, Xorg, XFree86, and all of the gory history of X before I could even begin to use ee and know to edit the /etc/rc.conf file. The installation process did not recognize my graphics card or Ethernet connection, and all I could get was a crude 600x800 display. And DesktopBSD was even worse. The Handbook is excellent at walking through much of the setup. Although, in cases similar to yours I always recommend starting with the article designed for people new to both FreeBSD and Unix. http://www.freebsd.org/doc/en_US.ISO8859-1/articles/new-users/index.html This gets you started on all the basics you'll need to know to get everything else under control and is short enough that you don't feel compelled to jump around and possibly miss stuff. It doesn't cover X setup but gets you comfortable working in the command line which is what you're going to need to be proficient at until you have X configured. X is usually fairly easy to setup but you need to know how to move around. Conversely, FreeBSD took me multiple days and has still left me bewildered. Needless to say, I was very disappointed. I feel that FreeBSD will never achieve broader acceptance (even with momentum building for alternative OS) among people with modest technical proficiency and fairly simple requirements (i.e., spreadsheets, word processing, presentations, email). FreeBSD has an awful out of the box experience. It's too bad, because I think FreeBSD is probably a better OS, but I'll never really know. Regards, FreeBSD has an excellent out of the box experience, for the majority of people who use it. The best out of the box experience (for most BSD users) is a base system which is configured to be used well enough to set it up for whatever use you intend for it. Even moving to it completely new, it's not bad if you take the time to learn it. Moving to a different OS isn't something you should take lightly. There's a reason people are encouraged to read all the documentation they can before starting. With that said, the installation does require administrative ability. But since it's your machine, you will eventually need that. Huge learning curve right at the front but it's very gentle after that. My step-mother (who can't manage to understand why programs people send her don't run -- yes they're windows viruses -- and only knows her web-browser because it's the globe icon) manages to use FreeBSD without issue. She absolutely loves it and does everything you listed as simple requirements and more. But I set it up for her because she wasn't up for the learning curve. If you're of modest-technical ability and have a desire to learn the OS, it's not very difficult to overcome that curve. But the curve does exist. Anyway, when you're stuck, posting specific questions about your problems here (or trying google) is usually a lot more productive than giving up and sending an email about how it doesn't work to the help list. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Producing a binary install
Otherwise doing a 'make package' after the port has been installed will create a package for you. You should then be able to install the package on the other machine using pkg_add. HTH, Micah If you've already done make clean... you're going to end up rebuilding if you use make package. Since that's not what you're looking to do, use pkg_create instead. pkg_create -b jdk-1.5.0p3_1 Obviously, replace with the package name in your system. By default, the package will be created in the directory you are in when you run the command. I maintain a computer for my step-mother and, since I want to avoid actually building on her computer as much as possible, I use the following script to package every binary on my system and then I can just copy them over to her computer (or setup my computer so pkg_add can get them over the internet) and use them to install. #!/bin/tcsh foreach file ( `pkg_info | awk '{print $1}'` ) echo Creating package for $file pkg_create -b $file end This script is not smart... it doesn't check to see if a package of the same name already exists -- which it should... hmm, I'm going to add that to mine... to save time if you run it frequently, and just build packages you need. Anyway, pkg_create is very useful in saving time when you maintain a bunch of computers and want to keep them all up to date and only want to commit one to building and testing. -Kevin B. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: We want tu use your company name and logo
On Thursday 02 March 2006 15:56, Ercan Pamuk wrote: In our company we want to sell T-shirts,glasses,caps that are products of FreeBSD Linux which we give them system supporting in our company.We want to use Slackware FreeBSD Linux Logos Of all the spam, I think the FreeBSD Linux spam amuses me the most. If someone could find a better way to say I don't know anything about this at all but I think I do I would like to see it. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Find Syntax
On Monday 02 January 2006 11:19, Drew Tomlinson wrote: I'm trying to find all files with a modification time older than three weeks ago. In reading the find man page and searching Google, it seems the time returned by 'ls -l' is mtime. Thus I construct the following command: find . -not \( -newermt 3w \) -exec ls -l {} \; But it returns files that are newer: -rw--- 1 nobody nobody 35292 Dec 29 08:43 totContactedRcvdPeers.rrd -rw--- 1 nobody nobody 35292 Dec 29 08:43 totContactedSentPeers.rrd -rw--- 1 nobody nobody 35292 Dec 29 08:33 ./dc0/hosts/207/106/6/90/pktSent.rrd I've tried various placement of the '-not' and the )'s but I can't get it right. What am I missing? Have you tried find . -mtime +3w I don't know about the other syntax but this is what I find to be the simplest. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Find Syntax
OK, I understand now. I ultimately want to delete files and was just trying to check my command before doing the actual delete. I will use '-ls' in my script. find . -type f -mtime +1w -exec ls -l {} \; This works too. Thanks again! What is your intent with the -ls? Do you need the full listing because I find that if I just want to know what files are removed the -print switch is cleaner. Or, once I am comfortable that the command is doing what I want, leaving off the output entirely. For my temp file deletions I use /usr/bin/find /home/kevinb/tmp -atime +3 -exec rm {} \; Yes, I keep my own tmp/ directory below my home directory (it's an old habit). This command deletes anything I haven't accessed in three or more days. I use access (-atime) here but modification works just as well. I have that in a script which cron runs once a day so I can use my temporary folder and not worry about cleaning up after myself... and I know that anything I put there I expect to lose unless I find a reason to keep it and move it somewhere else. As a word of warning, don't run this in your home directory or in a location where there are files which will sit around without being used for months at a time. You would really be upset if ~/.cshrc happened to vanish or any other file you rely on but don't think of. -Kevin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Obtaining an @freebsd.org email address.
Does anyone know what the requirements for a freebsd.org email address are? I have looked but I can't seem to find a link to them nor a description of who I would contact concerning this. I have read the following from the porter's handbook ( http://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/keeping-up.html ) If you wish to use FreshPorts, all you need is an account. If your registered email address is @FreeBSD.org, you will see the opt-in link on the right hand side of the webpages. For those of you who already have a FreshPorts account, but are not using your @FreeBSD.org email address, just change your email to @FreeBSD.org, subscribe, then change it back again. This seems to imply that 1) I need an @freebsd.org email address to fully utilize the site 2) I should be able to get an @freebsd.org email address for being a port maintainer. My implications could be wrong so if anyone could point me in the right direction here (for clarification or who I should contact) it would be greatly appreciated. Thanks in advance, -Kevin B ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: fortune database
There are a couple of ports that install new fortune databases. See /usr/ports/games/fortune-* and the Porter's Handbook for more. Kris I think you meant to type /usr/ports/misc/fortune-* At least that is where I found mine. Thanks BTW... I was wondering if there were more I could add. Finally my excuse list is integrated into fortune. HA HA HA -- Down with disease, up before the dawn. A thousand barefoot children, dancin? on my lawn -Phish Down with Disease ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]