You are not logged in.

#1 2016-12-20 17:03:26

ale93p
Member
Registered: 2016-10-15
Posts: 8

[SOLVED] Error building tcptrace via yaourt

I'm trying to install tcptrace 6.6.7 from the AUR via yaourt. But it gets wrong, i receive the following errors:

Several times i get:

/usr/include/features.h:148:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
 # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"

And at the end:

tcpdump.o: In function `pread_tcpdump':
tcpdump.c:(.text+0x4d): undefined reference to `pcap_offline_read'
collect2: error: ld returned 1 exit status
make: *** [Makefile:189: tcptrace] Error 1

I tried to look for a solution but i didn't find anything useful. Does someone can help?
If there are further informations that I should share please let me know.

Last edited by ale93p (2016-12-23 17:25:06)

Offline

#2 2016-12-21 17:09:53

alex.theoto
Member
From: Athens Greece
Registered: 2014-11-30
Posts: 307

Re: [SOLVED] Error building tcptrace via yaourt

Don't use yaourt...
Start using 'makepkg'

Offline

#3 2016-12-21 18:04:38

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,868
Website

Re: [SOLVED] Error building tcptrace via yaourt

Good general advice, but won't help in this case.

The current version of tcptrace is 12 years old, and it's starting to show it's age. Well, I say "starting", but the bug you are encountering was reported and fixed in debian over 7 years ago. I have serious doubts that the package ever built on Arch in it's current state.

Here's a PKGBUILD that Works For Me™:

pkgname=tcptrace
pkgver=6.6.7
pkgrel=3
pkgdesc="A TCP dump file analysis tool"
arch=('i686' 'x86_64')
url="http://tcptrace.org/"
license=('GPL')
depends=('libpcap')
optdepends=(
  'tcpdump: for generating dumps'
  'gnuplot: for plotting graphs'
  'xplot: for plotting graphs'
)
source=(http://tcptrace.org/download/$pkgname-$pkgver.tar.gz
        http://http.debian.net/debian/pool/main/t/tcptrace/tcptrace_6.6.7-4.1.diff.gz)
md5sums=('68128dc1817b866475e2f048e158f5b9'
         'd073fb808e942f75399d035ba80c78cf')

prepare() {
  cd ${pkgname}-${pkgver}

  patch -p1 -i "$srcdir/tcptrace_6.6.7-4.1.diff"
  sed -e "s|BINDIR = /usr/local/bin|BINDIR = ${pkgdir}/usr/bin|" \
      -e "s|MANDIR = /usr/local/man/|MANDIR = ${pkgdir}/usr/share/man|" \
      -e "s|-o bin -g bin| -o root -g root|" -i Makefile.in
}

build() {
  cd ${pkgname}-${pkgver}

  ./configure
  make
}

package(){
  cd ${pkgname}-${pkgver}

  export DEB_BUILD_OPTIONS="nostrip"
  make install
  install -Dm755 "${srcdir}/${pkgname}-${pkgver}/xpl2gpl" \
    "${pkgdir}/usr/bin/xpl2gpl"
}

Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#4 2016-12-23 17:24:45

ale93p
Member
Registered: 2016-10-15
Posts: 8

Re: [SOLVED] Error building tcptrace via yaourt

Thanks to the both of you, I used 'makepkg' with this PKGBUILD and it seems to work, indeed both me and yaourt were using an old version of PKGBUILD.

Offline

Board footer

Powered by FluxBB