From 753b67c88d7feb166cf99243118943c09beba62a Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Mon, 30 Oct 2023 21:40:57 -0400 Subject: [PATCH 1/1] src: unbundle gl2ps Updated patch based on the one by infinity0@debian.org. Ours links only libxcas (and not libgiac) to gl2ps. --- configure.ac | 4 ++++ src/Graph3d.cc | 2 +- src/Makefile.am | 6 +++--- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac index d66c3e1..2acbf30 100644 --- a/configure.ac +++ b/configure.ac @@ -469,6 +469,10 @@ dnl AC_CHECK_LIB(GLU, main) AC_CHECK_LIB(fltk_images, main) FLTK_LIBS="$LIBS $X_LIBS" AC_SUBST(FLTK_LIBS) + + # GL2PS is only used by xcas (the GUI) + GL2PS_LIBS="-lgl2ps" + AC_SUBST(GL2PS_LIBS) cd src && ln -sf ../fltk-1.3.8 && cd .. fi fi diff --git a/src/Graph3d.cc b/src/Graph3d.cc index e653cc4..a6c3468 100644 --- a/src/Graph3d.cc +++ b/src/Graph3d.cc @@ -23,7 +23,7 @@ #define __CARBONSOUND__ #ifdef HAVE_LIBFLTK #ifdef HAVE_LIBFLTK_GL -#include "gl2ps.h" +#include #else void gl_font(int fontid, int size){} void gl_draw(const char *){} diff --git a/src/Makefile.am b/src/Makefile.am index 7c90381..2ae8003 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -35,17 +35,17 @@ libbf.h list.h cutils.h qjsgiac.h \ quickjs.h js.h quickjs-atom.h quickjs-libc.h quickjs-opcode.h bf2gmp.h noinst_LTLIBRARIES = libxcas.la -libxcas_la_LIBADD = libgiac.la $(FLTK_LIBS) +libxcas_la_LIBADD = libgiac.la $(FLTK_LIBS) $(GL2PS_LIBS) libxcas_la_SOURCES = History.cc Input.cc Xcas1.cc Equation.cc Print.cc \ Tableur.cc Editeur.cc Graph.cc Graph3d.cc Help1.cc Cfg.cc \ Flv_CStyle.cc \ Flve_Check_Button.cc Flve_Input.cc Flv_Style.cc Flv_Data_Source.cc \ - Flve_Combo.cc Flv_List.cc Flv_Table.cc gl2ps.c \ + Flve_Combo.cc Flv_List.cc Flv_Table.cc \ History.h Input.h Xcas1.h Equation.h Print.h Tableur.h \ Editeur.h Graph.h Graph3d.h Help1.h Cfg.h Python.cc Python.h \ Flv_CStyle.H Flve_Check_Button.H Flve_Input.H Flv_Style.H \ - Flv_Data_Source.H Flve_Combo.H Flv_List.H Flv_Table.H gl2ps.h + Flv_Data_Source.H Flve_Combo.H Flv_List.H Flv_Table.H ##libjavagiac_la_LIBADD = libgiac.la -- 2.41.0