From 92e8eefbb77c8bac2fb1b0428c5fef35dffc4a2a Mon Sep 17 00:00:00 2001 From: Yann Collette Date: Wed, 3 Jan 2024 08:04:30 +0100 Subject: [PATCH] update to 0.54.1 --- pure-data/dekencpu | 82 +++++++++ pure-data/export.patch | 155 ++++++++++++++++++ pure-data/libpd_example.patch | 104 ++++++++++++ pure-data/libpd_visibility.patch | 20 +++ pure-data/pd-patch-etc-gui-plugins.patch | 12 +- pure-data/pd-patch-fixmanpage.patch | 8 +- .../pd-patch-helpbrowser_puredata-doc.patch | 10 +- pure-data/pd-patch-pd2puredata.patch | 23 ++- pure-data/pd-patch-privacy.patch | 12 +- .../pd-patch-remove_timestamp-macros.patch | 23 ++- pure-data/pd-patch-usrlibpd_path.patch | 18 +- pure-data/puredata.spec | 94 ++++++++--- 12 files changed, 479 insertions(+), 82 deletions(-) create mode 100755 pure-data/dekencpu create mode 100644 pure-data/export.patch create mode 100644 pure-data/libpd_example.patch create mode 100644 pure-data/libpd_visibility.patch diff --git a/pure-data/dekencpu b/pure-data/dekencpu new file mode 100755 index 000000000..eb8601b90 --- /dev/null +++ b/pure-data/dekencpu @@ -0,0 +1,82 @@ +#!/bin/sh + +# get the "Deken CPU" for the given arch. +# This is mainly targetted at Debian's ${DEB_HOST_ARCH} +# it works for many cases of ${DEB_HOST_ARCH_CPU} resp +# ${DEB_HOST_GNU_CPU}, but not for all +# (notably the 'x32' Debian architecture has both +# DEB_HOST_(ARCH|GNU)_CPU set to some x86_64 value) + +archmap_() { +cat </dev/stderr < + + Prints the 'deken CPU' (as used in the filename for Pd-externals) for the given Debian (or GNU) architecture. + +Examples: + $0 \$(dpkg-architecture -qDEB_HOST_ARCH) + $0 \${DEB_HOST_ARCH} +EOF +} + +cpu="$1" + +if [ -z "${cpu}" ]; then + usage + exit 1 +fi + +dekcpu=$(archmap | grep -E "^${cpu}\b" | awk '{print $2}') + +echo "${dekcpu:-$cpu}" + diff --git a/pure-data/export.patch b/pure-data/export.patch new file mode 100644 index 000000000..8f9ee3b70 --- /dev/null +++ b/pure-data/export.patch @@ -0,0 +1,155 @@ +Description: Export required symbols and retract some other symbols +Author: IOhannes m zmölnig +Origin: Debian +Bug: https://github.com/pure-data/pure-data/issues/2122 +Last-Update: 2023-11-02 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +--- puredata.orig/src/m_pd.h ++++ puredata/src/m_pd.h +@@ -12,7 +12,6 @@ + #define PD_MINOR_VERSION 54 + #define PD_BUGFIX_VERSION 1 + #define PD_TEST_VERSION "" +-extern int pd_compatibilitylevel; /* e.g., 43 for pd 0.43 compatibility */ + + /* old name for "MSW" flag -- we have to take it for the sake of many old + "nmakefiles" for externs, which will define NT and not MSW */ +@@ -903,6 +902,7 @@ + + /* get version number at run time */ + EXTERN void sys_getversion(int *major, int *minor, int *bugfix); ++EXTERN int pd_compatibilitylevel; /* e.g., 43 for pd 0.43 compatibility */ + + /* get floatsize at run time */ + EXTERN unsigned int sys_getfloatsize(void); +--- puredata.orig/src/s_stuff.h ++++ puredata/src/s_stuff.h +@@ -38,7 +38,7 @@ + /* s_main.c */ + extern int sys_debuglevel; + extern int sys_verbose; +-extern int sys_noloadbang; ++EXTERN int sys_noloadbang; + EXTERN int sys_havegui(void); + extern const char *sys_guicmd; + +@@ -249,7 +249,7 @@ + /* s_midi.c */ + #define MAXMIDIINDEV 16 /* max. number of input ports */ + #define MAXMIDIOUTDEV 16 /* max. number of output ports */ +-extern int sys_midiapi; ++EXTERN int sys_midiapi; + extern int sys_nmidiin; + extern int sys_nmidiout; + extern int sys_midiindevlist[]; +@@ -346,7 +346,7 @@ + #endif + + void sys_set_priority(int higher); +-extern int sys_hipriority; /* real-time flag, true if priority boosted */ ++EXTERN int sys_hipriority; /* real-time flag, true if priority boosted */ + + /* s_print.c */ + +--- puredata.orig/src/m_imp.h ++++ puredata/src/m_imp.h +@@ -102,6 +102,7 @@ + EXTERN void glob_initfromgui(void *dummy, t_symbol *s, int argc, t_atom *argv); + EXTERN void glob_quit(void *dummy); /* glob_exit(0); */ + EXTERN void glob_exit(void *dummy, t_float status); ++EXTERN void glob_watchdog(t_pd *dummy); + EXTERN void open_via_helppath(const char *name, const char *dir); + + #define __m_imp_h_ +--- puredata.orig/src/d_fft_fftsg.c ++++ puredata/src/d_fft_fftsg.c +@@ -109,12 +109,12 @@ + } + + /* -------- public routines -------- */ +-EXTERN void mayer_fht(t_sample *fz, int n) ++void mayer_fht(t_sample *fz, int n) + { + post("FHT: not yet implemented"); + } + +-EXTERN void mayer_dofft(t_sample *fz1, t_sample *fz2, int n, int sgn) ++void mayer_dofft(t_sample *fz1, t_sample *fz2, int n, int sgn) + { + FFTFLT *buf, *fp3; + int i; +@@ -137,17 +137,17 @@ + } + } + +-EXTERN void mayer_fft(int n, t_sample *fz1, t_sample *fz2) ++void mayer_fft(int n, t_sample *fz1, t_sample *fz2) + { + mayer_dofft(fz1, fz2, n, -1); + } + +-EXTERN void mayer_ifft(int n, t_sample *fz1, t_sample *fz2) ++void mayer_ifft(int n, t_sample *fz1, t_sample *fz2) + { + mayer_dofft(fz1, fz2, n, 1); + } + +-EXTERN void mayer_realfft(int n, t_sample *fz) ++void mayer_realfft(int n, t_sample *fz) + { + FFTFLT *buf, *fp3; + int i, nover2 = n/2; +@@ -165,7 +165,7 @@ + *fp1 = fp3[0], *fp2 = fp3[1]; + } + +-EXTERN void mayer_realifft(int n, t_sample *fz) ++void mayer_realifft(int n, t_sample *fz) + { + FFTFLT *buf, *fp3; + int i, nover2 = n/2; +--- puredata.orig/src/d_fft_fftw.c ++++ puredata/src/d_fft_fftw.c +@@ -167,7 +167,7 @@ + } + + +-EXTERN void mayer_fht(t_sample *fz, int n) ++void mayer_fht(t_sample *fz, int n) + { + post("FHT: not yet implemented"); + } +@@ -189,12 +189,12 @@ + fz1[i] = fz[i*2], fz2[i] = fz[i*2+1]; + } + +-EXTERN void mayer_fft(int n, t_sample *fz1, t_sample *fz2) ++void mayer_fft(int n, t_sample *fz1, t_sample *fz2) + { + mayer_do_cfft(n, fz1, fz2, 1); + } + +-EXTERN void mayer_ifft(int n, t_sample *fz1, t_sample *fz2) ++void mayer_ifft(int n, t_sample *fz1, t_sample *fz2) + { + mayer_do_cfft(n, fz1, fz2, 0); + } +@@ -205,7 +205,7 @@ + but it's probably the mayer_fft that should be corrected... + */ + +-EXTERN void mayer_realfft(int n, t_sample *fz) ++void mayer_realfft(int n, t_sample *fz) + { + int i; + rfftw_info *p = rfftw_getplan(n, 1); +@@ -221,7 +221,7 @@ + fz[i] = -p->out[i]; + } + +-EXTERN void mayer_realifft(int n, t_sample *fz) ++void mayer_realifft(int n, t_sample *fz) + { + int i; + rfftw_info *p = rfftw_getplan(n, 0); diff --git a/pure-data/libpd_example.patch b/pure-data/libpd_example.patch new file mode 100644 index 000000000..1fa48c702 --- /dev/null +++ b/pure-data/libpd_example.patch @@ -0,0 +1,104 @@ +Description: Fix Makefile to allow compiling libpd example +Author: IOhannes m zmönig +Origin: Debian +Forwarded: not-needed +Last-Update: 2023-07-05 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +--- puredata.orig/libpd/test_libpd/Makefile ++++ puredata/libpd/test_libpd/Makefile +@@ -1,84 +1,26 @@ +-# This is a makefile to build "test_libpd". It assumes that libpd is in the +-# source directory "../" and that libpd is already built. +- +-# detect platform +-UNAME = $(shell uname) +-SOLIB_PREFIX = lib +- +-ifeq ($(UNAME), Darwin) # Mac +- SOLIB_EXT = dylib +- STATICLIB_EXT = a +- PLATFORM = mac +-else +- ifeq ($(OS), Windows_NT) # Windows, use Mingw +- SOLIB_PREFIX = +- SOLIB_EXT = dll +- STATICLIB_EXT = lib +- PLATFORM = windows +- else # assume Linux +- SOLIB_EXT = so +- STATICLIB_EXT = a +- PLATFORM = linux +- endif +-endif +- +-PD_DIR = ../.. +-LIBPD_DIR = .. +-LIBPD = $(LIBPD_DIR)/$(SOLIB_PREFIX)pd.$(SOLIB_EXT) +-LIBPD_STATIC = $(LIBPD_DIR)/libpd.$(STATICLIB_EXT) +- ++# This is a makefile to build "test_libpd". + SRC_FILES = test_libpd.c + TARGET = test_libpd + +-CFLAGS = -I$(PD_DIR)/src -O3 +- +-.PHONY: libs clean-libs clean clobber +- + all: $(TARGET) + +-##### libs +- +-$(LIBPD): +- cp $(LIBPD_DIR)/$(LIBPD) . +- +-# on windows, copy libpd and MinGW winpthread dll to here +-ifeq ($(PLATFORM), windows) +- +-LDFLAGS = $(LIBPD) +- +-PTHREAD_DIR = ${MINGW_PREFIX}/bin +-PTHREAD = libwinpthread-1.dll +- +-$(PTHREAD): +- cp $(PTHREAD_DIR)/$(PTHREAD) . +- +-libs: $(LIBPD) $(PTHREAD) +- +-clean-libs: +- rm -f $(LIBPD) $(PTHREAD) +- +-# mac & linux +-else +- +-# force static linking? make STATIC=true + ifeq ($(STATIC), true) +-LDFLAGS = $(LIBPD_STATIC) +-else # copy libpd to here by default +-LDFLAGS = $(LIBPD) +-libs: $(LIBPD) ++LDFLAGS += -l:libpd.a -lm ++else ++LDFLAGS += -lpd + endif + +-clean-libs: +- rm -f $(LIBPD) ++LDFLAGS += -lc + +-endif ++CPPFLAGS += -I/usr/include/pd + + ##### target + +-$(TARGET): ${SRC_FILES:.c=.o} libs +- $(CC) -o $@ ${SRC_FILES:.c=.o} $(LDFLAGS) ++$(TARGET): ${SRC_FILES:.c=.o} ++ $(CC) -o $@ ${SRC_FILES:.c=.o} $(LDFLAGS) $(LIBS) + + ##### clean + +-clean: clean-libs ++.PHONY: clean all ++clean: + rm -f $(TARGET) *.o diff --git a/pure-data/libpd_visibility.patch b/pure-data/libpd_visibility.patch new file mode 100644 index 000000000..bf3908169 --- /dev/null +++ b/pure-data/libpd_visibility.patch @@ -0,0 +1,20 @@ +Description: reduce visibility of symbols inlibpd + by compiling the binary with visbility=hidden +Author: IOhannes m zmölnig +Bug: https://github.com/pure-data/pure-data/issues/569 +Last-Update: 2021-12-21 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +--- puredata.orig/src/Makefile.am ++++ puredata/src/Makefile.am +@@ -28,6 +28,10 @@ + + libpdbin_PROGRAMS = + ++# reduce visibility of libpd symbols ++libpd_la_CPPFLAGS += -DEXTERN='__attribute__ ((visibility("default"))) extern' ++libpd_la_CFLAGS += -fvisibility=hidden ++ + # there are pd_* and pd_*_core variables as we need different flags on Windows + # for the DLL and the EXE, other OSes simply set pd_* = $(pd_*_core) later + # also, the "_core" suffix is used as this keeps automake from thinking these diff --git a/pure-data/pd-patch-etc-gui-plugins.patch b/pure-data/pd-patch-etc-gui-plugins.patch index 74a4fbc0e..06ff96c4c 100644 --- a/pure-data/pd-patch-etc-gui-plugins.patch +++ b/pure-data/pd-patch-etc-gui-plugins.patch @@ -3,20 +3,18 @@ Date: Tue, 29 Jan 2019 11:31:36 +0100 Subject: search for GUI plugins in /etc/pd/plugins-enabled Origin: Debian -Last-Update: 2016-02-17 this gives us a standard path where the user can symlink-enable their system-wide GUI plugins. -Last-Update: 2016-02-17 +Last-Update: 2023-11-02 +Forwarded: not-needed --- tcl/pd-gui.tcl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -diff --git a/tcl/pd-gui.tcl b/tcl/pd-gui.tcl -index 6408a0b..fa221d7 100755 ---- a/tcl/pd-gui.tcl -+++ b/tcl/pd-gui.tcl -@@ -803,7 +803,7 @@ proc load_startup_plugins {} { +--- puredata.orig/tcl/pd-gui.tcl ++++ puredata/tcl/pd-gui.tcl +@@ -775,7 +775,7 @@ } # load other installed plugins diff --git a/pure-data/pd-patch-fixmanpage.patch b/pure-data/pd-patch-fixmanpage.patch index e45eabc16..bea1eb0be 100644 --- a/pure-data/pd-patch-fixmanpage.patch +++ b/pure-data/pd-patch-fixmanpage.patch @@ -7,10 +7,8 @@ Forwarded: not-needed man/pd.1 | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) -diff --git a/man/pd.1 b/man/pd.1 -index f469dec..579ac38 100644 ---- a/man/pd.1 -+++ b/man/pd.1 +--- puredata.orig/man/pd.1 ++++ puredata/man/pd.1 @@ -1,6 +1,12 @@ .TH pd 1 "1996 Mar 20" GNU .SH NAME @@ -24,7 +22,7 @@ index f469dec..579ac38 100644 .SH DESCRIPTION Pd is a graphical programming environment for real-time audio synthesis and related applications. It sports a rich set of real-time control -@@ -9,17 +15,17 @@ and I/O features. +@@ -9,17 +15,17 @@ To get a list of allowable arguments to pd, type .IP .B pd -help diff --git a/pure-data/pd-patch-helpbrowser_puredata-doc.patch b/pure-data/pd-patch-helpbrowser_puredata-doc.patch index 678fc5fa8..b0712e9dd 100644 --- a/pure-data/pd-patch-helpbrowser_puredata-doc.patch +++ b/pure-data/pd-patch-helpbrowser_puredata-doc.patch @@ -11,11 +11,9 @@ Forwarded: not-needed tcl/pd_menucommands.tcl | 14 ++++++++++++++ 1 file changed, 14 insertions(+) -diff --git a/tcl/pd_menucommands.tcl b/tcl/pd_menucommands.tcl -index b4a0ae6..cc84ed6 100644 ---- a/tcl/pd_menucommands.tcl -+++ b/tcl/pd_menucommands.tcl -@@ -228,10 +228,23 @@ proc ::pd_menucommands::set_filenewdir {mytoplevel} { +--- puredata.orig/tcl/pd_menucommands.tcl ++++ puredata/tcl/pd_menucommands.tcl +@@ -232,10 +232,23 @@ } } @@ -39,7 +37,7 @@ index b4a0ae6..cc84ed6 100644 if {![file exists $filename]} { ::pdwindow::error [format [_ "ignoring '%s': doesn't exist"] $filename] ::pdwindow::error "\n" -@@ -291,6 +304,7 @@ proc ::pd_menucommands::menu_doc_open {dir basename} { +@@ -295,6 +308,7 @@ # open HTML docs from the menu using the OS-default HTML viewer proc ::pd_menucommands::menu_openfile {filename} { diff --git a/pure-data/pd-patch-pd2puredata.patch b/pure-data/pd-patch-pd2puredata.patch index bad36f346..54c8410a6 100644 --- a/pure-data/pd-patch-pd2puredata.patch +++ b/pure-data/pd-patch-pd2puredata.patch @@ -9,30 +9,29 @@ to be installed simultaneously, puredata will install itself as This patch ensures that the "puredata" namespace is used throughout (both installed binary and library-paths) + +Last-Update: 2023-11-02 +Forwarded: not-needed --- configure.ac | 2 +- src/s_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -diff --git a/configure.ac b/configure.ac -index 93232a8..15ff0f8 100644 ---- a/configure.ac -+++ b/configure.ac +--- puredata.orig/configure.ac ++++ puredata/configure.ac @@ -2,7 +2,7 @@ ##### Prelude ##### AC_PREREQ(2.59) --AC_INIT([pd], [0.53.1]) -+AC_INIT([puredata], [0.53.1]) +-AC_INIT([pd], [0.54.1]) ++AC_INIT([puredata], [0.54.1]) AC_CONFIG_SRCDIR(src/m_pd.c) AC_CONFIG_AUX_DIR([m4/config]) AC_CONFIG_MACRO_DIR([m4/generated]) -diff --git a/src/s_main.c b/src/s_main.c -index c30fef5..b9c527a 100644 ---- a/src/s_main.c -+++ b/src/s_main.c -@@ -627,7 +627,7 @@ void sys_findprogdir(const char *progname) - #else +--- puredata.orig/src/s_main.c ++++ puredata/src/s_main.c +@@ -718,7 +718,7 @@ + strncpy(sbuf, sbuf2, MAXPDSTRING-30); sbuf[MAXPDSTRING-30] = 0; - strcat(sbuf, "/lib/pd"); diff --git a/pure-data/pd-patch-privacy.patch b/pure-data/pd-patch-privacy.patch index 1d7bac4f1..363a000be 100644 --- a/pure-data/pd-patch-privacy.patch +++ b/pure-data/pd-patch-privacy.patch @@ -13,10 +13,8 @@ Last-Update: 2020-02-24 doc/8.topics/slop-tilde.htm | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -diff --git a/doc/8.topics/compander-limiter.htm b/doc/8.topics/compander-limiter.htm -index d50f36e..6d25a2f 100644 ---- a/doc/8.topics/compander-limiter.htm -+++ b/doc/8.topics/compander-limiter.htm +--- puredata.orig/doc/8.topics/compander-limiter.htm ++++ puredata/doc/8.topics/compander-limiter.htm @@ -12,7 +12,7 @@ div.column{display: inline-block; vertical-align: top; width: 50%;} @@ -26,10 +24,8 @@ index d50f36e..6d25a2f 100644 -diff --git a/doc/8.topics/slop-tilde.htm b/doc/8.topics/slop-tilde.htm -index db9ba91..26c18aa 100644 ---- a/doc/8.topics/slop-tilde.htm -+++ b/doc/8.topics/slop-tilde.htm +--- puredata.orig/doc/8.topics/slop-tilde.htm ++++ puredata/doc/8.topics/slop-tilde.htm @@ -12,7 +12,7 @@ div.column{display: inline-block; vertical-align: top; width: 50%;} diff --git a/pure-data/pd-patch-remove_timestamp-macros.patch b/pure-data/pd-patch-remove_timestamp-macros.patch index 3f398945f..1977d4f60 100644 --- a/pure-data/pd-patch-remove_timestamp-macros.patch +++ b/pure-data/pd-patch-remove_timestamp-macros.patch @@ -2,22 +2,21 @@ From: =?utf-8?q?IOhannes_m_zm=C3=B6lnig?= Date: Tue, 29 Jan 2019 11:31:36 +0100 Subject: remove C-macros for timestamps -Last-Update: 2015-05-20 For reproducible builds, we don't want timestamps in the builds. Instead we should set the version to be displayed to the Debian package version (use PD_TEST_VERSION) for this. -Last-Update: 2015-05-20 + +Last-Update: 2023-11-02 +Forwarded: not-needed --- src/Makefile.am | 4 ++++ src/s_main.c | 12 ++++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) -diff --git a/src/Makefile.am b/src/Makefile.am -index 45c5d8b..fef341d 100644 ---- a/src/Makefile.am -+++ b/src/Makefile.am -@@ -11,6 +11,10 @@ AM_CPPFLAGS = @PD_CPPFLAGS@ +--- puredata.orig/src/Makefile.am ++++ puredata/src/Makefile.am +@@ -11,6 +11,10 @@ AM_CFLAGS = @PD_CFLAGS@ AM_LDFLAGS = @PD_LDFLAGS@ @@ -28,11 +27,9 @@ index 45c5d8b..fef341d 100644 pd_CFLAGS = -DPD -DPD_INTERNAL -DINSTALL_PREFIX=\"$(prefix)\" @PD_CFLAGS@ pd_LDFLAGS = @PD_LDFLAGS@ pd_LDADD = -diff --git a/src/s_main.c b/src/s_main.c -index b9c527a..56fd633 100644 ---- a/src/s_main.c -+++ b/src/s_main.c -@@ -32,8 +32,12 @@ char *pd_version = "Pd-" stringify(PD_MAJOR_VERSION) "." \ +--- puredata.orig/src/s_main.c ++++ puredata/src/s_main.c +@@ -33,8 +33,12 @@ stringify(PD_MINOR_VERSION) "." stringify(PD_BUGFIX_VERSION) "\ (" stringify(PD_TEST_VERSION) ")"; @@ -47,7 +44,7 @@ index b9c527a..56fd633 100644 void pd_init(void); int sys_argparse(int argc, const char **argv); -@@ -360,8 +364,8 @@ int sys_main(int argc, const char **argv) +@@ -434,8 +438,8 @@ sys_loadpreferences(prefsfile, 1); /* args to override prefs */ if (sys_argparse(argc-1, argv+1)) /* parse cmd line args */ return (1); diff --git a/pure-data/pd-patch-usrlibpd_path.patch b/pure-data/pd-patch-usrlibpd_path.patch index 7d169addc..f51d41732 100644 --- a/pure-data/pd-patch-usrlibpd_path.patch +++ b/pure-data/pd-patch-usrlibpd_path.patch @@ -5,22 +5,20 @@ Subject: search /usr/lib/pd/extra/ for externals since we install into /usr/lib/puredata/extra, the ordinary install path for externals (/usr/lib/pd/extra) won't get searched automatically; so we need to add it manually + +Last-Update: 2023-11-02 +Forwarded: not-needed + --- - src/s_path.c | 4 ++++ - 1 file changed, 4 insertions(+) +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ -diff --git a/src/s_path.c b/src/s_path.c -index 2d6f456..db54b67 100644 ---- a/src/s_path.c -+++ b/src/s_path.c -@@ -263,6 +263,10 @@ void sys_setextrapath(const char *p) +--- puredata.orig/src/s_path.c ++++ puredata/src/s_path.c +@@ -253,6 +253,7 @@ #endif /* add built-in "extra" path last so its checked last */ STUFF->st_staticpath = namelist_append(STUFF->st_staticpath, p, 0); -+ /* DEBIAN: add common path for all pd-flavours very last, so puredata -+ * specific externals get higher priority */ + STUFF->st_staticpath = namelist_append(STUFF->st_staticpath, "/usr/lib/pd/extra", 0); -+ } /* try to open a file in the directory "dir", named "name""ext", diff --git a/pure-data/puredata.spec b/pure-data/puredata.spec index e2713cd16..7e1e0e40e 100644 --- a/pure-data/puredata.spec +++ b/pure-data/puredata.spec @@ -2,8 +2,8 @@ # Pure Data vanilla build # -%define pdver 0.53-1 -%define pkgver 0.53.1 +%define pdver 0.54-1 +%define pkgver 0.54.1 Summary: Pure Data Name: puredata @@ -28,23 +28,30 @@ Source15: pd-gui-plugin.1 Source16: pd-README # mime stuff Source17: puredata-gui.sharedmimeinfo +# deken_cpi +Source18: dekencpu # add relevant debian patches -Patch1: pd-patch-pd2puredata.patch -Patch2: pd-patch-usrlib64pd_path.patch -Patch3: pd-patch-usrlibpd_path.patch -Patch4: pd-patch-helpbrowser_puredata-doc.patch -Patch5: pd-patch-etc-gui-plugins.patch -Patch6: pd-patch-fixmanpage.patch -Patch7: pd-patch-privacy.patch - -BuildRequires: gcc gcc-c++ +Patch1: pd-patch-pd2puredata.patch +Patch2: pd-patch-usrlib64pd_path.patch +Patch3: pd-patch-usrlibpd_path.patch +Patch4: pd-patch-helpbrowser_puredata-doc.patch +Patch5: pd-patch-etc-gui-plugins.patch +Patch6: pd-patch-fixmanpage.patch +Patch7: pd-patch-privacy.patch +Patch8: export.patch +Patch9: libpd_example.patch +Patch10: libpd_visibility.patch + +BuildRequires: gcc +BuildRequires: gcc-c++ BuildRequires: autoconf BuildRequires: automake BuildRequires: libtool BuildRequires: alsa-lib-devel BuildRequires: jack-audio-connection-kit-devel BuildRequires: portaudio-devel +BuildRequires: portmidi-devel BuildRequires: gettext-devel BuildRequires: desktop-file-utils @@ -56,6 +63,7 @@ Requires: puredata-gui Requires: puredata-utils # for the gui plugin Requires: python3 +Requires: dejavu-sans-mono-fonts %description Pure Data (also known as Pd) is a real-time graphical programming @@ -84,6 +92,13 @@ environment for audio and graphics processing. This package provides the header-files for compiling externals (plugins) for puredata. +%package static +Summary: Pure Data static library +Requires: puredata-devel + +%description static +Pure Data static lib (libpd static). + %package doc Summary: Pure Data documentation Requires: puredata-core @@ -134,22 +149,28 @@ and pdreceive, for sending and receiving FUDI over the net. %setup -n pd-%{pdver} # pd-patch-pd2puredata.patch -%patch1 -p1 +%patch 1 -p1 %ifarch x86_64 amd64 # pd-patch-usrlib64pd_path.patch -%patch2 -p1 +%patch 2 -p1 %else # pd-patch-usrlibpd_path.patch -%patch3 -p1 +%patch 3 -p1 %endif # pd-patch-helpbrowser_puredata-doc.patch -%patch4 -p1 +%patch 4 -p1 # pd-patch-etc-gui-plugins.patch -%patch5 -p1 +%patch 5 -p1 # pd-patch-fixmanpage.patch -%patch6 -p1 +%patch 6 -p1 # pd-patch-privacy.patch -%patch7 -p1 +%patch 7 -p1 +# export.patch +%patch 8 -p1 +# libpd_example.patch +%patch 9 -p1 +# libpd_visibility.patch +%patch 10 -p1 # fix hardwired lib dir in startup file (why the heck is this hardwired?) sed -i -e "s|\"/lib|\"/%{_lib}|g" src/s_main.c @@ -160,10 +181,20 @@ sed -i -e "s|/usr/local/lib|%{_libdir}|g" src/s_path.c %set_build_flags +DEKEN_CPU=`%{SOURCE18} uname -m` + # now do the build, use "puredata" as the program name ./autogen.sh -%configure --enable-alsa --enable-jack --program-transform-name 's/pd$$/puredata/' - +%configure --enable-alsa \ + --enable-jack \ + --without-local-portaudio \ + --without-local-portmidi \ + --program-transform-name 's/pd$$/puredata/' \ + --enable-libpd \ + --enable-libpd-utils \ + --with-floatsize=64 \ + --with-deken-cpu=$(DEKEN_CPU) \ + --with-external-extension=linux-$(DEKEN_CPU)-64.so %make_build %install @@ -173,7 +204,6 @@ sed -i -e "s|/usr/local/lib|%{_libdir}|g" src/s_path.c # add additional stuff needed by the gui package # create plugins enabled directory mkdir -p %{buildroot}%{_sysconfdir}/pd/plugins-enabled -desktop-file-validate %{buildroot}%{_datadir}/applications/org.puredata.pd-gui.desktop # pd-gui script and plugin install -m 755 %{SOURCE12} %{buildroot}%{_bindir}/pd-gui @@ -191,6 +221,9 @@ install -m 644 doc/1.manual/1.introduction.txt %{buildroot}%{_datadir}/puredata- # mime stuff mkdir -p %{buildroot}%{_datadir}/mime/packages/ install -m 644 %{SOURCE17} %{buildroot}%{_datadir}/mime/packages/puredata.xml +# deken cpi +mkdir -p %{buildroot}%{_datadir}/puredata/fedora/ +install -m 755 %{SOURCE18} %{buildroot}%{_datadir}/puredata/fedora/ # hardlink pd-* binaries rm -f %{buildroot}%{_bindir}/pd @@ -205,6 +238,16 @@ ln -s %{_libdir}/puredata/bin/pd-watchdog %{buildroot}%{_bindir}/pd-watchdog rm -f %{buildroot}%{_libdir}/puredata/doc/Makefile.am +# Remove installed fonts +rm -rf %{buildroot}%{_datadir}/puredata/font + +# Already installed +rm -f %{buildroot}%{_datadir}/puredata/LICENSE.txt +rm -f %{buildroot}%{_datadir}/puredata/README.txt + +%check +desktop-file-validate %{buildroot}%{_datadir}/applications/org.puredata.pd-gui.desktop + %files %doc README.txt INSTALL.txt %license LICENSE.txt @@ -218,6 +261,7 @@ rm -f %{buildroot}%{_libdir}/puredata/doc/Makefile.am %{_libdir}/puredata/doc/5.reference %{_libdir}/puredata/doc/7.stuff %{_mandir}/man1/pd.1* +%{_libdir}/libpd.so.* %files doc %{_libdir}/puredata/doc/1.manual/ @@ -232,6 +276,10 @@ rm -f %{buildroot}%{_libdir}/puredata/doc/Makefile.am %{_includedir}/m_pd.h %{_includedir}/puredata/ %{_libdir}/pkgconfig/pd.pc +%{_libdir}/libpd.so + +%files static +%{_libdir}/libpd.a %files extra %{_libdir}/puredata/extra/ @@ -251,6 +299,7 @@ rm -f %{buildroot}%{_libdir}/puredata/doc/Makefile.am %{_datadir}/puredata-gui %{_datadir}/mime/packages/puredata.xml %{_metainfodir}/org.puredata.pd-gui.metainfo.xml +%{_datadir}/puredata/fedora/* %files utils %{_bindir}/pdreceive @@ -259,6 +308,9 @@ rm -f %{buildroot}%{_libdir}/puredata/doc/Makefile.am %{_mandir}/man1/pdsend.1.gz %changelog +* Wed Jan 03 2024 Yann Collette - 0.54.1-3 +- update to 0.54.1-3 + * Mon Jan 02 2023 Yann Collette - 0.53.1-3 - update to 0.53.1-3 - fix package