"make -C ..." causes error in net/tkabber/Makefile, line 17

parv parv at pair.com
Sun Feb 1 14:02:00 PST 2004


in message <20040201213549.GA93666 at moo.holy.cow>,
wrote parv thusly...
>
> I am running FreeBSD 4.8-p14; and the make(1) man page lists -C
> option...
>
>      -C directory
>           Change to directory while running.
>
>
> ...However, "make -V PORTVERSION" in net/tkabber" produces this...
>
>   make: illegal option -- C
>   usage: make [-Beiknqrstv] [-D variable] [-d flags] [-E variable] [-f makefile]
>               [-I directory] [-j max_jobs] [-m directory] [-V variable]
>               [variable=value] [target ...]
...

On the second thought, could it be that man page & binary are out of
sync for some reason?  It is hard to believe though as -C option
parsing appears in src/usr.bin/make/main.c, line 185...

  178  #ifdef REMOTE
  179  # define OPTFLAGS "BD:E:I:L:PSV:Xd:ef:ij:km:nqrstv"
  180  #else
  181  # define OPTFLAGS "BD:E:I:PSV:Xd:ef:ij:km:nqrstv"
  182  #endif
  183  rearg:  while((c = getopt(argc, argv, OPTFLAGS)) != -1) {
  184                  switch(c) {
  185                  case 'C':
  186                          if (chdir(optarg) == -1)
  187                                  err(1, "chdir %s", optarg);
  188                          break;


...but is omitted from OPTFLAGS (lines 179 & 181).  Is that the reason
of make carping when presented w/ -C option?


  - Parv

--



More information about the freebsd-ports mailing list