diff --git a/.gitignore b/.gitignore index 7c894ce..52ed481 100644 --- a/.gitignore +++ b/.gitignore @@ -18,3 +18,7 @@ xiphos-3.1.3.tar.gz /4.0.6.tar.gz /4.0.7.tar.gz /4.1.0.tar.gz +/xiphos-4.2.1.tar.xz +/xiphos-4.3.1.tar.xz +/xiphos-4.3.2.tar.xz +/xiphos-4.4.0.tar.xz diff --git a/cmake.patch b/cmake.patch deleted file mode 100644 index ca63bad..0000000 --- a/cmake.patch +++ /dev/null @@ -1,124109 +0,0 @@ -diff --git a/.bzrignore b/.bzrignore -index 1425fec6..67dc79cd 100644 ---- a/.bzrignore -+++ b/.bzrignore -@@ -34,12 +34,12 @@ po/.intltool-merge-cache - po/Makefile.in.in - po/POTFILES - po/stamp-it --src/gnome2/.libs/ --src/gnome2/ipc-interface.h --src/gnome2/locale_set.c --src/gnome2/marshal.c --src/gnome2/marshal.h --src/gnome2/xiphos -+src/gtk/.libs/ -+src/gtk/ipc-interface.h -+src/gtk/locale_set.c -+src/gtk/marshal.c -+src/gtk/marshal.h -+src/gtk/xiphos - .waf* - build - .lock-wscript -diff --git a/CMakeLists.txt b/CMakeLists.txt -new file mode 100644 -index 00000000..02073f1d ---- /dev/null -+++ b/CMakeLists.txt -@@ -0,0 +1,109 @@ -+# Xiphos build script -+# -+# Copyright (C) 2018 Xiphos Development Team -+# -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 2 of the License, or -+# (at your option) any later version. -+# -+# This program is distributed in the hope that it will be useful, -+# but WITHOUT ANY WARRANTY; without even the implied warranty of -+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+# GNU Library General Public License for more details. -+# -+# You should have received a copy of the GNU General Public License -+# along with this program; if not, write to the Free Software -+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. -+# -+ -+# the oldest stable cmake version we support -+cmake_minimum_required (VERSION 3.6 FATAL_ERROR) -+cmake_policy(VERSION 3.6) -+ -+ -+### set project name and version HERE ### -+project (xiphos -+ VERSION "4.1.0" -+ LANGUAGES C CXX) -+ -+ -+# set commonly used Xiphos variables: -+# Xiphos website -+set (XIPHOS_WEBSITE "http://xiphos.org") -+ -+# Xiphos issues report website -+set (XIPHOS_BUG_REPORT "https://github.com/crosswire/xiphos/issues") -+ -+# Xiphos release date, (read from 'ChangeLog') -+# read last entry in ChangeLog -+file(STRINGS ${PROJECT_SOURCE_DIR}/ChangeLog -+ ChangeLog_lastentry REGEX "^20[0-9][0-9]-[0-9][0-9]" LIMIT_COUNT 1) -+# get year -+string(SUBSTRING ${ChangeLog_lastentry} 0 4 ChangeLog_year) -+# get month's number -+string(SUBSTRING ${ChangeLog_lastentry} 5 2 ChangeLog_month) -+# transform month's number into month's name -+list(APPEND month_names "XXX;Jan;Feb;Mar;Apr;May;Jun;Jul;Aug;Sep;Oct;Nov;Dec") -+list(GET month_names ${ChangeLog_month} ChangeLog_month) -+# generate release date string -+string(CONFIGURE "@ChangeLog_month@ @ChangeLog_year@" XIPHOS_RELEASE_DATE) -+ -+ -+# make sure it's an out-of-stream build -+file(TO_CMAKE_PATH "${PROJECT_BINARY_DIR}/CMakeLists.txt" LOC_PATH) -+if(EXISTS "${LOC_PATH}") -+ message(FATAL_ERROR "You cannot build in the source directory (or any directory with a CMakeLists.txt file). Please make an out-of-stream build subdirectory.") -+endif() -+ -+ -+# tell cmake where its modules can be found in our project directory -+list (APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) -+list (APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules) -+ -+# set install directory variables as defined by the GNU Coding Standards. -+# e.g. CMAKE_INSTALL_DATAROOTDIR; CMAKE_INSTALL_FULL_BINDIR; -+# CMAKE_INSTALL_FULL_DOCDIR... -+include (GNUInstallDirs) -+ -+# set CMAKE options that the user can optionally select ON or OFF. -+include (XiphosOptions) -+ -+# find needed tools for building Xiphos -+include (XiphosBuildTools) -+ -+# find dependencies -+include (XiphosDependencies) -+ -+# set flags -+include (XiphosFlags) -+ -+# create config.h -+include (XiphosConfig_h) -+ -+# build xiphos -+add_subdirectory(win32) -+add_subdirectory(src/backend) -+add_subdirectory(src/editor) -+add_subdirectory(src/main) -+add_subdirectory(src/webkit) -+add_subdirectory(src/xiphos_html) -+add_subdirectory(src/gtk) -+ -+# build xiphos-nav -+add_subdirectory(src/examples) -+ -+# build other stuff -+add_subdirectory(pixmaps) -+add_subdirectory(ui) -+add_subdirectory(po) -+add_subdirectory(desktop) -+add_subdirectory(doc) -+add_subdirectory(mhelp) -+ -+# create packages -+add_subdirectory(cpack) -+ -+# report -+include (XiphosReport) -+# End -diff --git a/INSTALL-cmake.md b/INSTALL-cmake.md -new file mode 100644 -index 00000000..d0f601d9 ---- /dev/null -+++ b/INSTALL-cmake.md -@@ -0,0 +1,232 @@ -+Installation instructions -+========================== -+ -+On Linux install Xiphos through you package manager, for example on Fedora: -+ -+ $ sudo dnf install xiphos-gtk3 -+ -+Or on Debian, Ubuntu, or Linux Mint: -+ -+ $ sudo apt-get update -+ $ sudo apt-get install xiphos -+ -+If you use Windows download the .exe file from: http://xiphos.org/download/ -+ -+Compile Xiphos from source -+========================== -+ -+Get source -+---------- -+ -+To compile Xiphos from source you will need to get a checkout of Xiphos from -+GitHub. To do so, do: -+ -+ $ git clone https://github.com/crosswire/xiphos.git -+ -+Dependencies -+------------ -+ -+Before building Xiphos with CMake, please ensure that you have the platform -+specific dependencies installed: -+ -+ gcc GCC, the GNU Compiler Collection -+ intltool Set of tools to centralize translation -+ libxml2 XML C parser and toolkit -+ libgsf The G Structured File Library -+ gconfmm C++ wrappers for GConf -+ libuuid universally unique identifier library -+ sword >= 1.8.0 CrossWire Bible Society's Bible software -+ biblesync Protocol to support Bible software shared co-navigation -+ Gtk+-2.0 or GTK+-3.0 The GIMP Toolkit -+ WebKit1 or Webkit2 Port to Gtk+ of the WebKit rendering engine -+ -+Optional Dependencies: -+ -+ gtkhtml Lightweight HTML rendering/editing engine -+ dbus-glib API for use of D-Bus from GLib applications -+ -+Recommended tools: -+ -+ intltool An internationalization tool -+ appstream-util Utility to validate AppStream metadata -+ desktop-file-validate Validates a desktop file -+ itstool Translates XML documents with PO files -+ xmllint Validates an XML file against an XSD schema -+ yelp-build Creates HTML, EPUB, and other files from help files -+ chmcmd Creates a Compressed HTML help file (chm) -+ -+For *Fedora*, you need to make sure you have these packages installed: -+ -+ $ sudo dnf install cmake gcc-c++ intltool gtk3-devel dbus-glib-devel gtkhtml3-devel webkitgtk4-devel libxml2-devel libgsf-devel gconfmm26-devel sword-devel libuuid-devel biblesync-devel intltool libappstream-glib-devel desktop-file-utils itstool yelp-tools fpc -+ -+Or for *Ubuntu*, both GTK3 and GTK2 versions, install: -+ -+ $ sudo apt-get install cmake cpp intltool libdbus-glib-1-dev libwebkitgtk-3.0-dev libxml2-dev libgsf-1-dev libgconfmm-2.6-dev libsword-dev uuid-dev libwebkitgtk-dev libglade2-dev intltool appstream-util desktop-file-utils itstool libxml2-utils yelp-tools fp-utils uuid-runtime -+ -+ -+Building Xiphos with CMake -+-------------------------- -+ -+CMake is a cross-platform tool for generating makefiles (as well as project files -+used by IDEs). -+ -+The current version of the buildsystem is capable of building and packaging -+Xiphos for the following platforms: -+ -+- Linux (GNU Makefiles, Ninja) -+ -+Should work, but untested: -+- FreeBSD (GNU Makefiles) -+ -+Work in progress: -+- Linux Cross compiling for Windows (GNU Makefiles, Ninja) -+ -+While the legacy build systems typically used in-source builds, it's highly -+recommended to use *out-of-source* builds with CMake. -+ -+The necessary runtime dependencies such as generated source files, static -+libraries, translated files are copied over to the build directory automatically -+during the build process. -+ -+ -+Commands for building Xiphos -+---------------------------- -+ -+This section lists the necessary commands for building Xiphos with CMake. -+CMake supports different generators (like GNU/NMake Makefiles or Ninja). -+ -+The cmake command-line tool --help output lists available generators on the -+current platform. Use its -G option to specify the generator for a new build tree. -+ -+Set-up the out-of-source build. Using a build tree that is separate from the -+source tree will prevent CMake from generating any files in the source tree. -+Create a completely separate directory: -+ -+ -+ mkdir xiphos-build && cd xiphos-build -+ -+ -+All examples below are for out-of-source builds with Xiphos checked out to -+``: -+ -+### Linux build with Ninja -+ -+ -+ cmake -G Ninja -+ cmake --build . -- -v # or: ninja -v all -+ -+`CMAKE_BUILD_TYPE` defaults to `Release` (or to `Debug` if a .git dir exists) -+ -+### Linux build with Makefiles -+ -+ cmake -+ cmake --build . -- VERBOSE=1 -j$(nproc) # or: make VERBOSE=1 -j$(nproc) -+ -+ -+Build Options -+------------- -+ -+Xiphos supports a number of build options that can enable or disable certain -+functionality. These options must be set when running CMake with -+`-DENABLE_