Upload Tizen:Base source
authorKim Kibum <kb0929.kim@samsung.com>
Mon, 21 May 2012 08:40:59 +0000 (17:40 +0900)
committerKim Kibum <kb0929.kim@samsung.com>
Mon, 21 May 2012 08:40:59 +0000 (17:40 +0900)
packaging/diffutils-cmp-s-empty.patch [new file with mode: 0644]
packaging/diffutils.changes [new file with mode: 0644]
packaging/diffutils.spec [new file with mode: 0644]

diff --git a/packaging/diffutils-cmp-s-empty.patch b/packaging/diffutils-cmp-s-empty.patch
new file mode 100644 (file)
index 0000000..bc1c6b4
--- /dev/null
@@ -0,0 +1,20 @@
+diff -up diffutils-2.8.1/src/cmp.c.cmp-s-empty diffutils-2.8.1/src/cmp.c
+--- diffutils-2.8.1/src/cmp.c.cmp-s-empty      2002-04-05 21:37:31.000000000 +0100
++++ diffutils-2.8.1/src/cmp.c  2010-06-25 14:56:08.464802321 +0100
+@@ -316,12 +316,15 @@ main (int argc, char **argv)
+   /* If only a return code is needed,
+      and if both input descriptors are associated with plain files,
++     and if both files are larger than 0 bytes (procfs files are always 0),
+      conclude that the files differ if they have different sizes
+      and if more bytes will be compared than are in the smaller file.  */
+   if (comparison_type == type_status
+       && S_ISREG (stat_buf[0].st_mode)
+-      && S_ISREG (stat_buf[1].st_mode))
++      && S_ISREG (stat_buf[1].st_mode)
++      && stat_buf[0].st_size > 0
++      && stat_buf[1].st_size > 0)
+     {
+       off_t s0 = stat_buf[0].st_size - file_position (0);
+       off_t s1 = stat_buf[1].st_size - file_position (1);
diff --git a/packaging/diffutils.changes b/packaging/diffutils.changes
new file mode 100644 (file)
index 0000000..1c8738b
--- /dev/null
@@ -0,0 +1,2 @@
+* Fri Jul 29 2011 Junfeng Dong <junfeng.dong@intel.com> - 3.0
+- Import 3.0 for SLP.
diff --git a/packaging/diffutils.spec b/packaging/diffutils.spec
new file mode 100644 (file)
index 0000000..af528f6
--- /dev/null
@@ -0,0 +1,45 @@
+Name:           diffutils
+Version:        3.0
+Release:        1
+License:        GPLv2+
+Summary:        A GNU collection of diff utilities
+Url:            http://www.gnu.org/software/diffutils/diffutils.html
+Group:          Applications/Text
+Source:         ftp://ftp.gnu.org/gnu/diffutils/diffutils-%{version}.tar.xz
+Patch0:         diffutils-cmp-s-empty.patch
+
+%description
+Diffutils includes four utilities: diff, cmp, diff3 and sdiff. Diff
+compares two files and shows the differences, line by line.  The cmp
+command shows the offset and line numbers where two files differ, or
+cmp can show the characters that differ between the two files.  The
+diff3 command shows the differences between three files.  Diff3 can be
+used when two people have made independent changes to a common
+original; diff3 can produce a merged file that contains both sets of
+changes and warnings about conflicts.  The sdiff command can be used
+to merge two files interactively.
+
+Install diffutils if you need to compare text files.
+
+%prep
+%setup -q
+%patch0 -p1 
+
+%build
+%configure --disable-nls
+make PR_PROGRAM=%{_bindir}/pr
+
+%install
+%make_install
+
+%clean
+rm -rf %{buildroot}
+
+%docs_package 
+
+%files 
+%defattr(-,root,root,-)
+%doc NEWS README COPYING
+%{_bindir}/*
+%{_mandir}/*/*
+%{_infodir}/diff.info*gz