aboutsummaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
Diffstat (limited to 'packages')
-rw-r--r--packages/Makefile58
-rw-r--r--packages/Makefile.buildlayout4
-rw-r--r--packages/TODO26
-rw-r--r--packages/darwin_app/Info.plist.in5
-rw-r--r--packages/darwin_app/Makefile56
-rw-r--r--packages/darwin_app/TODO9
-rw-r--r--packages/patches/darwin/darwin_dlopen.patch65
-rw-r--r--packages/patches/extended-help-menu.patch298
-rw-r--r--packages/win32_inno/TODO2
9 files changed, 369 insertions, 154 deletions
diff --git a/packages/Makefile b/packages/Makefile
index 5316b2e7..ca503f54 100644
--- a/packages/Makefile
+++ b/packages/Makefile
@@ -130,6 +130,7 @@ flext:
#------------------------------------------------------------------------------
# Gem
gem:
+# cd $(GEM_SRC)/Gem && xcodebuild
#------------------------------------------------------------------------------
@@ -180,18 +181,25 @@ pd:
#==============================================================================#
#------------------------------------------------------------------------------
-# abstractions
+# install
+install: license_install readme_install welcome_install gem_install
+install: pd_install abstractions_install doc_install externals_install
+install: noncvs_install
+ @echo "Complete install succeeded!"
+
+#------------------------------------------------------------------------------
+# abstractions_install
abstractions_install:
cd $(ABSTRACTIONS_SRC) && make $(DEST_PATHS) install
#------------------------------------------------------------------------------
-# doc
+# doc_install
doc_install:
cd $(DOC_SRC) && make $(DEST_PATHS) install
#------------------------------------------------------------------------------
-# externals
+# externals_install
externals_install:
cd $(EXTERNALS_SRC) && make $(DEST_PATHS) install
@@ -210,12 +218,38 @@ flext_install:
#------------------------------------------------------------------------------
-# Gem
-gem_install:
+# gem_install
+GEM_NAME = gem
+gem_install: gem $(HELP_DEST)
+ install -p $(GEM_SRC)/help/*.* $(HELP_DEST)
+ install -p $(GEM_SRC)/abstractions/*-help.pd $(HELP_DEST)
+ install -d $(OBJECTS_DEST)/$(GEM_NAME)
+ install -p $(shell ls -1 $(GEM_SRC)/abstractions/*.* | \
+ grep -v '\-help.pd') $(OBJECTS_DEST)
+ install -d $(MANUALS_DEST)/$(GEM_NAME)
+ install -p $(GEM_SRC)/doc/*.* $(MANUALS_DEST)/$(GEM_NAME)
+ install -d $(MANUALS_DEST)/$(GEM_NAME)/manual
+ install -p $(GEM_SRC)/manual/*.* $(MANUALS_DEST)/$(GEM_NAME)/manual
+ for dir in $(shell ls -1 $(GEM_SRC)/examples | grep -v CVS); do \
+ echo "installing $$dir"; \
+ install -d $(APPLICATIONS_DEST)/$(GEM_NAME)/$$dir ; \
+ install -p $(GEM_SRC)/examples/$$dir/*.* $(APPLICATIONS_DEST)/$(GEM_NAME)/$$dir ; \
+ done
#------------------------------------------------------------------------------
-# pd
+# noncvs_install
+# this is for including pre-compiled binaries in a build
+noncvs_install:
+ -install -p $(PACKAGES_SRC)/noncvs/$(OS_NAME)/bin/*.* $(BIN_DEST)
+ -install -p $(PACKAGES_SRC)/noncvs/$(OS_NAME)/doc/5.reference/*.* \
+ $(HELP_DEST)
+ -install -p $(PACKAGES_SRC)/noncvs/$(OS_NAME)/extra/*.* $(OBJECTS_DEST)
+
+
+
+#------------------------------------------------------------------------------
+# pd_install
PD_NAME=Pd
pd_install: pd
cd $(PD_SRC)/src && \
@@ -224,14 +258,6 @@ pd_install: pd
install -p $(PD_SRC)/src/notes.txt $(MANUALS_DEST)/$(PD_NAME)
-#------------------------------------------------------------------------------
-# install
-install: license_install readme_install welcome_install
-install: pd_install abstractions_install doc_install externals_install
-#install: flext_install gem_install
- @echo "Complete install succeeded!"
-
-
#==============================================================================#
#
@@ -340,10 +366,10 @@ doc_format:
# run script to move help-*.pd files to *-help.pd according to the standard
cd $(DOCS_DEST) && \
$(SCRIPTS_SRC)/convert-help-to-standard.sh
-#----------------------------------------------------------------------------
# remove write perms to prevent people form editing the helpfiles by mistake
cd $(DOCS_DEST) && chmod a-wx */*.pd */*/*.pd
- cd $(DOCS_DEST) && chmod a-w ????*/*.* *.txt
+ find $(DOCS_DEST) -name '*.pd' -print0 | xargs -0 chmod a-wx
+ find $(DOCS_DEST) -name '*.txt' -print0 | xargs -0 chmod a-wx
diff --git a/packages/Makefile.buildlayout b/packages/Makefile.buildlayout
index 32500ae9..12df9df5 100644
--- a/packages/Makefile.buildlayout
+++ b/packages/Makefile.buildlayout
@@ -65,10 +65,10 @@ endif
# sources
ABSTRACTIONS_SRC = $(SRC_ROOT_DIR)/abstractions
DOC_SRC = $(SRC_ROOT_DIR)/doc
+EXTENSIONS_SRC = $(SRC_ROOT_DIR)/extensions
EXTERNALS_SRC = $(SRC_ROOT_DIR)/externals
FLEXT_SRC = $(SRC_ROOT_DIR)/externals/grill/flext
GEM_SRC = $(SRC_ROOT_DIR)/Gem
-GEMLIBS_SRC = $(SRC_ROOT_DIR)/GemLibs
PACKAGES_SRC = $(SRC_ROOT_DIR)/packages
PD_SRC = $(SRC_ROOT_DIR)/pd
SCRIPTS_SRC = $(SRC_ROOT_DIR)/scripts
@@ -130,7 +130,7 @@ PD_VERSION = $(PD_MAJOR_VERSION).$(PD_MINOR_VERSION).$(PD_BUGFIX_VERSION)
# release version for this distro
-PACKAGE_VERSION = extended-RC4
+PACKAGE_VERSION = extended-RC5
PACKAGE_NAME = Pd-$(PD_VERSION)-$(PACKAGE_VERSION)
diff --git a/packages/TODO b/packages/TODO
index 204e24ac..6544f838 100644
--- a/packages/TODO
+++ b/packages/TODO
@@ -1,9 +1,8 @@
-- fix scripts/checkout...sh. It doesn't cvs co into the newly created pure-data folder
-
-- add packages/win32_inno/Makefile to cvs on winky
+- move darwin_app_perms to here and make generic prerelease_clean target which
+ is called separately
-- menu_openhtml on Win32 with rundll should be able to open other filetypes like open on MACOSX.
+- fix scripts/checkout...sh. It doesn't cvs co into the newly created pure-data folder
- rename "applications" to "examples"
@@ -11,17 +10,12 @@
- On GNU/Linux, figure out how to deal with build/extra vs. build/lib/pd/extra
-- make loaderHEX functions follow Pd standart of object_setup() rather than
- setup_object()
-
- global optimization flags
ideally, you would use a version of Pd that is fully optimized for your
CPU. In order to do this, a system of optimization flags needs to be
developed so that you can specific the target CPU in one place and have
everything compile for that CPU.
-- document libdir format
-
- add GRIPD for Anders
- add reg keys for Martin Dupras
@@ -30,3 +24,17 @@
- make standard targets: distclean (*~, etc.), installdirs (make just the
dirs), uninstall instead of install_clean
+
+- help menu
+
+ - check up on this bug: Opening Help patches from "Pure Documentation"
+
+ - make help menu function check if item exists before trying to make a
+ menu item so that it doesn't break pd.tk<->pd interaction (i.e. windows
+ titled x50bf90). (the recursive function might have fixed this)
+
+ - port to Linux/Windows
+
+- Preferences
+
+ - look at BBogart's LML http://www.ekran.org/ben/research/lml/lml-v0.1-TEST8-osx.tgz
diff --git a/packages/darwin_app/Info.plist.in b/packages/darwin_app/Info.plist.in
index d2a4201a..4450e8d6 100644
--- a/packages/darwin_app/Info.plist.in
+++ b/packages/darwin_app/Info.plist.in
@@ -9,7 +9,8 @@
<dict>
<key>CFBundleTypeExtensions</key>
<array>
- <string>PD_APP_NAME</string>
+ <string>pd</string>
+ <string>pat</string>
</array>
<key>CFBundleTypeIconFile</key>
<string>pd-file.icns</string>
@@ -22,7 +23,7 @@
<key>CFBundleExecutable</key>
<string>Pd</string>
<key>CFBundleIdentifier</key>
- <string>org.puredata.pd</string>
+ <string>org.puredata.pd.wish</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
diff --git a/packages/darwin_app/Makefile b/packages/darwin_app/Makefile
index 9ba57465..2aa69bf0 100644
--- a/packages/darwin_app/Makefile
+++ b/packages/darwin_app/Makefile
@@ -35,7 +35,7 @@ DEST_PATHS = BUILDLAYOUT_DIR=$(BUILDLAYOUT_DIR) \
install: darwin_app
#------------------------------------------------------------------------------#
-darwin_app: darwin_app_core extended_app_install rez_install
+darwin_app: darwin_app_core extended_app_install darwin_app_doc_format rez_install
@echo " "
@echo "Pd.app build succeeded!"
@@ -43,7 +43,7 @@ darwin_app: darwin_app_core extended_app_install rez_install
# this target is for when you already have a pre-built Pd.app and you
# just want to fill it with goodies from CVS. To do so, place your
# Pd.app in $(BUILD_BASE)/Pd.app
-extended_app_install: extended_install darwin_app_noncvs darwin_app_doc_format
+extended_app_install: extended_install
#------------------------------------------------------------------------------#
@@ -68,7 +68,7 @@ darwin_app_wrapper: Info.plist
install -m0644 -p Info.plist "$(PD_APP_CONTENTS)"
install -m0644 -p *.icns "$(PD_APP_CONTENTS)/Resources"
mv "$(PD_APP_CONTENTS)/MacOS/Wish Shell" \
- "$(PD_APP_CONTENTS)/MacOS/$(PD_APP_NAME)"
+ "$(PD_APP_CONTENTS)/MacOS/Pd"
# diskutil eject /Volumes/$(TCLTK)
@@ -107,6 +107,7 @@ darwin_app_doc_format:
cd $(DOCS_DEST) && \
sed -i.bak 's/^\(\#N canvas [0-9]* [0-9]* [0-9]* [0-9]*\) 12/\1 10/' \
*/*.pd */*/*.pd */*/*/*.pd
+ find $(INSTALL_PREFIX) -name '*.pd.bak' -delete
#==============================================================================#
#
@@ -120,19 +121,7 @@ extended_install:
#------------------------------------------------------------------------------#
darwin_app_externals: darwin_app_externals_standard darwin_app_externals_c++ darwin_app_externals_flext
-#darwin_app_externals: darwin_app_externals_standard darwin_app_externals_c++ darwin_app_externals_gem
-
-
-#------------------------------------------------------------------------------#
-# GEM
-darwin_app_externals_gem:
- cd $(GEM_SRC)/Gem && xcodebuild
- install -p -m0644 $(GEM_SRC)/Gem/help/*.* $(HELP_DEST)
- install -d $(DOCS_DEST)/Gem/doc
- install -p -m0644 $(GEM_SRC)/Gem/doc/*.* $(DOCS_DEST)/gem
- install -d $(DOCS_DEST)/Gem/00.manual
- install -p -m0644 $(GEM_SRC)/Gem/manual/*.* $(DOCS_DEST)/gem/00.manual
- cp -Rfp $(GEM_SRC)/Gem/examples/*.* $(GEM_SRC)/Gem/examples/data $(DOCS_DEST)/gem
+#darwin_app_externals: darwin_app_externals_standard darwin_app_externals_c++
#------------------------------------------------------------------------------#
@@ -270,24 +259,10 @@ darwin_app_externals_c++:
# gem2pdp
# cd $(EXTERNALS_SRC)/gem2pdp && $(MAKE) -f Makefile.darwin
# install -p -m0444 $(EXTERNALS_SRC)/gem2pdp/*.pd_darwin $(OBJECTS_DEST)
-#----------------------------------------------------------------------------
-# GridFlow
-# cd ../../gridflow && ./configure && $(MAKE)
-darwin_app_noncvs:
- test -d noncvs/doc/5.reference && \
- install -p noncvs/doc/5.reference/*.* $(HELP_DEST)
- test -d noncvs/extra && install -p noncvs/extra/*.* $(OBJECTS_DEST)
- test -d noncvs/doc/serendipd && cp -Rp noncvs/doc/serendipd \
- $(APPLICATIONS_DEST)
-
darwin_app_perms:
- chmod a-x $(DOCS_DEST)/*/*.pd $(DOCS_DEST)/*/*/*.pd $(DOCS_DEST)/*/*/*/*.pd
chmod -R a-w $(DOCS_DEST)
-# serendiPd shared patch
- test -d $(APPLICATIONS_DEST)/serendipd && \
- chmod a+w $(APPLICATIONS_DEST)/serendipd/*shared_patch.pd
DMG_NAME = $(PACKAGE_NAME)
dmg: darwin_app_perms
@@ -299,8 +274,7 @@ dmg: darwin_app_perms
cd $(CWD) && /bin/sh mkdmg "$(DMG_NAME)"
-clean: darwin_app_clean darwin_app_externals_standard_clean \
- darwin_app_externals_gem_clean darwin_app_externals_flext_clean \
+clean: darwin_app_clean darwin_app_externals_flext_clean \
cd $(PACKAGES_SRC) && make clean
-rm Info.plist
@@ -312,7 +286,7 @@ darwin_app_clean:
-darwin_app_externals_gem_clean:
+
cd $(GEM_SRC)/Gem && xcodebuild clean
darwin_app_externals_flext_clean:
@@ -331,6 +305,22 @@ darwin_app_externals_flext_clean:
#
#==============================================================================#
+darwin_app_noncvs:
+ @echo " "
+ @echo "Deprecated!!"
+ @echo "cd $(PACKAGES_SRC) && make noncvs_install"
+ cd $(PACKAGES_SRC) && make $(DEST_PATHS) noncvs_install
+
+darwin_app_externals_gem_clean:
+ @echo " "
+ @echo "Deprecated!!"
+ @echo "cd $(PACKAGES_SRC) && make gem_clean"
+
+darwin_app_externals_gem:
+ @echo " "
+ @echo "Deprecated!!"
+ @echo "cd $(PACKAGES_SRC) && make gem_install"
+
darwin_app_externals_standard_clean:
@echo " "
@echo "Deprecated!!"
diff --git a/packages/darwin_app/TODO b/packages/darwin_app/TODO
index a64c8665..38bc6a39 100644
--- a/packages/darwin_app/TODO
+++ b/packages/darwin_app/TODO
@@ -3,18 +3,11 @@
- in post-clean, rm *.bak
-- make Info.plist.in template and have the Makefile create Info.plist
-
-- check to make sure that Rez mac.r is working in Makefile
-
- make Pd open a new window when its launched to workaround the bug where the
menus don't work until a window is opened.
- otool dylib help: http://qin.laya.com/tech_coding_help/dylib_linking.html
-- add symbolic link for flext
- (cd Pd.app/Contents/Resources/extra && ln -s . lib)
-
- from Carmen Rocco about [fiddle~] crash: "is fiddle~: * compiled with the same header * linked with the same binary of (lib)pd * compiled with the same compiler? i had very similar issues with bonk on windows (Virtually same stacktrace but s/fiddle/bonk) until fixing the above 3 things..."
- review permissions so that you can build on top on existing builds
@@ -55,7 +48,7 @@ http://developer.apple.com/documentation/MacOSX/Conceptual/BPFileSystem/Articles
- make Cmd-click work like Ctrl-click
- write script to convert from -DMACOSX to -D__APPLE__ where ever possible (check out
- __gnu_linux__ while I am at it) and submit to miller
+ __gnu_linux__ and WIN32 while I am at it) and submit to miller
- instead of shipping Pd.app with a org.puredata.pd.plist, make a script that
uses the "defaults" command to add the desired prefs to any existing
diff --git a/packages/patches/darwin/darwin_dlopen.patch b/packages/patches/darwin/darwin_dlopen.patch
new file mode 100644
index 00000000..a93ef7ed
--- /dev/null
+++ b/packages/patches/darwin/darwin_dlopen.patch
@@ -0,0 +1,65 @@
+Index: s_loader.c
+===================================================================
+RCS file: /cvsroot/pure-data/pd/src/s_loader.c,v
+retrieving revision 1.4
+diff -u -w -r1.4 s_loader.c
+--- s_loader.c 6 Sep 2004 20:20:35 -0000 1.4
++++ s_loader.c 26 Nov 2005 00:27:11 -0000
+@@ -2,6 +2,9 @@
+ * For information on usage and redistribution, and for a DISCLAIMER OF ALL
+ * WARRANTIES, see the file, "LICENSE.txt," in this distribution. */
+
++#ifdef __APPLE__
++#define DL_OPEN
++#endif
+ #ifdef DL_OPEN
+ #include <dlfcn.h>
+ #endif
+@@ -13,7 +16,7 @@
+ #include <io.h>
+ #include <windows.h>
+ #endif
+-#ifdef MACOSX
++#ifdef MACOSX10.2
+ #include <mach-o/dyld.h>
+ #endif
+ #include <string.h>
+@@ -90,7 +93,7 @@
+ if (lastdot = strrchr(nameptr, '.'))
+ *lastdot = 0;
+
+-#ifdef MACOSX
++#ifdef MACOSX10.2
+ strcpy(symname, "_");
+ strcat(symname, nameptr);
+ #else
+@@ -122,7 +125,7 @@
+ }
+ makeout = (t_xxx)GetProcAddress(ntdll, symname);
+ #endif
+-#ifdef MACOSX
++#ifdef MACOSX10.2
+ {
+ NSObjectFileImage image;
+ void *ret;
+@@ -134,8 +137,18 @@
+ return 0;
+ }
+ ret = NSLinkModule( image, filename,
+- NSLINKMODULE_OPTION_BINDNOW + NSLINKMODULE_OPTION_PRIVATE);
+-
++ NSLINKMODULE_OPTION_BINDNOW |
++ //NSLINKMODULE_OPTION_PRIVATE |
++ NSLINKMODULE_OPTION_RETURN_ON_ERROR);
++
++ if (ret == NULL) {
++ int err;
++ const char *fname, *errt;
++ NSLinkEditErrors c;
++ NSLinkEditError(&c, &err, &fname, &errt);
++ post("link error %d %s %s", err, fname, errt);
++ return 0;
++ }
+ s = NSLookupSymbolInModule(ret, symname);
+
+ if (s)
diff --git a/packages/patches/extended-help-menu.patch b/packages/patches/extended-help-menu.patch
index 0cabfeaa..192374a5 100644
--- a/packages/patches/extended-help-menu.patch
+++ b/packages/patches/extended-help-menu.patch
@@ -1,38 +1,136 @@
Index: u_main.tk
===================================================================
RCS file: /cvsroot/pure-data/pd/src/u_main.tk,v
---- pd-0.38-4/src/u_main.tk Sun Feb 20 20:03:36 2005
-+++ u_main.tk Wed Nov 16 00:33:02 2005
-@@ -374,22 +374,41 @@
- set help_directory $pd_guidir/doc
- set help_top_directory $pd_guidir/doc
-
-+################## generate_menu_doc_link #########################
-+# This procedure generates a temporary mirror of the documentation directory
-+# in /tmp so that it can be opened from the Help->Pure Documentation... menu
-+# under Mac OS X. It is meant to be run at startup.
-+# Damn you Apple and your "hide stuff from the user" "features".
-+# <hans@at.or.at.>
-+proc generate_menu_doc_link {} {
-+ global help_directory
-+
-+ regsub -all "/" $help_directory "." help_directory_alias
-+ set help_directory_alias /tmp/$help_directory_alias
-+ set help_directory_tmpdir $help_directory_alias/doc
-+ # if something other than a directory exists, delete it
-+ if [file exists $help_directory_alias] {
-+ file delete -force -- $help_directory_alias
-+ }
-+ if { ! [ file isdirectory $help_directory_tmpdir ] } {
-+ file mkdir $help_directory_tmpdir
-+ }
-+ foreach file [ lsort [ glob -dir $help_directory * ] ] {
-+ regsub -all ".*/" $file "" link_file_name
-+ file link -symbolic [file join $help_directory_tmpdir $link_file_name ] $file
-+ }
-+ set help_directory $help_directory_tmpdir
-+}
+retrieving revision 1.7.2.4
+diff -u -w -r1.7.2.4 u_main.tk
+--- u_main.tk 21 Feb 2005 04:20:20 -0000 1.7.2.4
++++ u_main.tk 25 Nov 2005 22:47:06 -0000
+@@ -24,6 +24,14 @@
+ # Tearoff is set to true by default:
+ set pd_tearoff 1
+
++
++# a menu on the main menubar named $whatever.help while be treated
++# as a special menu with specific behaviors on different platforms.
++# See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
++# this is the default name for the Help menu
++set help_menu_name "help"
++
++#################### init for Windows ####################
+ if {$pd_nt == 1} {
+ global pd_guidir
+ global pd_tearoff
+@@ -32,8 +40,12 @@
+ set pd_guidir $pd_gui3/..
+ load $pd_guidir/bin/pdtcl.dll
+ set pd_tearoff 1
++ set help_top_directory $pd_guidir/doc
++ # init last help directory browsed
++ set help_directory $help_top_directory
+ }
+
++##################### init for Mac OS X/Darwin ####################
+ if {$pd_nt == 2} {
+ # turn on James Tittle II's fast drawing (wait until I can test this...):
+ # set tk::mac::useCGDrawing 1
+@@ -43,6 +55,39 @@
+ set pd_guidir $pd_gui2/..
+ load $pd_guidir/bin/pdtcl
+ set pd_tearoff 0
++ set help_top_directory $pd_guidir/doc
++
++
++ # This procedure generates a temporary mirror of the documentation directory
++ # in /tmp so that it can be opened from the Help->Pure Documentation... menu
++ # under Mac OS X. It is meant to be run at startup.
++ # Damn you Apple and your hide-stuff-from-the-user "features".
++ # <hans@at.or.at.>
++ regsub -all "/" $help_top_directory "." help_directory_alias
++ set help_directory_alias /tmp/.pd_help_directory_alias-$help_directory_alias
++ set help_directory_tmpdir $help_directory_alias/doc
++ # if something other than a directory exists, delete it
++ if [file exists $help_directory_alias] {
++ file delete -force -- $help_directory_alias
++ }
++ if { ! [ file isdirectory $help_directory_tmpdir ] } {
++ file mkdir $help_directory_tmpdir
++ }
++ foreach file [ lsort [ glob -dir $help_top_directory * ] ] {
++ regsub -all ".*/" $file "" link_file_name
++ file link -symbolic $help_directory_tmpdir/$link_file_name $file
++ }
++ # init last help directory browsed
++ set help_directory $help_directory_tmpdir
++
++
++ # a menu on the main menubar named "$whatever.help" while be treated
++ # as a special menu with specific behaviors on different platforms.
++ # See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
++ # Apple doesn't allow cascading menus in their Help so I had to call this
++ # one "docs" <hans@at.or.at>
++ set help_menu_name "docs"
++
+
+ # tk::mac::OpenDocument is called with the filenames put into the
+ # var args whenever docs are either dropped on the Pd.app icon or
+@@ -60,14 +105,22 @@
+ # hack so you can easily test-run this script in linux... define pd_guidir
+ # (which is normally defined at startup in pd under linux...)
+
++#################### init for GNU/Linux ####################
+ if {$pd_nt == 0} {
+ if {! [info exists pd_guidir]} {
+ global pd_guidir
+ puts stderr {setting pd_guidir to '.'}
+ set pd_guidir .
++ set help_top_directory $pd_guidir/doc
++ # init last help directory browsed
++ set help_directory $help_top_directory
+ }
+ }
+
++#################### init for all platforms ####################
+
++
++
+ # it's unfortunate but we seem to have to turn off global bindings
+ # for Text objects to get control-s and control-t to do what we want for
+ # "text" dialogs below. Also we have to get rid of tab's changing the focus.
+@@ -95,25 +148,15 @@
+ if {$pd_nt != 2} {
+ .mbar add cascade -label "Windows" -menu .mbar.windows
+ .mbar add cascade -label "Media" -menu .mbar.audio
+-# a menu on the main menubar named $whatever.help while be treated
+-# as a special menu with specific behaviors on different platforms.
+-# See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
+- menu .mbar.help -tearoff $pd_tearoff
+- .mbar add cascade -label "Help" -menu .mbar.help
+ } else {
+ menu .mbar.apple -tearoff 0
+ .mbar add cascade -label "Apple" -menu .mbar.apple
+ # arrange menus according to Apple HIG
+ .mbar add cascade -label "Media" -menu .mbar.audio
+ .mbar add cascade -label "Window" -menu .mbar.windows
+-# a menu on the main menubar named "$whatever.help" while be treated
+-# as a special menu with specific behaviors on different platforms.
+-# See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
+-# Apple doesn't allow cascading menus in their Help so I had to call this
+-# one $mbar.docs # <hans@at.or.at>
+- menu .mbar.docs -tearoff $pd_tearoff
+- .mbar add cascade -label "Help" -menu .mbar.docs
+ }
++menu .mbar.$help_menu_name -tearoff $pd_tearoff
++.mbar add cascade -label "Help" -menu .mbar.$help_menu_name
+
+ set ctrls_audio_on 0
+ set ctrls_meter_on 0
+@@ -371,25 +414,15 @@
+ }
+ }
+
+-set help_directory $pd_guidir/doc
+-set help_top_directory $pd_guidir/doc
+-
+################## menu_documentation #########################
proc menu_documentation {} {
global help_directory
@@ -47,13 +145,14 @@ RCS file: /cvsroot/pure-data/pd/src/u_main.tk,v
- -initialdir /tmp/pd-documentation]
- } else {
set filename [tk_getOpenFile -defaultextension .pd \
- -filetypes { {{documentation} {.pd .txt .htm}} } \
+- -filetypes { {{documentation} {.pd .txt .htm}} } \
++ -filetypes { {{documentation} {.pd .txt .htm .html}} } \
-initialdir $help_directory]
- }
if {$filename != ""} {
if {[string first .txt $filename] >= 0} {
menu_opentext $filename
-@@ -411,35 +430,57 @@
+@@ -411,42 +444,69 @@
set dirname $pd_guidir/$subdir
@@ -73,45 +172,47 @@ RCS file: /cvsroot/pure-data/pd/src/u_main.tk,v
- pd [concat pd open [pdtk_enquote $basename] \
- [pdtk_enquote $dirname] \;]
+ menu_openhtml $dirname/$basename
-+ }
}
}
++}
++
-proc doc_submenu {helpmenu subdir} {
- global help_top_directory pd_tearoff
--
-- set menudir $help_top_directory/$subdir
-
-- regsub -all "\\\." $subdir "" submenu
+################## menu_doc_submenu #########################
-
++
+# this is a recursive function to generation a nested menu in the help menu
+# which shows the complete contents of the doc directory <hans@at.or.at>
+proc menu_doc_submenu {helpmenu base_dir sub_dir} {
-+ global pd_tearoff
-+ global help_top_directory
-+
-+ set menu_dir $help_top_directory/$base_dir/$sub_dir
-+
-+ foreach file [ lsort [ glob -nocomplain -dir $menu_dir * ] ] {
-+ set file_type [file type $file]
-+ regsub {.*/(.*$)} $file {\1} file_name
-+ # If links are going to be used then there needs to be a check to see if each
-+ # link might cause this function to recurse forever <hans@at.or.at>
-+ # if { $file_type == "link"} {
-+ # puts stderr "LINK: $file"
-+ # }
-+ if { $file_type == "file" } {
-+ # only put certain file types on the menu
-+ if {[regexp ".*\.(htm|html|c|pd|txt|tk|pdf|wav|aif|aiff)$" $file]} {
-+ $helpmenu add command -label $file_name \
-+ -command "menu_doc_open doc/$base_dir/$sub_dir $file_name"
-+ }
-+ } elseif { $file_type == "directory" } {
-+ regsub -all "\\\." [string tolower $file_name] "" submenu
++ global pd_tearoff
++ global help_top_directory
+
+- set menudir $help_top_directory/$subdir
++ set menu_dir $help_top_directory/$base_dir/$sub_dir
+
+- regsub -all "\\\." $subdir "" submenu
++ catch {
++ foreach file [ lsort [ glob -nocomplain -dir $menu_dir * ] ] {
++ set file_type [file type $file]
++ regsub {.*/(.*$)} $file {\1} file_name
+
++ # If links are going to be used then there needs to be a check to
++ # see if each link might cause this function to recurse forever
++ # <hans@at.or.at>
++ if { $file_type == "link"} {
++ puts stderr "Warning doc_submenu found a link: $file"
++ }
++ if { $file_type == "file" } {
++ # only put certain file types on the menu
++ if {[regexp ".*\.(htm|html|c|pd|txt|tk|pdf|wav|aif|aiff)$" $file]} {
++ $helpmenu add command -label $file_name \
++ -command "menu_doc_open doc/$base_dir/$sub_dir $file_name"
++ }
++ } elseif { $file_type == "directory" } {
++ regsub -all "\\\." [string tolower $file_name] "" submenu
menu $helpmenu.$submenu -tearoff $pd_tearoff
- regsub -all "\\\." $subdir " " submenuname
-+ regsub -all "\\\." $file_name " " submenuname
++ regsub -all "\\\." $file_name " " submenuname
$helpmenu add cascade -label $submenuname \
-menu $helpmenu.$submenu
-
@@ -122,34 +223,34 @@ RCS file: /cvsroot/pure-data/pd/src/u_main.tk,v
- regsub {.*/(.*\..+$)} $file {\1} filename
- $helpmenu.$submenu add command -label $filename \
- -command "menu_doc_open doc/$subdir $filename"
-+ menu_doc_submenu $helpmenu.$submenu $base_dir/$sub_dir [file tail $file]
-+ }
++ menu_doc_submenu $helpmenu.$submenu $base_dir/$sub_dir \
++ [file tail $file]
++ }
++ }
}
}
-@@ -494,7 +535,18 @@
+ ############# routine to add media, help, and apple menu items ###############
+
+ proc menu_addstd {mbar} {
+- global pd_apilist pd_nt pd_tearoff
++ global pd_apilist pd_nt pd_tearoff help_menu_name
+ # the "Audio" menu
+ $mbar.audio add command -label {audio ON} -accelerator [accel_munge "Ctrl+/"] \
+ -command {menu_audio 1}
+@@ -494,30 +554,15 @@
# the "Help" menu
- if {$pd_nt != 2} {
-+ if {$pd_nt == 2} {
-+# Apple doesn't allow cascading menus in their Help so I had to call this
-+# one "docs" <hans@at.or.at>
-+ generate_menu_doc_link
-+ $mbar.docs add command -label {Browse Documentation...} \
-+ -command {menu_documentation}
-+ # the help menu only really works well on Mac OS X <hans@at.or.at>
-+ $mbar.docs add command -label {Pd HTML Manual...} \
-+ -command {menu_doc_open doc/1.manual index.htm}
-+ $mbar.docs add separator
-+ menu_doc_submenu $mbar.docs "." "."
-+ } else {
- # a menu on the main menubar named "$whatever.help" while be treated
- # as a special menu with specific behaviors on different platforms.
- # See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
-@@ -502,22 +554,9 @@
- -command {menu_doc_open doc/1.manual 1.introduction.txt}
- $mbar.help add command -label {Pure Documentation...} \
+-# a menu on the main menubar named "$whatever.help" while be treated
+-# as a special menu with specific behaviors on different platforms.
+-# See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
+- $mbar.help add command -label {About Pd} \
+- -command {menu_doc_open doc/1.manual 1.introduction.txt}
+- $mbar.help add command -label {Pure Documentation...} \
++ puts stderr "Starting Menu crap"
++ $mbar.$help_menu_name add command -label {Browse Documentation...} \
-command {menu_documentation}
- # add menu items for each section instead of using Pd patches
- $mbar.help add separator
@@ -161,14 +262,43 @@ RCS file: /cvsroot/pure-data/pd/src/u_main.tk,v
- }
-
- $mbar.$helpmenuname add command -label {1 manual...} \
-+ $mbar.help add command -label {1 manual...} \
++ # the help menu only really works well on Mac OS X <hans@at.or.at>
++ $mbar.$help_menu_name add command -label {Pd HTML Manual...} \
-command {menu_doc_open doc/1.manual index.htm}
- doc_submenu $mbar.$helpmenuname 2.control.examples
- doc_submenu $mbar.$helpmenuname 3.audio.examples
- doc_submenu $mbar.$helpmenuname 4.fft.examples
- doc_submenu $mbar.$helpmenuname 5.reference
- doc_submenu $mbar.$helpmenuname 6.externs
-+ }
++ $mbar.$help_menu_name add separator
++ menu_doc_submenu $mbar.$help_menu_name "." "."
++ puts stderr "Finishing Menu crap"
}
#################### the "File" menu for the Pd window ##############
+@@ -820,6 +865,7 @@
+ global pd_opendir
+ global pd_tearoff
+ global pd_nt
++ global help_menu_name
+
+ toplevel $name -menu $name.m
+ # puts stderr [concat geometry: $geometry]
+@@ -1078,13 +1124,11 @@
+ # as a special menu with specific behaviors on different platforms.
+ # See SPECIAL MENUS IN MENUBARS http://www.tcl.tk/man/tcl8.4/TkCmd/menu.htm
+ if {$pd_nt != 2} {
+- menu $name.m.help -tearoff $pd_tearoff
+- $name.m add cascade -label Help -menu $name.m.help
++ menu $name.m.$help_menu_name -tearoff $pd_tearoff
++ $name.m add cascade -label Help -menu $name.m.$help_menu_name
+ } else {
+- # Apple doesn't allow cascading menus in their Help
+- # so I had to call this one "docs". <hans@at.or.at>
+- menu $name.m.docs -tearoff $pd_tearoff
+- $name.m add cascade -label Help -menu $name.m.docs
++ menu $name.m.$help_menu_name -tearoff $pd_tearoff
++ $name.m add cascade -label Help -menu $name.m.$help_menu_name
+ }
+
+ menu_addstd $name.m
diff --git a/packages/win32_inno/TODO b/packages/win32_inno/TODO
index f85f3b6b..278207ee 100644
--- a/packages/win32_inno/TODO
+++ b/packages/win32_inno/TODO
@@ -1,4 +1,6 @@
+- add SMlib from email from Anders
+
- add Gem to noncvs
- get Pd compiling on MinGW:. From Carmen: