mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 05:10:05 +02:00
366 lines
9.8 KiB
Bash
366 lines
9.8 KiB
Bash
SUMMARY="Fast, scalable, distributed revision control system"
|
|
DESCRIPTION="Git is a free and open source distributed version control system \
|
|
designed to handle everything from small to very large projects with speed \
|
|
and efficiency.
|
|
|
|
Git is easy to learn and has a tiny footprint with lightning fast performance. \
|
|
It outclasses SCM tools like Subversion, CVS, Perforce, and ClearCase with \
|
|
features like cheap local branching, convenient staging areas, and multiple \
|
|
workflows."
|
|
HOMEPAGE="https://git-scm.com/"
|
|
COPYRIGHT="2005-2025 Git Authors (see git web site for list)"
|
|
LICENSE="GNU GPL v2"
|
|
REVISION="1"
|
|
SOURCE_URI="https://www.kernel.org/pub/software/scm/git/git-$portVersion.tar.xz"
|
|
CHECKSUM_SHA256="7e3e6c36decbd8f1eedd14d42db6674be03671c2204864befa2a41756c5c8fc4"
|
|
SOURCE_URI_2="https://www.kernel.org/pub/software/scm/git/git-manpages-$portVersion.tar.xz"
|
|
CHECKSUM_SHA256_2="7dd86882bbc22bef8852924de96b9cb378aad8532089e301c82093da3e7c5478"
|
|
SOURCE_URI_3="https://www.kernel.org/pub/software/scm/git/git-htmldocs-$portVersion.tar.xz"
|
|
CHECKSUM_SHA256_3="d15ccd1518b822e317d14b63de4444bb288909294f117cbbfa385c60ab739bca"
|
|
PATCHES="git-$portVersion.patchset"
|
|
|
|
ARCHITECTURES="all !x86_gcc2"
|
|
SECONDARY_ARCHITECTURES="x86"
|
|
|
|
GLOBAL_WRITABLE_FILES="
|
|
settings/gitconfig keep-old
|
|
"
|
|
USER_SETTINGS_FILES="
|
|
settings/git directory
|
|
"
|
|
|
|
portVersionCompat="$portVersion compat >= 2.3"
|
|
|
|
PROVIDES="
|
|
git$secondaryArchSuffix = $portVersionCompat
|
|
cmd:git = $portVersionCompat
|
|
cmd:git_receive_pack = $portVersionCompat
|
|
cmd:git_shell = $portVersionCompat
|
|
cmd:git_upload_archive = $portVersionCompat
|
|
cmd:git_upload_pack = $portVersionCompat
|
|
"
|
|
if [ "$targetArchitecture" = x86_gcc2 ]; then
|
|
REPLACES="
|
|
git
|
|
"
|
|
fi
|
|
PROVIDES_arch="
|
|
git${secondaryArchSuffix}_arch = $portVersionCompat
|
|
cmd:git_archimport = $portVersionCompat
|
|
"
|
|
PROVIDES_cvs="
|
|
git${secondaryArchSuffix}_cvs = $portVersionCompat
|
|
cmd:git_cvsimport = $portVersionCompat
|
|
cmd:git_cvsserver = $portVersionCompat
|
|
"
|
|
PROVIDES_daemon="
|
|
git${secondaryArchSuffix}_daemon = $portVersionCompat
|
|
cmd:git_daemon = $portVersionCompat
|
|
"
|
|
PROVIDES_email="
|
|
git${secondaryArchSuffix}_email = $portVersionCompat
|
|
cmd:git_send_email = $portVersionCompat
|
|
"
|
|
PROVIDES_gui="
|
|
git${secondaryArchSuffix}_gui = $portVersionCompat
|
|
cmd:git_gui = $portVersionCompat
|
|
cmd:gitk = $portVersionCompat
|
|
"
|
|
PROVIDES_perl="
|
|
git${secondaryArchSuffix}_perl = $portVersionCompat
|
|
"
|
|
if [ -n "$secondaryArchSuffix" ]; then
|
|
PROVIDES_perl+="
|
|
git_perl = $portVersionCompat
|
|
"
|
|
fi
|
|
PROVIDES_scalar="
|
|
git${secondaryArchSuffix}_scalar = $portVersionCompat
|
|
cmd:scalar = $portVersionCompat
|
|
"
|
|
PROVIDES_source="
|
|
git${secondaryArchSuffix}_source = $portVersionCompat
|
|
"
|
|
PROVIDES_svn="
|
|
git${secondaryArchSuffix}_svn = $portVersionCompat
|
|
cmd:git_svn = $portVersionCompat
|
|
"
|
|
PROVIDES_web="
|
|
git${secondaryArchSuffix}_web = $portVersionCompat
|
|
"
|
|
if [ "$targetArchitecture" = x86_gcc2 ]; then
|
|
for pkg in arch cvs daemon email gui scalar source svn; do eval "REPLACES_${pkg}=git_${pkg}"; done
|
|
fi
|
|
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
cmd:man
|
|
cmd:nano
|
|
lib:libcurl$secondaryArchSuffix
|
|
lib:libexpat$secondaryArchSuffix
|
|
lib:libiconv$secondaryArchSuffix
|
|
lib:libintl$secondaryArchSuffix
|
|
lib:libpcre2_8$secondaryArchSuffix
|
|
lib:libnghttp2$secondaryArchSuffix
|
|
lib:libssl$secondaryArchSuffix
|
|
lib:libz$secondaryArchSuffix
|
|
"
|
|
REQUIRES_arch="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
git${secondaryArchSuffix}_perl == $portVersion
|
|
"
|
|
REQUIRES_cvs="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
git${secondaryArchSuffix}_perl == $portVersion
|
|
cmd:cvsps
|
|
"
|
|
REQUIRES_daemon="
|
|
haiku$secondaryArchSuffix
|
|
lib:libcrypto$secondaryArchSuffix
|
|
lib:libiconv$secondaryArchSuffix
|
|
lib:libintl$secondaryArchSuffix
|
|
lib:libpcre2_8$secondaryArchSuffix
|
|
lib:libz$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
"
|
|
REQUIRES_email="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
git${secondaryArchSuffix}_perl == $portVersion
|
|
"
|
|
REQUIRES_gui="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
cmd:wish
|
|
"
|
|
REQUIRES_perl="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
cmd:perl >= 5
|
|
vendor_perl
|
|
"
|
|
REQUIRES_scalar="
|
|
haiku$secondaryArchSuffix
|
|
lib:libiconv$secondaryArchSuffix
|
|
lib:libintl$secondaryArchSuffix
|
|
lib:libpcre2_8$secondaryArchSuffix
|
|
lib:libz$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
"
|
|
|
|
REQUIRES_svn="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
git${secondaryArchSuffix}_perl == $portVersion
|
|
subversion${secondaryArchSuffix}_perl
|
|
termreadkey$secondaryArchSuffix
|
|
"
|
|
REQUIRES_web="
|
|
haiku$secondaryArchSuffix
|
|
git$secondaryArchSuffix == $portVersion base
|
|
git${secondaryArchSuffix}_perl == $portVersion
|
|
cgi # CGI.pm
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
devel:libcurl$secondaryArchSuffix
|
|
devel:libexpat$secondaryArchSuffix
|
|
devel:libiconv$secondaryArchSuffix
|
|
devel:libintl$secondaryArchSuffix
|
|
devel:libnghttp2$secondaryArchSuffix
|
|
devel:libpcre2_8$secondaryArchSuffix
|
|
devel:libssl$secondaryArchSuffix
|
|
devel:libz$secondaryArchSuffix
|
|
vendor_perl >= 5.40
|
|
"
|
|
|
|
BUILD_PREREQUIRES="
|
|
cmd:awk
|
|
cmd:cmp
|
|
cmd:find
|
|
cmd:gcc$secondaryArchSuffix
|
|
cmd:gettext
|
|
cmd:ld$secondaryArchSuffix
|
|
cmd:make
|
|
cmd:man
|
|
cmd:msgfmt
|
|
cmd:nano
|
|
cmd:perl >= 5.40
|
|
cmd:sed
|
|
cmd:tar
|
|
"
|
|
|
|
TEST_REQUIRES="
|
|
cmd:diff
|
|
cmd:gawk
|
|
"
|
|
|
|
makeGit()
|
|
{
|
|
make prefix=$prefix \
|
|
bindir_relative=$relativeBinDir \
|
|
mandir=$manDir \
|
|
infodir=$infoDir \
|
|
gitexecdir=$libDir/git-core \
|
|
sharedir=$dataDir \
|
|
template_dir=$dataDir/git-core/templates \
|
|
htmldir=$docDir \
|
|
sysconfdir=$sysconfDir \
|
|
PTHREAD_LIBS= \
|
|
USE_LIBPCRE2=YesPlease \
|
|
NO_D_TYPE_IN_DIRENT=YesPlease \
|
|
NO_MEMMEM=YesPlease \
|
|
NEEDS_LIBICONV=YesPlease \
|
|
PERL_PATH=/bin/perl \
|
|
perllibdir=$prefix/$(perl -V:installvendorlib | cut -d\' -f2 | cut -d/ -f5-) \
|
|
NO_PYTHON=YesPlease \
|
|
OBJECT_CREATION_USES_RENAMES=YesPlease \
|
|
NO_CROSS_DIRECTORY_HARDLINKS=YesPlease \
|
|
NO_INSTALL_HARDLINKS=YesPlease \
|
|
HAVE_DEV_TTY=YesPlease \
|
|
DEFAULT_EDITOR=nano \
|
|
DEFAULT_HELP_FORMAT=web \
|
|
BASIC_LDFLAGS="-lnetwork -lbsd" \
|
|
CPPFLAGS="-D_POSIX_THREAD_SAFE_FUNCTIONS" \
|
|
"$@"
|
|
}
|
|
|
|
BUILD()
|
|
{
|
|
makeGit $jobArgs
|
|
makeGit strip
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
makeGit install
|
|
|
|
# copy manpages
|
|
mkdir -p $manDir
|
|
cp -rd $sourceDir2/* $manDir/
|
|
|
|
# copy html documentation
|
|
htmlDir=$docDir
|
|
mkdir -p $htmlDir
|
|
cp -rd $sourceDir3/*.html $htmlDir/
|
|
|
|
# Add bash-completions (will work if the "bash_completion" package is installed).
|
|
install -d -m 755 $dataDir/bash-completion/completions
|
|
install -m 644 $sourceDir/contrib/completion/git-completion.bash $dataDir/bash-completion/completions/git
|
|
# Remove the one that gets installed via "makeGit install" (starting with git 2.50.0).
|
|
rm -rf $prefix/share
|
|
|
|
# Default system-wide gitconfig. Settings in this file are only used
|
|
# if they are unset both for the repository and globally (global options
|
|
# are saved in the user settings file).
|
|
# core.untrackedCache caches enumeration of untracked files and uses an
|
|
# efficient method of determining whether the cache is out of date. This
|
|
# is filesystem-dependent, but supported on BeFS.
|
|
mkdir -p $sysconfDir
|
|
printf "[core]\n untrackedCache = true" > $sysconfDir/gitconfig
|
|
|
|
# replace copies of git binaries with symlinks
|
|
cd $prefix/bin
|
|
for program in git*; do
|
|
if [ $program = "gitk" ]; then
|
|
continue
|
|
fi
|
|
ln -sfn "$libDir/git-core/$program" "$program"
|
|
done
|
|
ln -sfn "$libDir/git-core/scalar" "scalar"
|
|
|
|
packageEntries arch \
|
|
$docDir/git-archimport.html \
|
|
$manDir/man1/git-archimport.1 \
|
|
$libDir/git-core/git-archimport
|
|
|
|
packageEntries cvs \
|
|
$prefix/bin/git-cvsserver \
|
|
$docDir/git-cvsexportcommit.html \
|
|
$docDir/git-cvsimport.html \
|
|
$docDir/git-cvsserver.html \
|
|
$manDir/man1/git-cvsexportcommit.1 \
|
|
$manDir/man1/git-cvsimport.1 \
|
|
$manDir/man1/git-cvsserver.1 \
|
|
$manDir/man7/gitcvs-migration.7 \
|
|
$libDir/git-core/git-cvsexportcommit \
|
|
$libDir/git-core/git-cvsimport \
|
|
$libDir/git-core/git-cvsserver
|
|
|
|
packageEntries daemon \
|
|
$docDir/git-credential-cache--daemon.html \
|
|
$docDir/git-credential-cache.html \
|
|
$docDir/git-daemon.html \
|
|
$manDir/man1/git-credential-cache--daemon.1 \
|
|
$manDir/man1/git-credential-cache.1 \
|
|
$manDir/man1/git-daemon.1 \
|
|
$libDir/git-core/git-credential-cache--daemon \
|
|
$libDir/git-core/git-credential-cache \
|
|
$libDir/git-core/git-daemon
|
|
|
|
packageEntries email \
|
|
$docDir/git-send-email.html \
|
|
$manDir/man1/git-send-email.1 \
|
|
$libDir/git-core/git-send-email
|
|
|
|
packageEntries gui \
|
|
$docDir/git-gui.html \
|
|
$docDir/gitk.html \
|
|
$manDir/man1/git-gui.1 \
|
|
$manDir/man1/gitk.1 \
|
|
$dataDir/gitk \
|
|
$dataDir/git-gui \
|
|
$libDir/git-core/git-gui \
|
|
$libDir/git-core/git-gui--askpass \
|
|
$libDir/git-core/git-citool \
|
|
$prefix/bin/gitk
|
|
|
|
packageEntries perl \
|
|
$prefix/lib/perl5
|
|
|
|
packageEntries scalar \
|
|
$docDir/scalar.html \
|
|
$manDir/man1/scalar.1 \
|
|
$libDir/git-core/scalar \
|
|
$prefix/bin/scalar
|
|
|
|
packageEntries svn \
|
|
$docDir/git-svn.html \
|
|
$manDir/man1/git-svn.1 \
|
|
$libDir/git-core/git-svn
|
|
|
|
packageEntries web \
|
|
$docDir/gitweb*.html \
|
|
$docDir/git-instaweb.html \
|
|
$manDir/man1/gitweb.1 \
|
|
$manDir/man1/git-instaweb.1 \
|
|
$manDir/man5/gitweb.conf.5 \
|
|
$dataDir/gitweb \
|
|
$libDir/git-core/git-instaweb
|
|
}
|
|
|
|
# Note/Warning: "hp git --test" can take several hours (4 or 5).
|
|
TEST()
|
|
{
|
|
# Version 2.45.2, results on x86_64 hrev57801 with perl 5.32.1:
|
|
#failed test(s): t0005 t0006 t0007 t0033 t0061 t0210 t0211 t0301 t0302 t0410 t1060 t1300 t1305 t1306 t1308 t1309 t1419 t1800 t2400 t3600 t3903 t5000 t5300 t5329 t5351 t5604 t5605 t5702 t5810 t5814 t7060 t7300 t7408 t7450 t7701 t7704 t7900
|
|
#
|
|
#fixed 1
|
|
#success 28386
|
|
#failed 97
|
|
#broken 264
|
|
#total 29438
|
|
|
|
cat << DONE
|
|
!!Make sure to configure the debug_server in \
|
|
~/config/settings/system/debug_server/settings:
|
|
executable_actions {
|
|
/sources/git-* kill
|
|
}
|
|
DONE
|
|
makeGit $jobArgs test
|
|
}
|