SHA256
1
0
forked from pool/git

Accepting request 66945 from devel:tools:scm

Accepted submit request 66945 from user dirkmueller

OBS-URL: https://build.opensuse.org/request/show/66945
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/git?expand=0&rev=54
This commit is contained in:
Ruediger Oertel 2011-04-21 11:26:23 +00:00 committed by Git OBS Bridge
parent 50a6de56ba
commit fe5317faff
11 changed files with 48 additions and 102 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:64c834eba1b16088206e4f7d95db83c8824ef3ee74f6a16fe03c80f72cb86709
size 54759

3
cgit-0.9.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:530eaf702b8ca0a44750f5ed1f27b1d74b317441cce9d2d4bb340c7dbea8a48f
size 63580

View File

@ -1,15 +0,0 @@
---
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/Makefile
+++ b/Makefile
@@ -68,7 +68,7 @@
$(QUIET_CC)$(CC) -o $*.o -c $(CFLAGS) $<
-EXTLIBS = git/libgit.a git/xdiff/lib.a -lz -lcrypto
+EXTLIBS = git/libgit.a git/xdiff/lib.a -lz -lcrypto -lpthread
OBJECTS =
OBJECTS += cache.o
OBJECTS += cgit.o

14
cgit-optflags.diff Normal file
View File

@ -0,0 +1,14 @@
---
Makefile | 1 +
1 file changed, 1 insertion(+)
--- a/Makefile
+++ b/Makefile
@@ -134,6 +134,7 @@
CFLAGS += -g -Wall -Igit
+CFLAGS += $(RPM_OPT_FLAGS)
CFLAGS += -DSHA1_HEADER='$(SHA1_HEADER)'
CFLAGS += -DCGIT_VERSION='"$(CGIT_VERSION)"'
CFLAGS += -DCGIT_CONFIG='"$(CGIT_CONFIG)"'

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Mon Mar 28 18:26:17 CEST 2011 - tiwai@suse.de
- updated to git 1.7.4.2:
documentation updates, small bug fixes;
see included Documentation/RelNotes/1.7.4.2.txt
- updated to cgit 0.9:
major updates; using git-1.7.4.x
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Dec 17 17:51:32 CET 2010 - tiwai@suse.de Fri Dec 17 17:51:32 CET 2010 - tiwai@suse.de

View File

@ -17,21 +17,20 @@
# norootforbuild # norootforbuild
%define git_version 1.7.4.1 %define git_version 1.7.4.2
Name: cgit Name: cgit
Url: http://hjemli.net/git/cgit/ Url: http://hjemli.net/git/cgit/
License: GPLv2 License: GPLv2
Group: Development/Libraries/C and C++ Group: Development/Libraries/C and C++
AutoReqProv: on AutoReqProv: on
Version: 0.8.3.3 Version: 0.9
Release: 5 Release: 5
Summary: A web frontend for git repositories Summary: A web frontend for git repositories
Source0: %{name}-%{version}.tar.bz2 Source0: %{name}-%{version}.tar.bz2
Source1: git-%{git_version}.tar.bz2 Source1: git-%{git_version}.tar.bz2
Source2: cgitrc Source2: cgitrc
Patch0: cgit-link-fixes.diff Patch: cgit-optflags.diff
Patch1: cgit_fix_stringlist.patch
# Requirements for cgit # Requirements for cgit
BuildRequires: git >= 1.7.1 BuildRequires: git >= 1.7.1
BuildRequires: gnu-crypto libopenssl-devel libzip-devel BuildRequires: gnu-crypto libopenssl-devel libzip-devel
@ -50,38 +49,36 @@ Authors:
%prep %prep
%setup -q %setup -q
%setup -q -T -D -a 1 %setup -q -T -D -a 1
%patch -p1
rm -rf git rm -rf git
mv git-%{git_version} git mv git-%{git_version} git
%patch0 -p1
%patch1 -p1
%build %build
make make V=1
make man-doc
%install %install
make install CGIT_SCRIPT_PATH="%{buildroot}"/srv/www/htdocs/cgit make install DESTDIR="%{buildroot}" CGIT_SCRIPT_PATH=/srv/www/htdocs/cgit
make install-man DESTDIR="%{buildroot}"
mkdir -p "%{buildroot}"/srv/www/cgi-bin/cgit/ mkdir -p "%{buildroot}"/srv/www/cgi-bin/cgit/
mv "%{buildroot}"/srv/www/{htdocs,cgi-bin}/cgit/cgit.cgi mv "%{buildroot}"/srv/www/{htdocs,cgi-bin}/cgit/cgit.cgi
mkdir -p "%{buildroot}%{_mandir}"/man5/
cp cgitrc.5 "%{buildroot}%{_mandir}"/man5/cgitrc.5
mkdir -p "%{buildroot}"/etc mkdir -p "%{buildroot}"/etc
cp %{SOURCE2} "%{buildroot}"/etc/cgitrc cp %{SOURCE2} "%{buildroot}"/etc/cgitrc
%clean %clean
make clean rm -rf %{buildroot}
%files %files
%defattr(-,root,root) %defattr(-,root,root)
%doc README COPYING
%doc %{_mandir}/man5/cgitrc.5.gz
%dir /srv/www/htdocs/cgit %dir /srv/www/htdocs/cgit
%dir /srv/www/cgi-bin/cgit %dir /srv/www/cgi-bin/cgit
/srv/www/cgi-bin/cgit/cgit.cgi /srv/www/cgi-bin/cgit/cgit.cgi
/srv/www/htdocs/cgit/cgit.css /srv/www/htdocs/cgit/cgit.css
/srv/www/htdocs/cgit/cgit.png /srv/www/htdocs/cgit/cgit.png
%doc %{_mandir}/man5/cgitrc.5.gz /usr/lib/cgit
%config(noreplace) /etc/cgitrc %config(noreplace) /etc/cgitrc
%changelog %changelog

