Merge pull request !1 from jinjin/yang
This commit is contained in:
openeuler-ci-bot 2019-12-16 21:20:26 +08:00 committed by Gitee
commit 0394b5bfa6
7 changed files with 4028 additions and 75 deletions

View File

@ -1,36 +0,0 @@
# plotutils
#### Description
{**When you're done, you can delete the content in this README and update the file with details for others getting started with your repository**}
#### Software Architecture
Software architecture description
#### Installation
1. xxxx
2. xxxx
3. xxxx
#### Instructions
1. xxxx
2. xxxx
3. xxxx
#### Contribution
1. Fork the repository
2. Create Feat_xxx branch
3. Commit your code
4. Create Pull Request
#### Gitee Feature
1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md
2. Gitee blog [blog.gitee.com](https://blog.gitee.com)
3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore)
4. The most valuable open source project [GVP](https://gitee.com/gvp)
5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help)
6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)

View File

@ -1,39 +0,0 @@
# plotutils
#### 介绍
{**以下是码云平台说明,您可以替换此简介**
码云是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN。专为开发者提供稳定、高效、安全的云端软件开发协作平台
无论是个人、团队、或是企业,都能够用码云实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)}
#### 软件架构
软件架构说明
#### 安装教程
1. xxxx
2. xxxx
3. xxxx
#### 使用说明
1. xxxx
2. xxxx
3. xxxx
#### 参与贡献
1. Fork 本仓库
2. 新建 Feat_xxx 分支
3. 提交代码
4. 新建 Pull Request
#### 码云特技
1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md
2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com)
3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目
4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目
5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)

39
plotutils-2.6-png15.patch Normal file
View File

@ -0,0 +1,39 @@
diff -up plotutils-2.6/libplot/z_write.c.png15 plotutils-2.6/libplot/z_write.c
--- plotutils-2.6/libplot/z_write.c.png15 2008-07-15 20:54:10.000000000 -0400
+++ plotutils-2.6/libplot/z_write.c 2012-03-22 13:26:48.251676137 -0400
@@ -164,7 +164,11 @@ _pl_z_maybe_output_image (S___(Plotter *
}
/* cleanup after libpng errors (error handler does a longjmp) */
+#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4
+ if (setjmp (png_jmpbuf(png_ptr)))
+#else
if (setjmp (png_ptr->jmpbuf))
+#endif
{
png_destroy_write_struct (&png_ptr, (png_info **)NULL);
return -1;
@@ -444,7 +448,11 @@ _our_error_fn_stdio (png_struct *png_ptr
#endif
}
+#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4
+ longjmp (png_jmpbuf(png_ptr), 1);
+#else
longjmp (png_ptr->jmpbuf, 1);
+#endif
}
static void
@@ -515,7 +523,11 @@ _our_error_fn_stream (png_struct *png_pt
#endif
}
+#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4
+ longjmp (png_jmpbuf(png_ptr), 1);
+#else
longjmp (png_ptr->jmpbuf, 1);
+#endif
}
static void

BIN
plotutils-2.6.tar.gz Normal file

Binary file not shown.

3889
plotutils-aarch64.patch Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,13 @@
diff --git a/pic2plot/gram.yy b/pic2plot/gram.yy
index d11320b..1bcce46 100644
--- a/pic2plot/gram.yy
+++ b/pic2plot/gram.yy
@@ -1833,7 +1833,7 @@ do_sprintf(const char *form, const double *v, int nv)
{
one_format += *form++;
one_format += '\0';
- sprintf(sprintf_buf, one_format.contents());
+ sprintf(sprintf_buf, "%s", one_format.contents());
}
else
{

87
plotutils.spec Normal file
View File

@ -0,0 +1,87 @@
Name: plotutils
Version: 2.6
Release: 22
Summary: Tools for generating 2D plot graphics based on data sets
License: GPLv2+ and GPLv3+
URL: http://www.gnu.org/software/plotutils/
Source0: ftp://ftp.gnu.org/gnu/plotutils/plotutils-%{version}.tar.gz
Patch0000: plotutils-2.6-png15.patch
Patch0001: plotutils-aarch64.patch
Patch0002: plotutils-werror-format-security.patch
BuildRequires: gcc-c++ make flex libpng-devel xorg-x11-proto-devel
BuildRequires: libX11-devel libXaw-devel libXt-devel libXext-devel byacc
Requires(post): /sbin/install-info
Requires(post): /sbin/ldconfig
Requires(preun): /sbin/install-info
%description
The GNU plotutils package contains software for both programmers and technical users.
%package devel
Summary: Header files and libraries that use plotutils
Requires: %{name} = %{version}-%{release}
%description devel
This package contains the header files and libraries that use plotutils.
%package help
Summary: man info for plotutils
%description help
The package contains man information for plotutils.
%prep
%autosetup %{name}-%{version} -p1
%build
%configure --disable-static --enable-libplotter --enable-libxmi --enable-ps-fonts-in-pcl
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
%make_build
%install
rm -rf docs-plot
%make_install
mkdir docs-plot
mv ${RPM_BUILD_ROOT}%{_datadir}/{ode,pic2plot,libplot,tek2plot} docs-plot
%delete_la
%post
/sbin/install-info %{_infodir}/libxmi.info %{_infodir}/dir || :
/sbin/install-info %{_infodir}/plotutils.info %{_infodir}/dir || :
/sbin/ldconfig
%preun
if [ $1 = 0 ]; then
/sbin/install-info --delete %{_infodir}/libxmi.info %{_infodir}/dir || :
/sbin/install-info --delete %{_infodir}/plotutils.info %{_infodir}/dir || :
fi
%postun
/sbin/ldconfig
%files
%doc AUTHORS COMPAT COPYING
%doc docs-plot/*
%{_bindir}/*
%{_libdir}/*.so.*
%{_infodir}/*.info*
%exclude %{_infodir}/dir
%files devel
%doc TODO
%{_includedir}/*.h
%{_libdir}/*.so
%files help
%doc NEWS THANKS README PROBLEMS KNOWN_BUGS
%{_mandir}/man1/*
%changelog
* Mon Dec 16 2019 lijin Yang <yanglijin@huawei.com> - 2.6-22
- init package