texworks-vl.spec 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168
  1. %define svnrevision 950
  2. %define templates_japanese 1
  3. %define templates_japanese_version 20110626
  4. %define _qt4_qmake %{_libdir}/qt4/bin/qmake
  5. ## Summary/Description adopted from Debian with modification
  6. Name: texworks
  7. Version: 0.5
  8. Release: 1%{?svnrevision:.svn%svnrevision}%{?_dist_release}
  9. Summary: An environment for authoring TeX (LaTeX, ConTeXt, etc) documents
  10. Summary(ja): TeX ドキュメント制作のための総合環境
  11. Group: Applications/Editors
  12. License: GPLv2+
  13. URL: http://tug.org/texworks/
  14. Source0: http://texworks.googlecode.com/files/%{name}-%{version}%{?svnrevision:.svn%svnrevision}.tar.%{?svnrevision:bz2}%{!?svnrevision:gz}
  15. #Source0: http://texworks.googlecode.com/files/%{name}-%{version}-r858.tar.gz
  16. # Desktop file adopted from Debian with modification
  17. Source1: %{name}.desktop
  18. ## vine
  19. Source10: texworks-snapshot.sh
  20. %if %{templates_japanese}
  21. Source50: texworks-templates-japanese-%{templates_japanese_version}.tar.xz
  22. %endif
  23. Source100: pdfplatex.sh
  24. Source101: pdfeplatex.sh
  25. ## vine
  26. Patch100: texworks-0.4.1-ptex-vine-vl6.patch
  27. Patch101: texworks-0.5.svn950-vine-vl7.patch
  28. BuildRequires: hunspell-devel
  29. BuildRequires: dbus-devel
  30. BuildRequires: poppler-qt4-devel
  31. BuildRequires: desktop-file-utils
  32. BuildRequires: texlive-common
  33. Requires: texlive-common
  34. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
  35. Distribution: Vine
  36. Vendor: Project Vine
  37. Packager: munepi
  38. %description
  39. TeXworks is an environment for authoring TeX (LaTeX, ConTeXt, etc) documents,
  40. with a Unicode-based, TeX-aware editor, integrated PDF viewer, and a clean,
  41. simple interface accessible to casual and non-technical users.
  42. You may install the texlive-* packages to make this program useful.
  43. %description -l ja
  44. TeXworks は TeX (LaTeX, ConTeXt, etc) ドキュメント制作のための総合環境です。
  45. ユニコードベースで編集する TeX に特化したエディタに、
  46. PDF プレビュアーが統合されており、不慣れな非技術系のユーザへの
  47. 簡潔で操作しやすいインタフェースを備えています。
  48. TeXworks を利用するためには、TeX 環境が必要です。
  49. %prep
  50. %setup -q
  51. %if %{?_dist_release} == "vl6"
  52. %patch100 -p1 -b .vine
  53. %endif
  54. %if %{?_dist_release} == "vl7"
  55. %patch101 -p1 -b .vine
  56. %endif
  57. ## added some Japanese templates
  58. %if %{templates_japanese}
  59. %__tar xf %{SOURCE50}
  60. %__cp -ra "texworks-templates-japanese-%{templates_japanese_version}/Japanese documents" res/resfiles/templates/ || exit 1
  61. patch -p1 -b -z .vine < texworks-templates-japanese-%{templates_japanese_version}/texworks-0.4.1-templates-japanese.patch || exit 1
  62. %endif
  63. %build
  64. %_qt4_qmake INSTALL_PREFIX=%{_prefix} DOCS_DIR=%{_docdir}/%{name}-%{version}
  65. %__make %{?_smp_mflags}
  66. %install
  67. %__rm -rf %{buildroot}
  68. %__make install INSTALL_ROOT=%{buildroot}
  69. ## support platex/eplatex via dvipdfmx
  70. ## [ ]: TeX distribution and its version, ( ): typesetting engine
  71. ## vl5 [teTeX-3.0]: platex (ptex)
  72. ## vl6 [TeX Live 2009]: platex (ptex), eplatex (eptex)
  73. ## vl7 [TeX Live 2011]: platex (eptex)
  74. %__install -m755 -D %{SOURCE100} %{buildroot}%{_bindir}/pdfplatex
  75. %if %{?_dist_release} == "vl6"
  76. %__install -m755 -D %{SOURCE101} %{buildroot}%{_bindir}/pdfeplatex
  77. %endif
  78. %clean
  79. %__rm -rf %{buildroot}
  80. %post
  81. update-desktop-database &> /dev/null || :
  82. %postun
  83. update-desktop-database &> /dev/null || :
  84. %files
  85. %defattr(-,root,root,-)
  86. %{_docdir}/%{name}-%{version}/
  87. %{_bindir}/%{name}
  88. %{_bindir}/pdfplatex
  89. %if %{?_dist_release} == "vl6"
  90. %{_bindir}/pdfeplatex
  91. %endif
  92. %{_datadir}/applications/%{name}.desktop
  93. %{_datadir}/pixmaps/*
  94. # %dir %{_datadir}/texworks-help
  95. # %{_datadir}/texworks-help/*
  96. %{_mandir}/man1/texworks.1.gz
  97. %changelog
  98. * Sun Dec 4 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.5-1.svn950
  99. - source snapshot r950
  100. - updated pdfplatex.sh
  101. - support SyncTeX
  102. - TeX Live 2011
  103. * Fri Jul 01 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.4.3-1
  104. - new upstream release
  105. - added BuildRequires: texlive-common
  106. - added Requires: texlive-common
  107. * Sat Jun 25 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.4.1-2
  108. - added some Japanese templates
  109. * Sat Jun 18 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.4.1-1
  110. - new upstream release
  111. * Wed Mar 30 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.4.0-1
  112. - new upstream release
  113. * Fri Dec 17 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.3-1.svn724
  114. - source snapshot r724
  115. * Sat Oct 02 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.3-1.svn671
  116. - source snapshot r671
  117. - dropped obsolete/upstreamed patches
  118. - added texworks-snapshot.sh
  119. * Sat Aug 07 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.2.3-1
  120. - initial build
  121. * Sat Apr 24 2010 Robin Lee <robinlee.sysu@gmail.com> - 0.2.3-3
  122. - Move to menu category 'Office'
  123. - License tag revised to 'GPLv2+'
  124. - Initial import to Fedora repositories
  125. * Thu Apr 22 2010 Robin Lee <robinlee.sysu@gmail.com> - 0.2.3-2
  126. - Fix some strange characters in README
  127. - Patch TeXworks.pro to use qmake mechanism to install files and fix DSO linking
  128. problem
  129. * Sun Apr 11 2010 Robin Lee <robinlee.sysu@gmail.com> - 0.2.3-1
  130. - Initial packaging