Package Details: dnslookup-git 1:1.11.1.r1.g9b93ddd-1

Git Clone URL: https://aur.archlinux.org/dnslookup-git.git (read-only, click to copy)
Package Base: dnslookup-git
Description: Simple command line utility to make DNS lookups to the specified server
Upstream URL: https://github.com/ameshkov/dnslookup
Keywords: DNS network
Licenses: MIT
Conflicts: dnslookup
Provides: dnslookup
Submitter: krachyon
Maintainer: RiverOnVenus
Last Packager: RiverOnVenus
Votes: 3
Popularity: 0.005454
First Submitted: 2019-10-30 14:07 (UTC)
Last Updated: 2024-07-01 14:08 (UTC)

Dependencies (3)

Required by (0)

Sources (1)

Latest Comments

dreieck commented on 2024-04-11 15:27 (UTC)

Please change the source download protocol from git:// to git+https://.
Otherwise download will fail with a timeout due to changes at github.com.

Regards!

krachyon commented on 2023-09-23 18:49 (UTC)

Hi dreieck,

first of all thanks for basically doing the work for me, I incorporated your changes.

To be honest I forgot I submitted this package and have not really used it in the meantime or maintained any other packages so wasn't up to date on the guidelines. So I'd be glad to add you as co-maintainer or hand it over completely if you actively use it and wouldn't mind maintaining.

dreieck commented on 2023-09-20 12:35 (UTC)

Please add

provides=("dnslookup=${pkgver}")
conflicts=("dnslookup")

(the =${pkgver} only if pkgver() has been changed to provide official version number.)

Regards and thanks for maintaining!

dreieck commented on 2023-09-20 12:34 (UTC)

Actually, there is an official version information available:

git describe --tags currently produces v1.9.2-1-g5be7339.

According to the Arch Linux VCS packaging guidelines, official version numbers should be used as the first part of $pkgver if available (and leading v stripped off).

So, e.g. the following pkgver() could be used:

pkgver() {
  cd "${srcdir}/dnslookup"

  _ver="$(git describe  --tags | sed 's|^[vV]||' | sed 's|-g[0-9a-fA-F]*$||' | tr '-' '+')"
  _rev="$(git rev-list --count HEAD)"
  _date="$(git log -1 --date=format:"%Y%m%d" --format="%ad")"
  _hash="$(git rev-parse --short HEAD)"

  if [ -z "${_ver}" ]; then
    error "Version could not be determined."
    return 1
  else
    printf '%s' "${_ver}.r${_rev}.${_date}.${_hash}"
  fi
}

which currently produces 1.9.2+1.r73.20230814.

Regards!

dreieck commented on 2023-09-20 12:31 (UTC)

You have arch=('any'), but you build a binary.

Please specify proper arch entries!, e.g.

arch=(
  'aarch64'
  'armv6h'
  'armv7h'
  'i686'
  'x86_64'
)

Regards and thanks for maintaining!

dreieck commented on 2023-09-20 12:26 (UTC) (edited on 2023-09-20 12:30 (UTC) by dreieck)

After correcting the source download protocol error, build succeeds and package() fails with

==> Starting package()...
install: cannot stat '/tmp/makepkg/build/dnslookup-git/src/gopath/bin/dnslookup': No such file or directory

It turns out that go did place the built binary into "$GOBIN", which I have defined in my /etc/makepkg.conf to be /tmp/makepkg/.go/bin.

The following new package() function would take care of that:

package(){
    mkdir -p "${pkgdir}/usr/bin"

    if [ -v GOBIN ]; then
      _binpath="${GOBIN}"
    else
      _binpath="${srcdir}/gopath/bin"
    fi
    install "${_binpath}/dnslookup" "${pkgdir}/usr/bin/dnslookup"
}

Regards!

dreieck commented on 2023-09-20 12:20 (UTC)

You need to change the source download protocol from git:// to git+https:// due to changes at github.com.

Currently, download fails:

  -> Cloning dnslookup git repo...
Cloning into bare repository '/tmp/makepkg/sources/dnslookup'...
fatal: unable to connect to github.com:
github.com[0: 140.82.121.4]: errno=Connection timed out

==> ERROR: Failure while downloading dnslookup git repo

Regards!