recipe 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. # Build recipe for musl.
  2. #
  3. # Copyright (C) 2015-2017 Matias A. Fonzo, selk@dragora.org.
  4. # Copyright (C) 2017 Mateus P. Rodrigues, mprodrigues@dragora.org.
  5. #
  6. # This recipe is free software: you have unlimited permission
  7. # to copy, distribute and modify it.
  8. program=musl
  9. version=1.1.16
  10. release=1
  11. tarname=${program}-${version}.tar.gz
  12. # Remote source(s)
  13. fetch=http://www.musl-libc.org/releases/$tarname
  14. description="
  15. A powerful standard C/POSIX library.
  16. Musl is a new standard library to power a new generation of Linux-based
  17. devices. Musl is lightweight, fast, simple, free, and strives to be
  18. correct in the sense of standards-conformance and safety.
  19. "
  20. homepage=http://www.musl-libc.org
  21. license=MIT
  22. # Source documentation
  23. docs="COPYRIGHT README VERSION WHATSNEW"
  24. docsdir="${docdir}/${program}-${version}"
  25. build()
  26. {
  27. set -e
  28. unpack "${tardir}/$tarname"
  29. cd "$srcdir"
  30. patch -Np0 -i "/home/mprodrigues/repositories/dragora/patches/musl/musl-utmp_path.diff"
  31. ./configure --prefix=/opt/musl \
  32. --enable-shared \
  33. --enable-static \
  34. --enable-optimize=size
  35. make -j${jobs}
  36. make -j${jobs} install DESTDIR="$destdir"
  37. # Copy documentation
  38. mkdir -p "${destdir}${docsdir}"
  39. for file in $docs
  40. do
  41. cp -p $file "${destdir}${docsdir}"
  42. done
  43. }