From 69f1ceff8a2b12272c6c67e1af7b62eb7152ac40 Mon Sep 17 00:00:00 2001 From: mhc2910463910 <2910463910@qq.com> Date: Fri, 10 May 2024 12:01:01 +0800 Subject: [PATCH] build: add app xchm Unix CHM viewer Log: add app xchm --- io.github.xchm/linglong.yaml | 38 ++++++++++++++++++++++++ io.github.xchm/patches/fix-install.patch | 21 +++++++++++++ 2 files changed, 59 insertions(+) create mode 100644 io.github.xchm/linglong.yaml create mode 100644 io.github.xchm/patches/fix-install.patch diff --git a/io.github.xchm/linglong.yaml b/io.github.xchm/linglong.yaml new file mode 100644 index 000000000..bd6ef20ff --- /dev/null +++ b/io.github.xchm/linglong.yaml @@ -0,0 +1,38 @@ +package: + id: io.github.xchm + name: xchm + version: 1.37 + kind: app + description: | + UNIX CHM viewer. + +runtime: + id: org.deepin.Runtime + version: 23.0.0 + +depends: + - id: automake + version: 1.16.5 + - id: autoconf + version: 2.4.7 + - id: libtool + version: 2.4.6 + - id: wxWidgets + version: 3.2.3 +source: + kind: git + url: "https://github.com/rzvncj/xCHM.git" + commit: c63faadb67fd25e7f34fb1c78767f14938936abd + patch: patches/fix-install.patch + +build: + kind: manual + manual: + configure: | + ./bootstrap + CFLAGS="-Wall -O2" LDFLAGS="-L${PREFIX}/lib" CXXFLAGS="-L${PREFIX}/include" ./configure --prefix=${PREFIX} --enable-builtin-chmlib --disable-dependency-tracking + build: | + make ${jobs} + install: | + make ${jobs} DESTDIR=${dest_dir} install + diff --git a/io.github.xchm/patches/fix-install.patch b/io.github.xchm/patches/fix-install.patch new file mode 100644 index 000000000..558f25028 --- /dev/null +++ b/io.github.xchm/patches/fix-install.patch @@ -0,0 +1,21 @@ +diff --git a/Makefile.am b/Makefile.am +index 4c8c43f..6c02512 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -14,5 +14,16 @@ macbundle: all + clean-local: + -rm -rf $(top_srcdir)/xCHM.app + ++ ++install-data-local: ++ $(mkinstalldirs) $(DESTDIR)$(prefix)/bin ++ $(INSTALL_PROGRAM) $(top_builddir)/src/xchm $(DESTDIR)$(prefix)/bin ++ ++ $(mkinstalldirs) $(DESTDIR)$(prefix)/share/applications ++ cp $(top_srcdir)/data/xchm.desktop $(DESTDIR)$(prefix)/share/applications/xchm.desktop ++ ++ $(mkinstalldirs) $(DESTDIR)$(prefix)/share/icons ++ cp $(top_srcdir)/art/128x128/apps/xchm.png $(DESTDIR)$(prefix)/share/icons/xchm.png ++ + .PHONY: bundle +