Bug 151430 - [patch] net-mgmt/kismet fails to build with plugins
Summary: [patch] net-mgmt/kismet fails to build with plugins
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Brendan Fabeny
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-13 16:00 UTC by Alexander
Modified: 2010-11-06 00:32 UTC (History)
0 users

See Also:


Attachments
file.diff (1.27 KB, patch)
2010-10-13 16:00 UTC, Alexander
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander 2010-10-13 16:00:16 UTC
First:
-----
In Makefile.inc.in:
..
PLUGINLDFLAGS = @PLUGINLDFLAGS@
..

In FreeBSD kismet configures with empty @PLUGINLDFLAGS@, so PLUGINLDFLAGS in Makefile.inc has empty value.

In plugins Makefiles:
..
PLUGINLDFLAGS ?= $(LDFLAGS)
..
so, plugin fails to build without any LDFLAGS.

I suggest to remove "PLUGINLDFLAGS = @PLUGINLDFLAGS@" from Makefile.inc.in.


Second:
-----
In /usr/ports/net-mgmt/kismet/Makefile:
..
${REINPLACE_CMD} -e "s/plugin-/plugin-[aps]/" \
..
so, builds only plugin-autowep, plugin-ptw & plugin-spectools, without plugin-btscan.

Fix: In attached patch.

Patch attached with submission follows:
How-To-Repeat: # cd /usr/ports/net-mgmt/kismet
# make config
Enable PLUGINS option
Comment 1 Edwin Groothuis freebsd_committer 2010-10-13 16:00:23 UTC
Responsible Changed
From-To: freebsd-ports-bugs->bf

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 b. f. 2010-10-13 16:57:06 UTC
Well, generally speaking, it doesn't fail to "build with plugins", but
yes, to be safe I'll fix the LDFLAGS. Thanks.  As for the btscan
plugin, I left it out because it was advertised as working only on
Linux, and I didn't have the hardware to test it.  Can you confirm
that it works as intended on FreeBSD?

b.
Comment 3 Alexander 2010-10-13 18:33:52 UTC
Without patch, it fails with:

PLUGIN: plugin-autowep/
gmake[2]: Entering directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1/plugin-autowep'
c++ -I/usr/local/include -I/usr/include/ncurses -I/usr/include
-I/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1 -g -fPIC -c
autowep-kismet.cc -o autowep-kismet.o
c++ -shared -rdynamic autowep-kismet.o -o autowep-kismet.so -lutil -lpcre
-lstdc++
/usr/bin/ld: cannot find -lpcre
gmake[2]: *** [autowep-kismet.so] Error 1
gmake[2]: Leaving directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1/plugin-autowep'
PLUGIN: plugin-ptw/
gmake[2]: Entering directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1/plugin-ptw'
c++ -I/usr/local/include -I/usr/include/ncurses -I/usr/include
-I/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1 -g -fPIC -c
aircrack-crypto.cc -o aircrack-crypto.o
c++ -I/usr/local/include -I/usr/include/ncurses -I/usr/include
-I/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1 -g -fPIC -c
aircrack-ptw2-lib.cc -o aircrack-ptw2-lib.o
c++ -I/usr/local/include -I/usr/include/ncurses -I/usr/include
-I/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1 -g -fPIC -c
aircrack-kismet.cc -o aircrack-kismet.o
c++ -shared -rdynamic aircrack-crypto.o aircrack-ptw2-lib.o
aircrack-kismet.o -o aircrack-kismet.so -lutil -lpcre -lstdc++ -lssl
-lpthread -lcrypto
/usr/bin/ld: cannot find -lpcre
gmake[2]: *** [aircrack-kismet.so] Error 1
gmake[2]: Leaving directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1/plugin-ptw'
PLUGIN: plugin-spectools/
gmake[2]: Entering directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1/plugin-spectools'
c++ -I/usr/local/include -I/usr/include/ncurses -I/usr/include
-I/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1 -g -fPIC -c
spectool_netclient.cc -o spectool_netclient.o
c++ -I/usr/local/include -I/usr/include/ncurses -I/usr/include
-I/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1 -g -fPIC -c
spectool_kismet.cc -o spectool_kismet.o
c++ -shared -rdynamic spectool_netclient.o spectool_kismet.o -o
spectool_net.so -lutil -lpcre -lstdc++
/usr/bin/ld: cannot find -lpcre
gmake[2]: *** [spectool_net.so] Error 1
gmake[2]: Leaving directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1/plugin-spectools'
gmake[1]: *** [plugins] Error 2
gmake[1]: Leaving directory
`/usr/ports/net-mgmt/kismet/work/kismet-2010-07-R1'
gmake: *** [all-with-plugins] Error 2
*** Error code 1

Stop in /usr/ports/net-mgmt/kismet.
*** Error code 1

Stop in /usr/ports/net-mgmt/kismet.

===>>> make failed for net-mgmt/kismet
===>>> Aborting update
Comment 4 Alexander 2010-10-13 18:41:11 UTC
plugin-btscan really don't works on FreeBSD, I don't read readme, sorry :)
Comment 5 dfilter service freebsd_committer 2010-10-29 17:35:14 UTC
bf          2010-10-29 16:34:58 UTC

  FreeBSD ports repository

  Modified files:
    net-mgmt/kismet      Makefile distinfo 
  Log:
  Fix plugins build with CC=cc [1]; remove md5 checksums
  from distinfo
  
  PR:             151430 [1]
  Submitted by:   Alexander <bas@it-core.org> [1]
  Approved by:    makc, miwi (mentors, implicit)
  
  Revision  Changes    Path
  1.31      +3 -1      ports/net-mgmt/kismet/Makefile
  1.14      +0 -2      ports/net-mgmt/kismet/distinfo
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 6 Brendan Fabeny freebsd_committer 2010-11-06 00:32:24 UTC
State Changed
From-To: open->closed

Committed, with minor changes. Thanks!