View File

@ -1,66 +0,0 @@
Index: cgit-0.8.3.3/cgit.c
===================================================================
--- cgit-0.8.3.3.orig/cgit.c
+++ cgit-0.8.3.3/cgit.c
@@ -21,7 +21,7 @@ void add_mimetype(const char *name, cons
{
struct string_list_item *item;
- item = string_list_insert(xstrdup(name), &ctx.cfg.mimetypes);
+ item = string_list_insert(&ctx.cfg.mimetypes, xstrdup(name));
item->util = xstrdup(value);
}
Index: cgit-0.8.3.3/ui-stats.c
===================================================================
--- cgit-0.8.3.3.orig/ui-stats.c
+++ cgit-0.8.3.3/ui-stats.c
@@ -175,7 +175,7 @@ static void add_commit(struct string_lis
info = cgit_parse_commit(commit);
tmp = xstrdup(info->author);
- author = string_list_insert(tmp, authors);
+ author = string_list_insert(authors, tmp);
if (!author->util)
author->util = xcalloc(1, sizeof(struct authorstat));
else
@@ -186,7 +186,7 @@ static void add_commit(struct string_lis
date = gmtime(&t);
period->trunc(date);
tmp = xstrdup(period->pretty(date));
- item = string_list_insert(tmp, items);
+ item = string_list_insert(items, tmp);
if (item->util)
free(tmp);
item->util++;
@@ -279,7 +279,7 @@ void print_combined_authorrow(struct str
author = &authors->items[i];
authorstat = author->util;
items = &authorstat->list;
- date = string_list_lookup(tmp, items);
+ date = string_list_lookup(items, tmp);
if (date)
subtotal += (size_t)date->util;
}
@@ -331,7 +331,7 @@ void print_authors(struct string_list *a
for (j = 0; j < period->count; j++) {
tmp = period->pretty(tm);
period->inc(tm);
- date = string_list_lookup(tmp, items);
+ date = string_list_lookup(items, tmp);
if (!date)
html("<td>0</td>");
else {
Index: cgit-0.8.3.3/ui-plain.c
===================================================================
--- cgit-0.8.3.3.orig/ui-plain.c
+++ cgit-0.8.3.3/ui-plain.c
@@ -35,7 +35,7 @@ static void print_object(const unsigned
ctx.page.mimetype = NULL;
ext = strrchr(path, '.');
if (ext && *(++ext)) {
- mime = string_list_lookup(ext, &ctx.cfg.mimetypes);
+ mime = string_list_lookup(&ctx.cfg.mimetypes, ext);
if (mime)
ctx.page.mimetype = (char *)mime->util;
}

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:85c5afc1c8f96abcd8d1adfde6f813023bef5cec1dc0990fc3b159945b60cd1b
size 2703860

3
git-1.7.4.2.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4e2f4aedb5cb984c7da00a18f9ffcea1c1465191dd4afe2249d5bff17ae63970
size 2706400

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Mon Mar 28 18:18:54 CEST 2011 - tiwai@suse.de
- updated to 1.7.4.2:
* documentation updates, small bug fixes;
see included Documentation/RelNotes/1.7.4.2.txt
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Feb 24 17:42:33 CET 2011 - dmueller@suse.de Thu Feb 24 17:42:33 CET 2011 - dmueller@suse.de

View File

@ -38,7 +38,7 @@ BuildRequires: sgml-skel
BuildRequires: xmlto BuildRequires: xmlto
BuildRequires: python BuildRequires: python
BuildRequires: perl-Error BuildRequires: perl-Error
Version: 1.7.4.1 Version: 1.7.4.2
Release: 1 Release: 1
Summary: Fast, scalable, distributed revision control system Summary: Fast, scalable, distributed revision control system
License: GPLv2+ License: GPLv2+