aboutsummaryrefslogblamecommitdiffstats
path: root/community/git-lfs/APKBUILD
blob: d5abb7f947333f59425cfd03bcf70c7da5727380 (plain) (tree)
1
2
3
4
5
6
7
8
9
10


                                               

            

                                                  
               

             
                     
                                                   
                                                      
                          
                                                                                            


                                     
 



                                                                        
 
         




                                            


         
                                                   





                                                     


                                                              

                                              





                                           







                                                                                                                                                                  
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=git-lfs
pkgver=2.7.2
pkgrel=0
pkgdesc="Git extension for versioning large files"
url="https://git-lfs.github.io/"
arch="all !x86"
license="MIT"
depends="git"
makedepends="go ronn"
checkdepends="bash coreutils git-daemon perl-utils"
install="$pkgname.post-install $pkgname.pre-deinstall"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/git-lfs/$pkgname/archive/v$pkgver.tar.gz
	fix-test-locks.patch
	makefile-extra_go_flags.patch
	"

# -tags netcgo - use system's DNS resolver by default. Go's built-in DNS
#   resolver is buggy; it resolved localhost to totally wrong IP
#   address on ARM builders and so caused test failures.
_goflags="-v -tags netcgo"

build() {
	make \
		EXTRA_GO_FLAGS="$_goflags" \
		GIT_LFS_SHA="v$pkgver" \
		VERSION="v$pkgver"
	make man
}

check() {
	make integration EXTRA_GO_FLAGS="$_goflags"
}

package() {
	local docdir="$pkgdir/usr/share/doc/$pkgname"
	local mandir="$pkgdir/usr/share/man"

	install -Dm755 bin/$pkgname "$pkgdir"/usr/bin/$pkgname

	mkdir -p "$mandir"/man1 "$mandir"/man5
	install -m 644 man/*.1 "$mandir"/man1/
	install -m 644 man/*.5 "$mandir"/man5/

	mkdir -p "$docdir"
	cp -r docs/*.md docs/api "$docdir"/
	rm -r "$docdir"/api/schemas
}

cleanup_srcdir() {
	go clean -modcache
	default_cleanup_srcdir
}

sha512sums="cd71815eb418b7acaf077de4873ff49d332f71151c1212ca4fe3a2d0e079bad873894bb416488f272777153cc3422deecf17a849cd67f150b44eb094a09ae8be  git-lfs-2.7.2.tar.gz
a551d99af1770ea1d1cd9ccc0fcbed6d7d79fe81da6d3dff2462473ee531b95ca36c7759e48ece5bff1162db3d4ca05b17dd59d5f5e355aef84297c36cb4acf2  fix-test-locks.patch
2d793da75b37324936407948fdb634ff4c510c4dd4d3575c2459b81a0a6eb8f2464f5066ae99e88d5bf69e357fd60354b9d9d53e062cb6ba709f5f3a39858466  makefile-extra_go_flags.patch"