finished merge of cairocanvas with windows and windows+cc branches
authorPaul Davis <paul@linuxaudiosystems.com>
Fri, 10 Jan 2014 22:11:10 +0000 (17:11 -0500)
committerPaul Davis <paul@linuxaudiosystems.com>
Fri, 10 Jan 2014 22:11:10 +0000 (17:11 -0500)
102 files changed:
gtk2_ardour/ardour_ui.cc
gtk2_ardour/automation_line.cc
gtk2_ardour/export_range_markers_dialog.cc
gtk2_ardour/linux_vst_gui_support.cc
gtk2_ardour/lxvst_plugin_ui.cc
gtk2_ardour/main.cc
gtk2_ardour/plugin_eq_gui.cc
gtk2_ardour/system_exec.cc
gtk2_ardour/system_exec.h
gtk2_ardour/utils_videotl.cc
gtk2_ardour/wscript
libs/ardour/ardour/debug.h
libs/ardour/ardour/directory_names.h
libs/ardour/ardour/session_event.h
libs/ardour/audio_buffer.cc
libs/ardour/audio_diskstream.cc
libs/ardour/io.cc
libs/ardour/mtc_slave.cc
libs/ardour/panner_search_path.cc
libs/ardour/session_state.cc
libs/ardour/test/audio_engine_test.cc [new file with mode: 0644]
libs/ardour/test/audio_engine_test.h [new file with mode: 0644]
libs/ardour/wscript
libs/backends/jack/jack_connection.cc
libs/backends/jack/jack_session.cc
libs/backends/jack/jack_utils.cc
libs/backends/jack/wscript
libs/gtkmm2ext/wscript
libs/pbd/fpu.cc
libs/pbd/pathexpand.cc
libs/pbd/pbd/abstract_ui.h
libs/taglib/wscript
tools/autowaf.py
tools/windows_packaging/Fedora-16-mingw.txt [deleted file]
tools/windows_packaging/README
tools/windows_packaging/configure-distcc-debug.sh [new file with mode: 0755]
tools/windows_packaging/configure-distcc-release.sh [new file with mode: 0755]
tools/windows_packaging/cptovm.sh [deleted file]
tools/windows_packaging/cptovmshare.sh [new file with mode: 0755]
tools/windows_packaging/gdb-ardour.bat [new file with mode: 0644]
tools/windows_packaging/gdb.bat [new file with mode: 0644]
tools/windows_packaging/gdbinit_home [new file with mode: 0644]
tools/windows_packaging/mingw-env.sh
tools/windows_packaging/mingw64/fonts/conf.avail/10-autohint.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/10-no-sub-pixel.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-bgr.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-rgb.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-vbgr.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-vrgb.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/10-unhinted.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/20-fix-globaladvance.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/20-unhint-small-vera.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/25-unhint-nonlatin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/30-metric-aliases.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/30-urw-aliases.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/40-nonlatin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/45-latin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/49-sansserif.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/50-user.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/51-local.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/60-latin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/65-fonts-persian.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/65-khmer.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/65-nonlatin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/69-unifont.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/70-no-bitmaps.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/70-yes-bitmaps.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/80-delicious.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.avail/90-synthetic.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/20-fix-globaladvance.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/20-unhint-small-vera.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/30-metric-aliases.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/30-urw-aliases.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/40-nonlatin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/45-latin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/49-sansserif.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/50-user.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/51-local.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/60-latin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/65-fonts-persian.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/65-nonlatin.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/69-unifont.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/80-delicious.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/90-synthetic.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/conf.d/README [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/fonts.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/fonts/fonts.dtd [new file with mode: 0644]
tools/windows_packaging/mingw64/gtk-2.0/gtk.immodules [new file with mode: 0644]
tools/windows_packaging/mingw64/gtk-2.0/im-multipress.conf [new file with mode: 0644]
tools/windows_packaging/mingw64/pango/pango.modules [new file with mode: 0644]
tools/windows_packaging/package.sh
tools/windows_packaging/package_win32.sh [new file with mode: 0755]
tools/windows_packaging/run-wine.sh [deleted file]
tools/windows_packaging/startvm.sh [deleted file]
tools/windows_packaging/win32-env.sh [new file with mode: 0755]
tools/windows_packaging/wine-ardour-tests.sh [new file with mode: 0755]
tools/windows_packaging/wine-ardour.sh [new file with mode: 0755]
tools/windows_packaging/wine-env.sh [new file with mode: 0755]
tools/windows_packaging/wine-evoral-tests.sh [new file with mode: 0755]
tools/windows_packaging/wine-pbd-tests.sh [new file with mode: 0755]
waf
wscript

index a2a5f0a385e12981b0fa790adc959e85a44a5780..a771ed48b990831201d988541847bf7bca5ba8f0 100644 (file)
@@ -759,7 +759,7 @@ ARDOUR_UI::starting ()
                                nsm->check ();
 
                                Glib::usleep (i);
-                               if (nsm->is_active())
+                               if (nsm->is_active()) {
                                        break;
                                }
                        }
@@ -770,9 +770,8 @@ ARDOUR_UI::starting ()
                        // wait for open command from nsm server
                        for ( i = 0; i < 5000; ++i) {
                                nsm->check ();
-
                                Glib::usleep (1000);
-                               if (nsm->client_id ())
+                               if (nsm->client_id ()) {
                                        break;
                                }
                        }
index 2551b40c753abbb330705c1134349481aa3ff652..9fe1e0fa19cf61beee1b2fe81757dd9d37dfe431 100644 (file)
 
 #ifdef COMPILER_MSVC
 #include <float.h>
-
-// 'std::isinf()' and 'std::isnan()' are not available in MSVC.
+/* isinf() & isnan() are C99 standards, which older MSVC doesn't provide */
 #define isinf(val) !((bool)_finite((double)val))
 #define isnan(val) (bool)_isnan((double)val)
-#else
-using std::isnan;
-using std::isinf;
 #endif
 
 #include <cmath>
index 4b991629743ca4a598e0fe7c953e7d13cffbcfb3..97a8dba25fa7de301c4eca26d70e8d2689476989 100644 (file)
@@ -93,7 +93,7 @@ ExportRangeMarkersDialog::process_range_markers_export(Locations::LocationList&
                                if(gtk_events_pending()){
                                        gtk_main_iteration();
                                }else {
-                                       usleep(10000);
+                                       Glib::usleep(10000);
                                }
                        }
 
index 6eec688a7ccc631e9820455db7681bd8e0132626..4d90bdd4aa98e1388fababee0ba0be087e7d8671 100644 (file)
@@ -33,6 +33,7 @@
 #include <pthread.h>
 #include <signal.h>
 #include <glib.h>
+#include <glibmm/timer.h>
 
 #include "ardour/linux_vst_support.h"
 
@@ -377,7 +378,7 @@ void* gui_event_loop (void* ptr)
 
                /*We don't want to use all the CPU.. */
 
-               usleep(1000);
+               Glib::usleep(1000);
                
                LXVST_sched_event_timer++;
                
@@ -706,7 +707,7 @@ vstfx_launch_editor (VSTState* vstfx)
        /*QUIRK - some plugins need a slight delay after opening the editor before you can
        ask the window size or they might return zero - specifically discoDSP */
        
-       usleep(100000);
+       Glib::usleep(100000);
        
        /*Now we can find out how big the parent window should be (and try) to resize it*/
        
index d31038755b54b1116b10ebdc9a66b9e17e5f17f5..e3335d4990775b5ff3cd72bd6e5bd18fbadf4053 100644 (file)
@@ -141,7 +141,7 @@ LXVSTPluginUI::get_XID ()
        */
        
        while (!(_vst->state()->been_activated)) {
-               usleep (1000);
+               Glib::usleep (1000);
        }
        
        int const id = _vst->state()->xid;
index de56b1e387d13f0c7ad7748b22493958c0d665cc..d212edef92fdfd2bb3f5f97baf46fc731cfb4f63 100644 (file)
@@ -175,8 +175,8 @@ fixup_bundle_environment (int, char* [])
        export_search_path (bundle_dir, "VAMP_PATH", "/lib");
        export_search_path (bundle_dir, "GTK_PATH", "/lib/gtkengines");
 
-       setenv ("SUIL_MODULE_DIR", (bundle_dir + "/lib").c_str(), 1);
-       setenv ("PATH", (bundle_dir + "/MacOS:" + std::string(getenv ("PATH"))).c_str(), 1);
+       g_setenv ("SUIL_MODULE_DIR", (bundle_dir + "/lib").c_str(), 1);
+       g_setenv ("PATH", (bundle_dir + "/MacOS:" + std::string(g_getenv ("PATH"))).c_str(), 1);
 
        /* unset GTK_RC_FILES so that we only load the RC files that we define
         */
@@ -285,8 +285,8 @@ fixup_bundle_environment (int /*argc*/, char* argv[])
        export_search_path (dir_path, "VAMP_PATH", "/lib");
        export_search_path (dir_path, "GTK_PATH", "/lib/gtkengines");
 
-       setenv ("SUIL_MODULE_DIR", (dir_path + "/lib").c_str(), 1);
-       setenv ("PATH", (dir_path + "/bin:" + std::string(getenv ("PATH"))).c_str(), 1);
+       g_setenv ("SUIL_MODULE_DIR", (dir_path + "/lib").c_str(), 1);
+       g_setenv ("PATH", (dir_path + "/bin:" + std::string(g_getenv ("PATH"))).c_str(), 1);
 
        /* unset GTK_RC_FILES so that we only load the RC files that we define
         */
index 4bf2a5f87913e8143b67c0bc9aa61446c84e9632..9a91d0c124dea0647c2183f481b6b704e036cdb5 100644 (file)
 
 #ifdef COMPILER_MSVC
 #include <float.h>
-
-// 'std::isinf()' and 'std::isnan()' are not available in MSVC.
+/* isinf() & isnan() are C99 standards, which older MSVC doesn't provide */
 #define isinf(val) !((bool)_finite((double)val))
 #define isnan(val) (bool)_isnan((double)val)
-#else
-using std::isnan;
-using std::isinf;
 #endif
 
 #include "plugin_eq_gui.h"
index 1a8399d22ebfc49b25c7164259c235d70310c8fc..034ba90e4069ec73b45f7045c6e22040e6574ddf 100644 (file)
@@ -540,7 +540,7 @@ SystemExec::terminate ()
        
        if (pid) {
                ::kill(pid, SIGTERM);
-               ::usleep(50000);
+               usleep(50000);
                sched_yield();
                wait(WNOHANG);
        }
index 38589bb26fbe002492360c789f5d2fc09d74478c..c69f957d954a235a14e7d16662f1d38f3616c3aa 100644 (file)
 #define STDERR_FILENO 2
 #endif
 
+#if defined (__MINGW64__)
+#include <windows.h>
+
+#ifdef interface
+#undef interface // VKamyshniy: to avoid "include/giomm-2.4/giomm/dbusmessage.h:270:94: error: expected ',' or '...' before 'struct'"
+#endif
+
+#endif
+
 #include <string>
 #include <pthread.h>
 #include <signal.h>
index ed1bfad766eafbeb8c2fe996deb2acdeff583205..2e250b2cee29321b140419e6f815afa2c9a2e216 100644 (file)
@@ -325,7 +325,7 @@ extern "C" {
                struct A3MemoryStruct chunk;
                long int httpstatus;
                if (status) *status = 0;
-               //usleep(500000); return NULL; // TEST & DEBUG
+               //Glib::usleep(500000); return NULL; // TEST & DEBUG
                if (strncmp("http://", u, 7)) return NULL;
 
                chunk.data=NULL;
index 578409c4ae853f8142f99690ceafcbbe4cbf9fa7..41d5a269f693d7dee6945f0f16861da8a3224433 100644 (file)
@@ -3,6 +3,7 @@ from waflib.extras import autowaf as autowaf
 from waflib import Options, TaskGen
 import waflib.Logs as Logs, waflib.Utils as Utils
 import os
+import shutil
 import sys
 import re
 import time
@@ -630,7 +631,7 @@ def build(bld):
     obj.install_path = None
     set_subst_dict(obj, light_rc_subst_dict)
 
-    obj              = bld(rule = 'cp ${SRC} ${TGT}')
+    obj              = bld(rule = autowaf.copyfile) 
     obj.source       = [ 'ardour3_widget_list.rc' ]
     obj.target       = 'ardour3_widgets.rc'
     obj.install_path = None
@@ -672,11 +673,15 @@ def build(bld):
     # 'SAE-de-keypad', 'SAE-de-nokeypad', 'SAE-us-keypad',
     # 'SAE-us-nokeypad', 'ergonomic-us'
 
+    #
+    # explicitly state the use of perl here so that it works on windows too
+    # 
+    a_rule = 'perl ../tools/fmt-bindings --platform="%s" --winkey="%s" --accelmap <${SRC} >${TGT}' % (sys.platform, bld.env['WINDOWS_KEY'] )
     for b in [ 'mnemonic-us' ] :
         obj = bld(
             target = b + '.bindings',
             source = b + '.bindings.in',
-            rule = '../tools/fmt-bindings --platform="%s" --winkey="%s" --accelmap <${SRC} >${TGT}' % (sys.platform, bld.env['WINDOWS_KEY'] )
+            rule = a_rule
             )
         obj.install_path = os.path.join(bld.env['SYSCONFDIR'], 'ardour3')
 
index c26710b62095a124c3a20627b4608704d6dd2e56..d5d81b87729ece5b4051ac6d0654f0f14b0d198d 100644 (file)
@@ -35,6 +35,7 @@ namespace PBD {
                LIBARDOUR_API extern uint64_t SnapBBT;
                LIBARDOUR_API extern uint64_t Configuration;
                LIBARDOUR_API extern uint64_t Latency;
+               LIBARDOUR_API extern uint64_t Peaks;
                LIBARDOUR_API extern uint64_t Processors;
                LIBARDOUR_API extern uint64_t ProcessThreads;
                LIBARDOUR_API extern uint64_t Graph;
index 9eb2254219cf6c084d9a5a00fb1c40620fe0e8f4..db5d770739765e80632523522841671dff6ca2b9 100644 (file)
@@ -27,6 +27,7 @@ namespace ARDOUR {
 
        LIBARDOUR_API extern const char* const old_sound_dir_name;
        LIBARDOUR_API extern const char* const sound_dir_name;
+       LIBARDOUR_API extern const char* const ladspa_dir_name;
        LIBARDOUR_API extern const char* const midi_dir_name;
        LIBARDOUR_API extern const char* const midi_patch_dir_name;
        LIBARDOUR_API extern const char* const video_dir_name;
index d4102a62eff2b779043e2ea548e092a02a8b7ab1..1283f320040eb2ba3c58929bd69e86df51c1f7f7 100644 (file)
@@ -109,7 +109,7 @@ public:
 
        boost::shared_ptr<Region> region;
 
-    SessionEvent (Type t, Action a, framepos_t when, framepos_t where, double spd, bool yn = false, bool yn2 = false, bool yn3 = false)
+       SessionEvent (Type t, Action a, framepos_t when, framepos_t where, double spd, bool yn = false, bool yn2 = false, bool yn3 = false)
                : type (t)
                , action (a)
                , action_frame (when)
@@ -151,7 +151,7 @@ private:
        friend class Butler;
 };
 
-class LIBARDOUR_API SessionEventManager {
+class SessionEventManager {
 public:
        SessionEventManager () : pending_events (2048),
                                 auto_loop_event(0), punch_out_event(0), punch_in_event(0) {}
index b4e2a55ac2e7d38452e4dda3a7517dbaf03880fa..aa4f64755aeb9399d31e402b8703eae2dd1a4d1d 100644 (file)
@@ -88,7 +88,7 @@ AudioBuffer::check_silence (pframes_t nframes, bool wholebuffer, pframes_t& n) c
 
 void
 AudioBuffer::silence (framecnt_t len, framecnt_t offset) {
-       pframes_t n = 0;
+
        if (!_silent) {
                assert(_capacity > 0);
                assert(offset + len <= _capacity);
index f4d10c2043041dc41e83926acb9aceed428a944e..dd2dcf324eac9db2e6dcf34d5a3d408f920cdd61 100644 (file)
@@ -1789,7 +1789,7 @@ AudioDiskstream::get_state ()
        LocaleGuard lg (X_("POSIX"));
 
        boost::shared_ptr<ChannelList> c = channels.reader();
-       snprintf (buf, sizeof(buf), "%zd", c->size());
+       snprintf (buf, sizeof(buf), "%u", (unsigned int) c->size());
        node.add_property ("channels", buf);
 
        if (!capturing_sources.empty() && _session.get_record_enabled()) {
index ebd295411e9cdfaf3d5198e0c36f0a737cd86d92..2cc213f7975932624527f6ee58cd1c850aa14c01 100644 (file)
@@ -1414,7 +1414,7 @@ IO::find_port_hole (const char* base)
                std::vector<char> buf (AudioEngine::instance()->port_name_size());
                PortSet::iterator i = _ports.begin();
 
-               snprintf (&buf[0], jack_port_name_size(), _("%s %u"), base, n);
+               snprintf (&buf[0], buf.size()+1, _("%s %u"), base, n);
 
                for ( ; i != _ports.end(); ++i) {
                        if (string(i->name()) == string(&buf[0])) {
index 0dee2a071bdd4e3ce5035a25589cde25ee5d8009..1a1c5f2becfe8a5a510b5442783b98360c1f5ea4 100644 (file)
@@ -309,11 +309,7 @@ MTC_Slave::update_mtc_time (const MIDI::byte *msg, bool was_full, framepos_t now
           to use a timestamp indicating when this MTC time was received. example: when we received
           a locate command via MMC.
        */
-#ifdef COMPILER_MSVC
-       DEBUG_TRACE (DEBUG::MTC, string_compose ("MTC::update_mtc_time - TID:%1\n", ::pthread_self().p));
-#else
-       DEBUG_TRACE (DEBUG::MTC, string_compose ("MTC::update_mtc_time - TID:%1\n", ::pthread_self()));
-#endif
+       DEBUG_TRACE (DEBUG::MTC, string_compose ("MTC::update_mtc_time - TID:%1\n", pthread_name()));
        TimecodeFormat tc_format;
        bool reset_tc = true;
 
index 2889063ca47f4156500dfd24a07d245427883c93..c400aa6c3bb4471e1617d1b6e7930c867b7ae94f 100644 (file)
@@ -35,14 +35,11 @@ Searchpath
 panner_search_path ()
 {
        Searchpath spath(user_config_directory ());
+
        spath += ardour_dll_directory ();
        spath.add_subdirectory_to_paths(panner_dir_name);
-<<<<<<< HEAD
-       spath += SearchPath(Glib::getenv(panner_env_variable_name));
-=======
-
        spath += Searchpath(Glib::getenv(panner_env_variable_name));
->>>>>>> windows+cc
+
        return spath;
 }
 
index bbd34322052b92b8b74c2684dd035d3a30017437..5c3ffae3cc087c58031b3384bb5e01e2511ec89d 100644 (file)
@@ -136,14 +136,7 @@ Session::pre_engine_init (string fullpath)
 
        /* discover canonical fullpath */
 
-       char buf[PATH_MAX+1];
-       if (!realpath (fullpath.c_str(), buf) && (errno != ENOENT)) {
-               error << string_compose(_("Could not use path %1 (%2)"), buf, strerror(errno)) << endmsg;
-               destroy ();
-               throw failed_constructor();
-       }
-
-       _path = string(buf);
+       _path = canonical_path(fullpath);
        
        /* we require _path to end with a dir separator */
 
diff --git a/libs/ardour/test/audio_engine_test.cc b/libs/ardour/test/audio_engine_test.cc
new file mode 100644 (file)
index 0000000..b992caf
--- /dev/null
@@ -0,0 +1,53 @@
+#include <iostream>
+
+#include "ardour/audioengine.h"
+#include "ardour/audio_backend.h"
+#include "ardour/backend_search_path.h"
+
+#include "audio_engine_test.h"
+#include "test_common.h"
+
+CPPUNIT_TEST_SUITE_REGISTRATION (AudioEngineTest);
+
+using namespace std;
+using namespace ARDOUR;
+using namespace PBD;
+
+void
+print_audio_backend_info (AudioBackendInfo const* abi)
+{
+       cerr << "Audio Backend, name:" << abi->name << endl;
+}
+
+void
+AudioEngineTest::test_backends ()
+{
+       AudioEngine* engine = AudioEngine::create ();
+
+       CPPUNIT_ASSERT (engine);
+
+       std::vector<AudioBackendInfo const *> backends = engine->available_backends ();
+
+       CPPUNIT_ASSERT (backends.size () != 0);
+
+       for (std::vector<AudioBackendInfo const *>::const_iterator i = backends.begin();
+               i != backends.end(); ++i) {
+               print_audio_backend_info(*i);
+       }
+}
+
+void
+AudioEngineTest::test_start ()
+{
+       AudioEngine* engine = AudioEngine::create ();
+
+       CPPUNIT_ASSERT_NO_THROW (engine->set_default_backend ());
+
+       init_post_engine ();
+
+       CPPUNIT_ASSERT (engine->start () == 0);
+
+       // sleep
+       // stop
+       // destroy
+}
diff --git a/libs/ardour/test/audio_engine_test.h b/libs/ardour/test/audio_engine_test.h
new file mode 100644 (file)
index 0000000..9a6d9cc
--- /dev/null
@@ -0,0 +1,14 @@
+#include <cppunit/TestFixture.h>
+#include <cppunit/extensions/HelperMacros.h>
+
+class AudioEngineTest : public CppUnit::TestFixture
+{
+       CPPUNIT_TEST_SUITE (AudioEngineTest);
+       CPPUNIT_TEST (test_backends);
+       CPPUNIT_TEST (test_start);
+       CPPUNIT_TEST_SUITE_END ();
+
+public:
+       void test_backends ();
+       void test_start ();
+};
index 21f745e20bf72f8410f36e53f9b80aa5498a81a8..29efde269360d42c2af8607ff87bc1f94e637c18 100644 (file)
@@ -259,9 +259,6 @@ def configure(conf):
     autowaf.check_pkg(conf, 'sigc++-2.0', uselib_store='SIGCPP',
                       atleast_version='2.0')
 
-    if re.search ("linux", sys.platform) != None:
-        autowaf.check_pkg(conf, 'alsa', uselib_store='ALSA')
-
     if Options.options.lv2:
         autowaf.check_pkg(conf, 'lv2', uselib_store='LV2',
                           atleast_version='1.0.0', mandatory=True)
@@ -445,6 +442,7 @@ def build(bld):
                 testcommon.source += [ 'sse_functions_64bit.s' ]
 
         if bld.env['SINGLE_TESTS']:
+            create_ardour_test_program(bld, obj.includes, 'audio_engine_test', 'test_audio_engine', ['test/audio_engine_test.cc'])
             create_ardour_test_program(bld, obj.includes, 'automation_list_property_test', 'test_automation_list_property', ['test/automation_list_property_test.cc'])
             create_ardour_test_program(bld, obj.includes, 'bbt', 'test_bbt', ['test/bbt_test.cc'])
             create_ardour_test_program(bld, obj.includes, 'tempo', 'test_tempo', ['test/tempo_test.cc'])
@@ -463,6 +461,7 @@ def build(bld):
             create_ardour_test_program(bld, obj.includes, 'session_test', 'test_session', ['test/session_test.cc'])
 
         test_sources  = '''
+            test/audio_engine_test.cc
             test/automation_list_property_test.cc
             test/bbt_test.cc
             test/tempo_test.cc
index 09e6c9d6e7c02d2a4ba5d7c20eac7c6a63339068..fee1b299ba098c5f6123ff856c7ff73978b72453 100644 (file)
@@ -21,6 +21,8 @@
 #include <boost/scoped_ptr.hpp>
 #include <jack/session.h>
 
+#include <glibmm/timer.h>
+
 #include "pbd/epa.h"
 
 #include "jack_connection.h"
@@ -145,7 +147,7 @@ JackConnection::close ()
                _jack = 0;
 
                /* If we started JACK, it will be closing down */
-               usleep (500000);
+               Glib::usleep (500000);
 
                Disconnected (""); /* EMIT SIGNAL */
 
index 7cd7f6c62be0a46fc45acfe2a0b2b6b3d80a983e..60d11a8f0c1e7452f779082522a9241637c45c0f 100644 (file)
@@ -25,6 +25,8 @@
 #include <jack/jack.h>
 #include <jack/transport.h>
 
+#include "pbd/localtime_r.h"
+
 #include "ardour/audioengine.h"
 #include "ardour/filename_extensions.h"
 #include "ardour/session.h"
index 331c164353604000fa672c4776c50209e03d7522..01af13fe9ce91c63ab88b8daf441e37044c21b07 100644 (file)
@@ -891,11 +891,7 @@ ARDOUR::get_jack_command_line_string (JackCommandLineOptions& options, string& c
        ostringstream oss;
 
        for (vector<string>::const_iterator i = args.begin(); i != args.end();) {
-#ifdef WIN32
-               oss << quote_string (*i);
-#else
                oss << *i;
-#endif
                if (++i != args.end()) oss << ' ';
        }
 
index 4e54af0be5194334760bfc4e6e885708e2781546..b31d9b5d56452cd3b6f2e26f5df82cdc1fa74208 100644 (file)
@@ -20,6 +20,8 @@ def options(opt):
     autowaf.set_options(opt)
 
 def configure(conf):
+    autowaf.check_pkg(conf, 'jack', uselib_store='JACK', atleast_version='0.121.0')
+
     #
     # PortAudio is currently used to get a list of audio device names.
     # We should find a better way to do this that doesn't involve this
@@ -43,7 +45,7 @@ def build(bld):
     obj.includes = ['.']
     obj.name     = 'jack_audiobackend'
     obj.target   = 'jack_audiobackend'
-    if Options.options.dist_target == 'mingw':
+    if (bld.env['build_target'] == 'mingw'):
         obj.uselib   = [ 'JACK', 'PORTAUDIO' ]
     else:
         obj.uselib   = [ 'JACK' ]
index c87e1aa1d09690c38c6812bb1dc3c8abf656ca9c..bae2fbe4396f4f07df6fb5f5365e3ddad181ed7e 100644 (file)
@@ -87,7 +87,7 @@ def build(bld):
     if bld.is_defined ('INTERNAL_SHARED_LIBS'):
         obj              = bld.shlib(features = 'c cxx cshlib cxxshlib', source=gtkmm2ext_sources)
         # defines for this library
-        obj.defines      = [ 'LIBGTKMM2EXT_DLL_EXPORTS=1' ]
+        obj.defines      = [ 'LIBGTKMM2EXT_DLL_EXPORTS', 'ABSTRACT_UI_EXPORTS' ]
         obj.cxxflags     = [ '-fvisibility=hidden' ]
         obj.cflags     = [ '-fvisibility=hidden' ]
     else:
index 73bc7e599d3313cdb215ad40824823c65deaf6b3..b12d341366fe8c4ae701ebb845f613535d2be7bf 100644 (file)
@@ -39,11 +39,14 @@ FPU::FPU ()
 
        _flags = Flags (0);
 
+#if defined(__MINGW64__) // Vkamyshniy: under __MINGW64__ the assembler code below is not compiled
+       return;
+#endif
+
 #if !( (defined __x86_64__) || (defined __i386__) ) // !ARCH_X86
        return;
 #else
 
-       
 #ifndef _LP64 //USE_X86_64_ASM
        asm volatile (
                "mov $1, %%eax\n"
index 5784ec942855de3ece0de4e9809333efbb5278e1..26454e4164fc73a3c30b5e8b7bb4c6e99b7d09f1 100644 (file)
 using std::string;
 using std::vector;
 
+#ifdef COMPILER_MINGW
+
+#include <stdlib.h>
+#include <glibmm.h>
+
+/****************************************************************
+ * Emulate POSIX realpath() using Win32 _fullpath() since realpath()
+ * is not available.
+ *
+ * Returns:
+ *    On Success: A pointer to the resolved (absolute) path
+ *    On Failure: 0 (NULL)
+ */
+
+static char* 
+realpath (const char *original_path, char resolved_path[_MAX_PATH+1])
+{
+       char *rpath = 0;
+       bool bIsSymLink = false; // We'll probably need to test the incoming path
+                                // to find out if it points to a Windows shortcut
+                                // (or a hard link) and set this appropriately.
+
+       if (bIsSymLink) {
+               // At the moment I'm not sure if Windows '_fullpath()' is directly
+               // equivalent to POSIX 'realpath()' - in as much as the latter will
+               // resolve the supplied path if it happens to point to a symbolic
+               // link ('_fullpath()' probably DOESN'T do this but I'm not really
+               // sure if Ardour needs such functionality anyway). Therefore we'll
+               // possibly need to add that functionality here at a later date.
+       } else {
+               char temp[(_MAX_PATH+1)*6]; // Allow for maximum length of a path in wchar characters
+               
+               // POSIX 'realpath()' requires that the buffer size is at
+               // least PATH_MAX+1, so assume that the user knew this !!
+
+               rpath = _fullpath (temp, Glib::locale_from_utf8 (original_path).c_str(), _MAX_PATH);
+
+               if (0 != rpath) {
+                       snprintf (resolved_path, _MAX_PATH+1, "%s", Glib::locale_to_utf8 (temp).c_str());
+               }
+                       
+       }
+       
+       return (rpath);
+}
+
+#endif  // COMPILER_MINGW
+
 string
 PBD::canonical_path (const std::string& path)
 {
-#ifdef COMPILER_MINGW
-       return path;
-#else
        char buf[PATH_MAX+1];
 
        if (!realpath (path.c_str(), buf) && (errno != ENOENT)) {
@@ -46,7 +91,6 @@ PBD::canonical_path (const std::string& path)
        }
 
        return string (buf);
-#endif
 }
 
 string
index 1ceefe7b3b7a966b8c17824adc9013488ef723bb..dc5620b2ef76354358862d03e8a1fcd594fb1c42 100644 (file)
@@ -52,7 +52,7 @@
 class Touchable;
 
 template<typename RequestObject>
-class /*ABSTRACT_UI_API*/ AbstractUI : public BaseUI /* see notes in visibility.h about why this is not LIBPBD_API */
+class ABSTRACT_UI_API AbstractUI : public BaseUI
 {
   public:
        AbstractUI (const std::string& name);
@@ -75,7 +75,7 @@ class /*ABSTRACT_UI_API*/ AbstractUI : public BaseUI /* see notes in visibility.
         };
        typedef typename RequestBuffer::rw_vector RequestBufferVector;
 
-#if defined(__MINGW32__)
+#if defined(__MINGW32__) && !defined (__MINGW64__)
 
        struct pthread_cmp
        {
index 8c1f1fdd1e1e13159b4e7615e7e116488b391380..709eb0fd9064f0ee76ec160949a0308a01f3234c 100644 (file)
@@ -34,6 +34,79 @@ def build(bld):
     if bld.is_defined('USE_EXTERNAL_LIBS'):
         return
 
+    # the story: taglib distributes its headers all over the place then copies them
+    # into place during an install. but we're not planning to do an install. so this
+    # doesn't work when code does #include <taglib/foo.h>. 
+    #
+    # one approach is to store symlinks in the repository. but this breaks on windows
+    # where symlink support and git are not very well developed (if at all)
+    #
+    # the approach here is to copy the header files as part of the build step, if necessary
+    
+    headers = [
+        './ape/apefooter.h',
+        './ape/apeitem.h',
+        './ape/apetag.h',
+        './mpeg/id3v2/frames/attachedpictureframe.h',
+        './mpeg/id3v2/frames/commentsframe.h',
+        './flac/flacfile.h',
+        './flac/flacproperties.h',
+        './mpeg/id3v2/frames/generalencapsulatedobjectframe.h',
+        './mpeg/id3v1/id3v1genres.h',
+        './mpeg/id3v1/id3v1tag.h',
+        './mpeg/id3v2/id3v2extendedheader.h',
+        './mpeg/id3v2/id3v2footer.h',
+        './mpeg/id3v2/id3v2framefactory.h',
+        './mpeg/id3v2/id3v2frame.h',
+        './mpeg/id3v2/id3v2header.h',
+        './mpeg/id3v2/id3v2synchdata.h',
+        './mpeg/id3v2/id3v2tag.h',
+        './mpc/mpcfile.h',
+        './mpc/mpcproperties.h',
+        './mpeg/mpegfile.h',
+        './mpeg/mpegheader.h',
+        './mpeg/mpegproperties.h',
+        './ogg/oggfile.h',
+        './ogg/flac/oggflacfile.h',
+        './ogg/oggpage.h',
+        './ogg/oggpageheader.h',
+        './mpeg/id3v2/frames/relativevolumeframe.h',
+        './ogg/speex/speexfile.h',
+        './ogg/speex/speexproperties.h',
+        './toolkit/taglib.h',
+        './toolkit/tbytevector.h',
+        './toolkit/tbytevectorlist.h',
+        './toolkit/tdebug.h',
+        './mpeg/id3v2/frames/textidentificationframe.h',
+        './toolkit/tfile.h',
+        './toolkit/tlist.h',
+        'toolkit/tlist.tcc',
+        './toolkit/tmap.h',
+        'toolkit/tmap.tcc',
+        './trueaudio/trueaudiofile.h',
+        './trueaudio/trueaudioproperties.h',
+        './toolkit/tstring.h',
+        './toolkit/tstringlist.h',
+        './toolkit/unicode.h',
+        './mpeg/id3v2/frames/uniquefileidentifierframe.h',
+        './mpeg/id3v2/frames/unknownframe.h',
+        './mpeg/id3v2/frames/unsynchronizedlyricsframe.h',
+        './mpeg/id3v2/frames/urllinkframe.h',
+        './ogg/vorbis/vorbisfile.h',
+        './ogg/vorbis/vorbisproperties.h',
+        './wavpack/wavpackfile.h',
+        './wavpack/wavpackproperties.h',
+        './mpeg/xingheader.h',
+        './ogg/xiphcomment.h',
+        ]
+
+    for h in headers:
+        tgt = bld.path.get_bld().make_node (os.path.join ('taglib', os.path.basename (h)))
+        if not os.path.exists (tgt.bldpath()):
+            bld (rule = autowaf.copyfile,
+                 source = bld.path.make_node (os.path.join ('taglib', h)),
+                 target = tgt)
+
     # Library
     obj = bld(features = 'cxx cxxshlib')
     sources = bld.path.ant_glob('taglib/*.cpp')
@@ -69,7 +142,7 @@ def build(bld):
             taglib/ogg/speex
             taglib/ogg/flac
     '''.split()
-    obj.export_includes = ['.', 'taglib', 'taglib/toolkit']
+    obj.export_includes = ['.', 'taglib' ]
     obj.includes     = include_dirs
     obj.defines      = ['MAKE_TAGLIB_LIB']
     obj.name         = 'libtaglib'
index 87e19d5aea210b30dbf12ee52614a847fab8495f..e97c555362449f066b39211b96ee8bfd40256aeb 100644 (file)
@@ -10,6 +10,7 @@ import glob
 import os
 import subprocess
 import sys
+import shutil
 
 from waflib import Configure, Context, Logs, Node, Options, Task, Utils
 from waflib.TaskGen import feature, before, after
@@ -91,6 +92,12 @@ def set_options(opt, debug_by_default=False):
                             help="LV2 bundles [Default: LIBDIR/lv2]")
     g_step = 1
 
+def copyfile (task):
+    # a cross-platform utility for copying files as part of tasks
+    src = task.inputs[0].abspath()
+    tgt = task.outputs[0].abspath()
+    shutil.copy2 (src, tgt)
+
 def check_header(conf, lang, name, define='', mandatory=True):
     "Check for a header"
     includes = '' # search default system include paths
diff --git a/tools/windows_packaging/Fedora-16-mingw.txt b/tools/windows_packaging/Fedora-16-mingw.txt
deleted file mode 100644 (file)
index 23c9a74..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-
-Fedora Packages are installed via $ yum install foobar
-
-wine, needed to run some tests during the configure process
-
-mingw32-gcc
-
-mingw32-libogg
-
-mingw32-flac not in repo <- requires libogg
-
-mingw32-libvorbis
-
-mingw32-libsndfile not in repo <- requires flac, vorbis
-mingw32-libsamplerate not in repo <- requires sndfile for examples?
-
-mingw32-gtkmm24, this will pull in all the gtk+ deps etc
-
-mingw32-gtk2-engines not in repo <- provides clearlooks
-
-mingw32-libglade2, required for gnomecanvas 
-
-mingw32-libart_lgpl not in repo
-mingw32-libgnomecanvas not in repo <- requires libart, libglade2
-mingw32-libgnomecanvasmm not in repo <- requires
-
-mingw32-portaudio not in repo
-
-mingw32-jack-audio-connection-kit not in repo
-
-mingw32-fftw not in repo
-
-mingw32-curl
-
-Optional
-
-mingw32-cppunit, if tests enabled
-mingw32-gdb, for debugging
-
-qemu-kvm to run virt images
-
index cb01c5675f5b218f16c8aaa1e20c2854d2597168..4a766685c5d216330f67e75b8b1b4f432bf9736b 100644 (file)
@@ -1,15 +1,15 @@
 Building Ardour for Windows
 
 The windows build is compiled and tested with the MinGW compiler that is
-packaged in Fedora, Currently using Fedora 16. There are many cross compiled
-"mingw" libraries that Ardour requires that are also available on Fedora but
+packaged in Fedora, Currently using Fedora 19. There are many cross compiled
+"mingw" libraries that Ardour requires that are available on Fedora but
 not all are yet.
 
 
 Prerequisites
 
-Follow instructions in Fedora-16.txt to build and/or install the required
-packages.
+For setting up the required packages to build Ardour refer to the README
+file located at https://github.com/mojofunk/fedora-mingw-ardour
 
 
 Configuring
@@ -28,6 +28,8 @@ These scripts both source the mingw-env.sh script to setup the appropriate
 environment variables and then call waf with a specific set of parameters
 that are appropriate to configure for the windows build.
 
+There is also configure-distcc-debug.sh and configure-distcc-release.sh that
+configure to use distcc for building.
 
 Building
 
@@ -44,6 +46,14 @@ windows executable. This could probably be done in the waf scripts specifically
 for the windows build but I felt it simpler to do it in the packaging script
 for now.
 
+--------- NOTE --------------------
+
+package_win32.sh is an updated/extended version of package.sh from Valeriy. It
+should probably be merged with package.sh at some point. It uses a number of
+additional resources located under mingw64/
+
+-----------------------------------
+
 The packaging script then copies the JACK deamon and all the required mingw
 shared libraries from the host system into the packaging directory. The 
 shared libraries or dll's are placed in the same directory as the Ardour
@@ -73,8 +83,8 @@ in a separate terminal(Command Prompt) before starting Ardour so that they are
 not both writing to the same terminal. This will probably be fixed at some point
 so when jackd is started by Ardour the output is redirected etc.
 
-The cptovm.sh and startvm.sh scripts are intended for testing Ardour in a 
-Windows XP virt image and may need to be altered to be used successfully.
+The cptovmshare.sh script will copy the package to a directory specified in the
+ARDOUR_VM_SHARE_DIR for testing in a virtual machine.
 
 
 Testing
@@ -82,6 +92,8 @@ Testing
 When configured for debugging there are a number of test programs(prefixed with
 test_) included in the package.
 
+The tests for libpbd, libevoral and libardour can be run under wine from the
+windows packaging directory using the wine-*-tests.sh scripts
 
 Debugging
 
@@ -92,17 +104,43 @@ When configured for debugging the package contains gdb along with a .gdbinit
 file to automatically set the source directory so that the "list" gdb command
 will show the source code corresponding to the current stack frame.
 
-Use break `Somenamespace::somepartialsymbolname + tab to list symbols, then remove 
-` to set break. If you press tab with when there are thousands of possible
-matching symbols be prepared to wait a long time(this can also cause gdb to use a
-lot of memory).
+New versions of gdb will not load a .gdbinit file unless it is located in the directory
+set in the HOME environment variable and auto-load safe-path is set appropriately.
+
+So the gdbinit_home file needs to be moved to directory set in %USERPROFILE% and
+gdb started via gdb.bat for source file listing to work.
+
+The gdb batch scripts cannot be used if the package directory is on a network share
+so the package will need to be copied to a local drive first.
+
+When starting gdb using gdb.bat the Ardour executable needs to be set as the program
+to be debugged with the "file" command
+
+e.g (gdb) file ardour-3.5.exe
+
+You can then set a break point at main() with the "break" command as usual
+
+e.g (gdb) break main
+
+To set a breakpoint in a dll/shared library like libardour you need to wait for
+the symbols to be loaded which only occurs once the program has been executed using
+the "run" command
+
+You can set a breakpoint at a function
+
+e.g break `Somenamespace::somepartialsymbolname + tab to list symbols
+
+then remove ` to set the breakpoint.
 
-For reasons I've yet to determine many symbols are not accessible so the best way
-to set a breakpoint is by using filename and line number.
+If you press tab with when there are thousands of possible matching symbols be
+prepared to wait a long time(this can also cause gdb to use a lot of memory).
+For this reason I prefer to set breakpoints by specifying the source file and line
+number.
 
 e.g (gdb) break audiosource.cc:976
 
-but this seems to only work after running Ardour at least once.
+using "catch throw" or "catch catch" can be useful to break at points where exceptions
+are thrown or caught.
 
 They are a number of glib debugging options see
 
diff --git a/tools/windows_packaging/configure-distcc-debug.sh b/tools/windows_packaging/configure-distcc-debug.sh
new file mode 100755 (executable)
index 0000000..501e849
--- /dev/null
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+. ./mingw-env.sh
+
+export CC="distcc $HOST-gcc"
+export CPP="distcc $HOST-g++"
+export CXX="distcc $HOST-g++"
+
+. ./print-env.sh
+
+cd $BASE || exit 1
+./waf configure --prefix="/" --bindir="/" --configdir="/share" --noconfirm --no-lv2 --test --single-tests --dist-target=mingw "$@"
diff --git a/tools/windows_packaging/configure-distcc-release.sh b/tools/windows_packaging/configure-distcc-release.sh
new file mode 100755 (executable)
index 0000000..19cabf9
--- /dev/null
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+. ./mingw-env.sh
+
+export CC="distcc $HOST-gcc"
+export CPP="distcc $HOST-g++"
+export CXX="distcc $HOST-g++"
+
+. ./print-env.sh
+
+cd $BASE || exit 1
+./waf configure --prefix="/" --bindir="/" --configdir="/share" --optimize --noconfirm --no-lv2 --dist-target=mingw "$@"
diff --git a/tools/windows_packaging/cptovm.sh b/tools/windows_packaging/cptovm.sh
deleted file mode 100755 (executable)
index 62e6fd6..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-#!/bin/bash
-
-. ./mingw-env.sh
-
-TMP_DIR=tmp
-LOOP_DEV=/dev/loop4
-
-cd $BASE || exit 1
-
-if [ ! -d $TMP_DIR ]; then
-       echo "Creating temp directory to mount vm image ..."
-       mkdir $TMP_DIR || exit 1
-fi
-
-echo "mounting vm image as loopback device ..."
-
-sudo mount -o loop=$LOOP_DEV,offset=32256 $VIRT_IMAGE_PATH $TMP_DIR || exit 1
-
-if [ -d $TMP_DIR/$PACKAGE_DIR ]; then
-       echo "Removing old copy of $PACKAGE_DIR from vm image ..."
-       rm -rf $TMP_DIR/$PACKAGE_DIR || exit 1
-fi
-
-echo "Copying $PACKAGE_DIR to vm image ..."
-cp -r $PACKAGE_DIR $TMP_DIR || exit 1
-
-if [ "$1" == "--data" ]; then
-       DATA_DIR=data
-
-       if [ -d $TMP_DIR/$DATA_DIR ]; then
-               echo "Removing old copy of $DATA_DIR from vm image ..."
-               rm -rf $TMP_DIR/$DATA_DIR || exit 1
-       fi
-
-       echo "Copying $DATA_DIR to vm image ..."
-       cp -r $DATA_DIR $TMP_DIR || exit 1
-fi
-
-
-# in case mount is busy
-sleep 2
-
-echo "Unmounting vm image ..."
-
-sudo umount -d tmp
-
-echo "Removing temp directory used to mount vm image ..."
-rm -rf $TMP_DIR || exit 1
-
-if sudo losetup $LOOP_DEV; then
-       echo "sleeping for 10 seconds and trying again ..."
-       sleep 10
-       if sudo losetup -d $LOOP_DEV; then
-               echo "Unmounted loopback device successfully"
-               exit 0
-       else:
-               echo "Unmounting loopback device unsuccessful, you will need to use losetup -d to unmount device"
-               exit 1
-       fi
-fi
-
-exit 0
diff --git a/tools/windows_packaging/cptovmshare.sh b/tools/windows_packaging/cptovmshare.sh
new file mode 100755 (executable)
index 0000000..f447f57
--- /dev/null
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./mingw-env.sh
+
+cd $BASE || exit 1
+
+if [ -z $ARDOUR_VM_SHARE_DIR ]
+then
+       echo "You must set ARDOUR_VM_SHARE_DIR in your environment to use this script!"
+       exit 1
+fi
+
+if [ -d $ARDOUR_VM_SHARE_DIR/$PACKAGE_DIR ]; then
+       echo "Removing $PACKAGE_DIR from vm share directory ..."
+       rm -rf $ARDOUR_VM_SHARE_DIR/$PACKAGE_DIR || exit 1
+fi
+
+echo "Copying $PACKAGE_DIR to vm share directory $ARDOUR_VM_SHARE_DIR ..."
+cp -r $PACKAGE_DIR $ARDOUR_VM_SHARE_DIR || exit 1
diff --git a/tools/windows_packaging/gdb-ardour.bat b/tools/windows_packaging/gdb-ardour.bat
new file mode 100644 (file)
index 0000000..7d290b0
--- /dev/null
@@ -0,0 +1,4 @@
+set HOME=%USERPROFILE%\r
+echo "set home to %HOME%"\r
+\r
+START gdb.exe ardour-3.3.exe\r
diff --git a/tools/windows_packaging/gdb.bat b/tools/windows_packaging/gdb.bat
new file mode 100644 (file)
index 0000000..90f586b
--- /dev/null
@@ -0,0 +1,4 @@
+set HOME=%USERPROFILE%\r
+echo "set home to %HOME%"\r
+\r
+START gdb.exe\r
diff --git a/tools/windows_packaging/gdbinit_home b/tools/windows_packaging/gdbinit_home
new file mode 100644 (file)
index 0000000..910710c
--- /dev/null
@@ -0,0 +1 @@
+set auto-load safe-path /
index 616f89af5e05ef3f843d9946f63a4ed077c2bdef..983e6d0b9b382091a7f30d0270e515fbd7b5ec75 100755 (executable)
@@ -26,19 +26,18 @@ BUILD_DIR=$BASE/build
 BUILD_CACHE_FILE=$BUILD_DIR/c4che/_cache.py
 TOOLS_DIR=$BASE/tools/windows_packaging
 
-. ../define_versions.sh
-
 APPNAME=`grep -m 1 '^APPNAME' $BASE/wscript | awk '{print $3}' | sed "s/'//g"`
 
 # These are only relevant after a build
 if test -f $BUILD_CACHE_FILE
 then
+        . ../define_versions.sh
+
        # Figure out the Build Type
-       if grep -q "DEBUG = True" $BUILD_CACHE_FILE; then
-               DEBUG=1
-               PACKAGE_DIR="$APPNAME-${version}-win32-dbg"
+       if [ x$DEBUG = xT ]; then
+               PACKAGE_DIR="$APPNAME-${release_version}-win32-dbg"
        else
-               PACKAGE_DIR="$APPNAME-${version}-win32"
+               PACKAGE_DIR="$APPNAME-${release_version}-win32"
        fi
 
        if grep -q "BUILD_TESTS = True" $BUILD_CACHE_FILE; then
@@ -47,6 +46,3 @@ then
 
        ARDOUR_DATA_DIR=$PACKAGE_DIR/share/ardour3
 fi
-
-# put this somewhere better...
-VIRT_IMAGE_PATH=$HOME/Data/virt-images/winxp.raw
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-autohint.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-autohint.conf
new file mode 100644 (file)
index 0000000..c597bf4
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Use the Autohinter --> 
+  <match target="font">
+    <edit name="autohint" mode="assign"><bool>true</bool></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-no-sub-pixel.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-no-sub-pixel.conf
new file mode 100644 (file)
index 0000000..87ada4e
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Enable sub-pixel rendering --> 
+  <match target="font">
+    <edit name="rgba" mode="assign"><const>none</const></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-bgr.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-bgr.conf
new file mode 100644 (file)
index 0000000..e1f64fd
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Enable sub-pixel rendering --> 
+  <match target="font">
+    <edit name="rgba" mode="assign"><const>bgr</const></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-rgb.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-rgb.conf
new file mode 100644 (file)
index 0000000..2b49fe3
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Enable sub-pixel rendering --> 
+  <match target="font">
+    <edit name="rgba" mode="assign"><const>rgb</const></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-vbgr.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-vbgr.conf
new file mode 100644 (file)
index 0000000..5947650
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Enable sub-pixel rendering --> 
+  <match target="font">
+    <edit name="rgba" mode="assign"><const>vbgr</const></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-vrgb.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-sub-pixel-vrgb.conf
new file mode 100644 (file)
index 0000000..84481bd
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Enable sub-pixel rendering --> 
+  <match target="font">
+    <edit name="rgba" mode="assign"><const>vrgb</const></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/10-unhinted.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/10-unhinted.conf
new file mode 100644 (file)
index 0000000..025ae2a
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--  Disable hinting --> 
+  <match target="font">
+    <edit name="hinting" mode="assign"><bool>false</bool></edit>
+  </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/20-fix-globaladvance.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/20-fix-globaladvance.conf
new file mode 100644 (file)
index 0000000..2a9c063
--- /dev/null
@@ -0,0 +1,28 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  Some Asian fonts misadvertise themselves as monospaced when
+  in fact they are dual-spaced (half and full).  This makes
+  FreeType very confused as it forces all widths to match.
+  Undo this magic by disabling the width forcing code -->
+       <match target="font">
+               <test name="family"><string>GulimChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+
+       <match target="font">
+               <test name="family"><string>DotumChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+
+       <match target="font">
+               <test name="family"><string>BatangChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+
+       <match target="font">
+               <test name="family"><string>GungsuhChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/20-unhint-small-vera.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/20-unhint-small-vera.conf
new file mode 100644 (file)
index 0000000..c4ebee9
--- /dev/null
@@ -0,0 +1,48 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- 
+       The Bitstream Vera fonts have GASP entries suggesting that hinting be
+       disabled below 8 ppem, but FreeType ignores those, preferring to use
+       the data found in the instructed hints.  The initial Vera release
+       didn't include the right instructions in the 'prep' table. Fix this
+       by disabling hinting manually at smaller sizes (< 8ppem)
+ -->
+
+       <match target="font">
+               <test name="family">
+                       <string>Bitstream Vera Sans</string>
+               </test>
+               <test name="pixelsize" compare="less">
+                       <double>7.5</double>
+               </test>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+       <match target="font">
+               <test name="family">
+                       <string>Bitstream Vera Serif</string>
+               </test>
+               <test name="pixelsize" compare="less">
+                       <double>7.5</double>
+               </test>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+       <match target="font">
+               <test name="family">
+                       <string>Bitstream Vera Sans Mono</string>
+               </test>
+               <test name="pixelsize" compare="less">
+                       <double>7.5</double>
+               </test>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/25-unhint-nonlatin.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/25-unhint-nonlatin.conf
new file mode 100644 (file)
index 0000000..ffb70c6
--- /dev/null
@@ -0,0 +1,128 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+
+<!-- We can't hint CJK fonts well, so turn off hinting for CJK fonts. -->
+
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Kochi Mincho</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Kochi Gothic</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Sazanami Mincho</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Sazanami Gothic</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Baekmuk Batang</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Baekmuk Dotum</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Baekmuk Gulim</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>Baekmuk Headline</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>AR PL Mingti2L Big5</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>AR PL ShanHeiSun Uni</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>AR PL KaitiM Big5</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>AR PL ZenKai Uni</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>AR PL SungtiL GB</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>AR PL KaitiM GB</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+       <match target="font">
+               <test name="family" compare="eq">
+                       <string>ZYSong18030</string>
+               </test>
+               <edit name="hinting" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/30-metric-aliases.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/30-metric-aliases.conf
new file mode 100644 (file)
index 0000000..702a495
--- /dev/null
@@ -0,0 +1,211 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+
+       <!-- Alias similar/metric-compatible families from various sources:
+
+               PostScript fonts:
+                       Helvetica
+                       Times
+                       Courier
+               URW fonts:
+                       Nimbus Sans L
+                       Nimbus Roman No9 L
+                       Nimbus Mono L
+
+               Microsoft fonts:
+                       Arial
+                       Times New Roman
+                       Courier New
+               Liberation fonts:
+                       Liberation Sans
+                       Liberation Serif
+                       Liberation Mono
+               StarOffice fonts:
+                       Albany
+                       Thorndale
+                       Cumberland
+               AMT fonts:
+                       Albany AMT
+                       Thorndale AMT
+                       Cumberland AMT
+
+            Of these, URW fonts are design compatible with PostScrict fonts,
+            and the Liberation, StarOffice, and AMT ones are compatible with
+            Microsoft fonts.
+
+            We want for each of them to fallback to any of these
+            available, but in an order preferring similar designs
+            first.  We do this in three steps:
+
+               1) Alias each specific to it's generic family.
+                  eg. Liberation Sans to Arial
+
+               2) Weak alias each generic to the other generic of its family.
+                  eg. Arial to Helvetica
+
+               3) Alias each generic to its specifics.
+                  eg. Arial to Liberation Sans, Albany, and Albany AMT
+       -->
+
+<!-- Map specifics to generics -->
+
+       <!-- PostScript -->
+       <alias binding="same">
+         <family>Nimbus Sans L</family>
+         <default>
+         <family>Helvetica</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Nimbus Roman No9 L</family>
+         <default>
+         <family>Times</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Nimbus Mono L</family>
+         <default>
+         <family>Courier</family>
+         </default>
+       </alias>
+
+
+       <!-- Microsoft -->
+       <alias binding="same">
+         <family>Liberation Sans</family>
+         <family>Albany</family>
+         <family>Albany AMT</family>
+         <default>
+         <family>Arial</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Liberation Serif</family>
+         <family>Thorndale</family>
+         <family>Thorndale AMT</family>
+         <default>
+         <family>Times New Roman</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Liberation Mono</family>
+         <family>Cumberland</family>
+         <family>Cumberland AMT</family>
+         <default>
+         <family>Courier New</family>
+         </default>
+       </alias>
+
+
+
+<!-- Accept the other group as fallback -->
+
+
+       <!-- PostScript -->
+       <alias>
+         <family>Helvetica</family>
+         <default>
+         <family>Arial</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Times</family>
+         <default>
+         <family>Times New Roman</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Courier</family>
+         <default>
+         <family>Courier New</family>
+         </default>
+       </alias>
+
+
+       <!-- Microsoft -->
+       <alias>
+         <family>Arial</family>
+         <default>
+         <family>Helvetica</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Times New Roman</family>
+         <default>
+         <family>Times</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Courier New</family>
+         <default>
+         <family>Courier</family>
+         </default>
+       </alias>
+
+
+
+<!-- Map generics to specifics -->
+
+
+       <!-- PostScript -->
+       <alias binding="same">
+         <family>Helvetica</family>
+         <accept>
+         <family>Nimbus Sans L</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Times</family>
+         <accept>
+         <family>Nimbus Roman No9 L</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Courier</family>
+         <accept>
+         <family>Nimbus Mono L</family>
+         </accept>
+       </alias>
+
+
+       <!-- Microsoft -->
+       <alias binding="same">
+         <family>Arial</family>
+         <accept>
+         <family>Liberation Sans</family>
+         <family>Albany</family>
+         <family>Albany AMT</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Times New Roman</family>
+         <accept>
+         <family>Liberation Serif</family>
+         <family>Thorndale</family>
+         <family>Thorndale AMT</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Courier New</family>
+         <accept>
+         <family>Liberation Mono</family>
+         <family>Cumberland</family>
+         <family>Cumberland AMT</family>
+         </accept>
+       </alias>
+
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/30-urw-aliases.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/30-urw-aliases.conf
new file mode 100644 (file)
index 0000000..9d59203
--- /dev/null
@@ -0,0 +1,40 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  URW provides metric and shape compatible fonts for some Adobe families.
+  Helvetica, Courier, and Times are handled in 30-metric-aliases.conf.
+  -->
+       <alias binding="same">
+         <family>Avant Garde</family>
+         <accept><family>URW Gothic L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Bookman</family>
+         <accept><family>URW Bookman L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>New Century Schoolbook</family>
+         <accept><family>Century Schoolbook L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Palatino</family>
+         <accept><family>URW Palladio L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Zapf Chancery</family>
+         <accept><family>URW Chancery L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Zapf Dingbats</family>
+         <accept><family>Dingbats</family></accept>
+       </alias>
+       <match target="pattern">
+         <test name="family">
+           <string>Symbol</string>
+         </test>
+         <edit name="family" mode="append" binding="same">
+           <string>Standard Symbols L</string>
+         </edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/40-nonlatin.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/40-nonlatin.conf
new file mode 100644 (file)
index 0000000..a875db0
--- /dev/null
@@ -0,0 +1,90 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  Mark common families with their generics so we'll get
+  something reasonable
+-->
+
+<!--
+  Serif faces
+ -->
+       <alias>
+               <family>Nazli</family>
+               <family>Lotoos</family>
+               <family>Mitra</family>
+               <family>Ferdosi</family>
+               <family>Badr</family>
+               <family>Zar</family>
+               <family>Titr</family>
+               <family>Jadid</family>
+               <family>Kochi Mincho</family>
+               <family>AR PL SungtiL GB</family>
+               <family>AR PL Mingti2L Big5</family>
+               <family>MS 明朝</family>
+               <family>UnBatang</family>
+               <family>Baekmuk Batang</family>
+               <family>MgOpen Canonica</family>
+               <family>Sazanami Mincho</family>
+               <family>AR PL ZenKai Uni</family>
+               <family>ZYSong18030</family>
+               <family>FreeSerif</family>
+               <default><family>serif</family></default>
+       </alias>
+<!--
+  Sans-serif faces
+ -->
+       <alias>
+               <family>Arshia</family>
+               <family>Elham</family>
+               <family>Farnaz</family>
+               <family>Nasim</family>
+               <family>Sina</family>
+               <family>Roya</family>
+               <family>Koodak</family>
+               <family>Terafik</family>
+               <family>Kochi Gothic</family>
+               <family>AR PL KaitiM GB</family>
+               <family>AR PL KaitiM Big5</family>
+               <family>MS ゴシック</family>
+               <family>UnDotum</family>
+               <family>Baekmuk Dotum</family>
+               <family>SimSun</family>
+               <family>MgOpen Modata</family>
+               <family>Sazanami Gothic</family>
+               <family>AR PL ShanHeiSun Uni</family>
+               <family>ZYSong18030</family>
+               <family>FreeSans</family>
+               <default><family>sans-serif</family></default>
+       </alias>
+<!--
+  Monospace faces
+ -->
+       <alias>
+               <family>NSimSun</family>
+               <family>ZYSong18030</family>
+               <family>FreeMono</family>
+               <default><family>monospace</family></default>
+       </alias>
+
+<!--
+  Fantasy faces
+ -->
+       <alias>
+               <family>Homa</family>
+               <family>Kamran</family>
+               <family>Fantezi</family>
+               <family>Tabassom</family>
+               <default><family>fantasy</family></default>
+       </alias>
+
+<!--
+  Cursive faces
+ -->
+       <alias>
+               <family>IranNastaliq</family>
+               <family>Nafees Nastaleeq</family>
+               <default><family>cursive</family></default>
+       </alias>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/45-latin.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/45-latin.conf
new file mode 100644 (file)
index 0000000..7e41264
--- /dev/null
@@ -0,0 +1,77 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  Mark common families with their generics so we'll get
+  something reasonable
+-->
+
+<!--
+  Serif faces
+ -->
+       <alias>
+               <family>Bitstream Vera Serif</family>
+               <family>DejaVu Serif</family>
+               <family>Liberation Serif</family>
+               <family>Times New Roman</family>
+               <family>Times</family>
+               <family>Nimbus Roman No9 L</family>
+               <family>Luxi Serif</family>
+               <family>Thorndale AMT</family>
+               <family>Thorndale</family>
+               <default><family>serif</family></default>
+       </alias>
+<!--
+  Sans-serif faces
+ -->
+       <alias>
+               <family>Bitstream Vera Sans</family>
+               <family>DejaVu Sans</family>
+               <family>Liberation Sans</family>
+               <family>Arial</family>
+               <family>Helvetica</family>
+               <family>Verdana</family>
+               <family>Albany AMT</family>
+               <family>Albany</family>
+               <family>Nimbus Sans L</family>
+               <family>Luxi Sans</family>
+               <default><family>sans-serif</family></default>
+       </alias>
+<!--
+  Monospace faces
+ -->
+       <alias>
+               <family>Bitstream Vera Sans Mono</family>
+               <family>DejaVu Sans Mono</family>
+               <family>Liberation Mono</family>
+               <family>Inconsolata</family>
+               <family>Courier New</family>
+               <family>Courier</family>
+               <family>Andale Mono</family>
+               <family>Luxi Mono</family>
+               <family>Cumberland AMT</family>
+               <family>Cumberland</family>
+               <family>Nimbus Mono L</family>
+               <default><family>monospace</family></default>
+       </alias>
+<!--
+  Fantasy faces
+ -->
+       <alias>
+               <family>Impact</family>
+               <family>Copperplate Gothic Std</family>
+               <family>Cooper Std</family>
+               <family>Bauhaus Std</family>
+               <default><family>fantasy</family></default>
+       </alias>
+<!--
+  Cursive faces
+  -->
+       <alias>
+               <family>ITC Zapf Chancery Std</family>
+               <family>Zapfino</family>
+               <family>Comic Sans MS</family>
+               <default><family>cursive</family></default>
+       </alias>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/49-sansserif.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/49-sansserif.conf
new file mode 100644 (file)
index 0000000..c6209a7
--- /dev/null
@@ -0,0 +1,21 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  If the font still has no generic name, add sans-serif
+ -->
+       <match target="pattern">
+               <test qual="all" name="family" compare="not_eq">
+                       <string>sans-serif</string>
+               </test>
+               <test qual="all" name="family" compare="not_eq">
+                       <string>serif</string>
+               </test>
+               <test qual="all" name="family" compare="not_eq">
+                       <string>monospace</string>
+               </test>
+               <edit name="family" mode="append_last">
+                       <string>sans-serif</string>
+               </edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/50-user.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/50-user.conf
new file mode 100644 (file)
index 0000000..3f89012
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <!-- Load per-user customization file -->
+       <include ignore_missing="yes">~/.fonts.conf.d</include>
+       <include ignore_missing="yes">~/.fonts.conf</include>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/51-local.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/51-local.conf
new file mode 100644 (file)
index 0000000..ca9fbe1
--- /dev/null
@@ -0,0 +1,6 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <!-- Load local system customization file -->
+       <include ignore_missing="yes">local.conf</include>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/60-latin.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/60-latin.conf
new file mode 100644 (file)
index 0000000..2107e31
--- /dev/null
@@ -0,0 +1,70 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>Bitstream Vera Serif</family>
+                       <family>DejaVu Serif</family>
+                       <family>Times New Roman</family>
+                       <family>Thorndale AMT</family>
+                       <family>Luxi Serif</family>
+                       <family>Nimbus Roman No9 L</family>
+                       <family>Times</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>Bitstream Vera Sans</family>
+                       <family>DejaVu Sans</family>
+                       <family>Verdana</family>
+                       <family>Arial</family>
+                       <family>Albany AMT</family>
+                       <family>Luxi Sans</family>
+                       <family>Nimbus Sans L</family>
+                       <family>Helvetica</family>
+                       <family>Lucida Sans Unicode</family>
+                       <family>BPG Glaho International</family> <!-- lat,cyr,arab,geor -->
+                       <family>Tahoma</family> <!-- lat,cyr,greek,heb,arab,thai -->
+               </prefer>
+       </alias>
+       <alias>
+               <family>monospace</family>
+               <prefer>
+                       <family>Bitstream Vera Sans Mono</family>
+                       <family>DejaVu Sans Mono</family>
+                       <family>Inconsolata</family>
+                       <family>Andale Mono</family>
+                       <family>Courier New</family>
+                       <family>Cumberland AMT</family>
+                       <family>Luxi Mono</family>
+                       <family>Nimbus Mono L</family>
+                       <family>Courier</family>
+               </prefer>
+       </alias>
+<!--
+  Fantasy faces
+ -->
+       <alias>
+               <family>fantasy</family>
+               <prefer>
+                       <family>Impact</family>
+                       <family>Copperplate Gothic Std</family>
+                       <family>Cooper Std</family>
+                       <family>Bauhaus Std</family>
+               </prefer>
+       </alias>
+<!--
+  Cursive faces
+  -->
+       <alias>
+               <family>cursive</family>
+               <prefer>
+                       <family>ITC Zapf Chancery Std</family>
+                       <family>Zapfino</family>
+                       <family>Comic Sans MS</family>
+               </prefer>
+       </alias>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/65-fonts-persian.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/65-fonts-persian.conf
new file mode 100644 (file)
index 0000000..0033675
--- /dev/null
@@ -0,0 +1,419 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<!--
+  fonts-persian.conf
+  To configure Persian fonts from The FarsiWeb Project.
+
+  Copyright (C) 2005  Sharif FarsiWeb, Inc. <license@farsiweb.info>
+
+  Permission to use, copy, modify, distribute, and sell this software and its
+  documentation for any purpose is hereby granted without fee, provided that
+  the above copyright notice appear in all copies and that both that
+  copyright notice and this permission notice appear in supporting
+  documentation, and that the name of Sharif FarsiWeb, Inc. not be used in
+  advertising or publicity pertaining to distribution of the software without
+  specific, written prior permission.  Sharif FarsiWeb, Inc. makes no
+  representations about the suitability of this software for any purpose.  It
+  is provided "as is" without express or implied warranty.
+
+  SHARIF FARSIWEB, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+  EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+  PERFORMANCE OF THIS SOFTWARE.
+
+  ChangeLog:
+    2005-04-03  Behdad Esfahbod:  Initial revision.
+    2005-10-09  Behdad Esfahbod:  Turned off back-slant and Tahoma sections.
+    2005-11-30  Behdad Esfahbod:  Set Titr susbtitution size to 24 points.
+    2008       Behdad Esfahbod:  Cleanup.  Add fantasy and cursive.
+  -->
+<fontconfig>
+
+
+<!-- Deprecated fonts are discouraged -->
+
+       <!-- Nesf[2] is officially deprecated and has problematic tables -->
+       <alias binding="same">
+         <family>Nesf</family>
+         <accept><family>Nesf2</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Nesf2</family>
+         <accept><family>Persian_sansserif_default</family></accept>
+       </alias>
+
+<!-- Name changes and spelling variant aliases -->
+
+       <alias binding="same">
+         <family>Nazanin</family>
+         <accept><family>Nazli</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Lotus</family>
+         <accept><family>Lotoos</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Yaqut</family>
+         <accept><family>Yaghoot</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Yaghut</family>
+         <accept><family>Yaghoot</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Traffic</family>
+         <accept><family>Terafik</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Ferdowsi</family>
+         <accept><family>Ferdosi</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Fantezy</family>
+         <accept><family>Fantezi</family></accept>
+       </alias>
+
+
+<!-- Classify fonts. -->
+
+       <!-- Persian_title class -->
+       <alias binding="same">
+         <family>Jadid</family>
+         <accept><family>Persian_title</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Titr</family>
+         <accept><family>Persian_title</family></accept>
+       </alias>
+
+       <!-- Persian_fantasy class -->
+       <alias binding="same">
+         <family>Kamran</family>
+         <accept>
+         <family>Persian_fantasy</family>
+         <family>Homa</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Homa</family>
+         <accept>
+         <family>Persian_fantasy</family>
+         <family>Kamran</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Fantezi</family>
+         <accept><family>Persian_fantasy</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Tabassom</family>
+         <accept><family>Persian_fantasy</family></accept>
+       </alias>
+
+       <!-- Persian_square class -->
+       <alias binding="same">
+         <family>Arshia</family>
+         <accept><family>Persian_square</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Nasim</family>
+         <accept><family>Persian_square</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Elham</family>
+         <accept>
+         <family>Persian_square</family>
+         <family>Farnaz</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Farnaz</family>
+         <accept>
+         <family>Persian_square</family>
+         <family>Elham</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Sina</family>
+         <accept><family>Persian_square</family></accept>
+       </alias>
+
+<!-- Font ordering per class -->
+
+       <!-- Persian_title class -->
+       <alias binding="same">
+         <family>Persian_title</family>
+         <accept>
+         <family>Titr</family>
+         <family>Jadid</family>
+         <family>Persian_serif</family>
+         </accept>
+       </alias>
+
+       <!-- Persian_fantasy class -->
+       <alias binding="same">
+         <family>Persian_fantasy</family>
+         <accept>
+         <family>Homa</family>
+         <family>Kamran</family>
+         <family>Fantezi</family>
+         <family>Tabassom</family>
+         <family>Persian_square</family>
+         </accept>
+       </alias>
+
+       <!-- Persian_square class -->
+       <alias binding="same">
+         <family>Persian_square</family>
+         <accept>
+         <family>Arshia</family>
+         <family>Elham</family>
+         <family>Farnaz</family>
+         <family>Nasim</family>
+         <family>Sina</family>
+         <family>Persian_serif</family>
+         </accept>
+       </alias>
+
+<!-- Register the fonts that we actually do have -->
+
+       <match target="scan">
+               <test name="family">
+                       <string>Elham</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Homa</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Koodak</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Nazli</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Roya</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Terafik</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Titr</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+
+<!-- Our fonts should oblique to the other side (TURNED-OFF) -->
+
+       <match target="font">
+               <test name="foundry">
+                       <!--string>farsiweb</string-->
+                       <string>TURNED-OFF</string>
+               </test>
+               <test name="foundry">
+                       <string>farsiweb</string>
+               </test>
+               <!-- check to see if the font is roman -->
+               <test name="slant">
+                       <const>roman</const>
+               </test>
+               <!-- check to see if the pattern requested non-roman -->
+               <test target="pattern" name="slant" compare="not_eq">
+                       <const>roman</const>
+               </test>
+               <!-- multiply the matrix to slant the font -->
+               <edit name="matrix" mode="assign">
+                       <times>
+                               <name>matrix</name>
+                               <matrix><double>1</double><double>-0.2</double>
+                                       <double>0</double><double>1</double>
+                               </matrix>
+                       </times>
+               </edit>
+               <!-- pretend the font is oblique now -->
+               <edit name="slant" mode="assign">
+                       <const>oblique</const>
+               </edit>
+       </match>
+
+
+<!--
+  We can't hint our fonts well, so turn off hinting.
+  Moreover, the bitmaps we have designed (well, they
+  have designed), suck, so disable them too.
+  -->
+
+       <match target="font">
+               <test name="foundry">
+                       <string>farsiweb</string>
+               </test>
+               <edit name="autohint">
+                       <bool>false</bool>
+               </edit>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+               <edit name="embeddedbitmap">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+
+<!-- Alias our fonts to common families -->
+
+       <!-- Persian serif fonts -->
+       <alias>
+               <family>serif</family>
+               <accept>
+                       <family>Nazli</family>
+                       <family>Lotoos</family>
+                       <family>Mitra</family>
+                       <family>Ferdosi</family>
+                       <family>Badr</family>
+                       <family>Zar</family>
+               </accept>
+       </alias>
+
+       <!-- Persian sans-serif fonts -->
+       <alias>
+               <family>sans-serif</family>
+               <accept>
+                       <family>Roya</family>
+                       <family>Koodak</family>
+                       <family>Terafik</family>
+               </accept>
+       </alias>
+
+       <!-- Persian monospace fonts -->
+       <alias>
+               <family>monospace</family>
+               <accept>
+                       <!-- Not really monospace -->
+                       <family>Terafik</family>
+               </accept>
+       </alias>
+
+       <!-- Persian fantasy fonts -->
+       <alias>
+               <family>fantasy</family>
+               <accept>
+                       <family>Homa</family>
+                       <family>Kamran</family>
+                       <family>Fantezi</family>
+                       <family>Tabassom</family>
+               </accept>
+       </alias>
+
+       <!-- Persian (and Urdu) Nastaliq/cursive fonts -->
+       <alias>
+               <family>cursive</family>
+               <accept>
+                       <family>IranNastaliq</family>
+                       <family>Nafees Nastaleeq</family>
+               </accept>
+       </alias>
+
+<!-- Use Titr in titles -->
+
+       <!-- Both serif... -->
+       <match>
+               <test name="family">
+                       <string>serif</string>
+               </test>
+               <test name="weight" compare="more_eq">
+                       <int>200</int>
+               </test>
+               <test name="size" compare="more_eq">
+                       <double>24</double>
+               </test>
+               <edit name="family" mode="prepend">
+                       <string>Titr</string>
+               </edit>
+       </match>
+
+       <!-- and sans-serif. -->
+       <match>
+               <test name="family">
+                       <string>sans-serif</string>
+               </test>
+               <test name="weight" compare="more_eq">
+                       <int>200</int>
+               </test>
+               <test name="size" compare="more_eq">
+                       <double>24</double>
+               </test>
+               <edit name="family" mode="prepend">
+                       <string>Titr</string>
+               </edit>
+       </match>
+
+       <!-- and more. -->
+       <match>
+               <test name="family">
+                       <string>Persian_sansserif_default</string>
+               </test>
+               <test name="weight" compare="more_eq">
+                       <int>200</int>
+               </test>
+               <test name="size" compare="more_eq">
+                       <double>24</double>
+               </test>
+               <edit name="family" mode="prepend" binding="same">
+                       <string>Titr</string>
+               </edit>
+       </match>
+
+
+<!-- Default substituted for deprecated sans-serif fonts -->
+
+       <match>
+               <test name="family">
+                       <string>Persian_sansserif_default</string>
+               </test>
+               <edit name="family" mode="assign" binding="same">
+                       <string>Roya</string>
+               </edit>
+       </match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/65-khmer.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/65-khmer.conf
new file mode 100644 (file)
index 0000000..f9d06f2
--- /dev/null
@@ -0,0 +1,16 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>Khmer OS"</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>Khmer OS"</family>
+               </prefer>
+       </alias>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/65-nonlatin.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/65-nonlatin.conf
new file mode 100644 (file)
index 0000000..53ac064
--- /dev/null
@@ -0,0 +1,195 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>Artsounk</family> <!-- armenian -->
+                       <family>BPG UTF8 M</family> <!-- georgian -->
+                       <family>Kinnari</family> <!-- thai -->
+                       <family>Norasi</family> <!-- thai -->
+                       <family>Frank Ruehl</family> <!-- hebrew -->
+                       <family>Dror</family>  <!-- hebrew -->
+                       <family>JG LaoTimes</family>  <!-- lao -->
+                       <family>Saysettha Unicode</family>  <!-- lao -->
+                       <family>Pigiarniq</family> <!-- canadian syllabics -->
+                       <family>B Davat</family> <!-- arabic (fa) -->
+                       <family>B Compset</family>  <!-- arabic (fa) -->
+                       <family>Kacst-Qr</family> <!-- arabic (ar) -->
+                       <family>Urdu Nastaliq Unicode</family> <!-- arabic (ur) -->
+                       <family>Raghindi</family> <!-- devanagari -->
+                       <family>Mukti Narrow</family> <!-- bengali -->
+                       <family>malayalam</family> <!-- malayalam -->
+                       <family>Sampige</family> <!-- kannada -->
+                       <family>padmaa</family> <!-- gujarati -->
+                       <family>Hapax Berbère</family> <!-- tifinagh -->
+                       <family>MS Gothic</family> <!-- han (ja) -->
+                       <family>UmePlus P Gothic</family> <!-- han (ja) -->
+                       <family>SimSun</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>PMingLiu</family> <!-- han (zh-tw) -->
+                       <family>WenQuanYi Zen Hei</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>WenQuanYi Bitmap Song</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>AR PL ShanHeiSun Uni</family> <!-- han (ja,zh-cn,zh-tw) -->
+                       <family>AR PL New Sung</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>HanyiSong</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>MgOpen Canonica</family>
+                       <family>Sazanami Mincho</family>
+                       <family>IPAMonaMincho</family>
+                       <family>IPAMincho</family>
+                       <family>Kochi Mincho</family>
+                       <family>AR PL SungtiL GB</family>
+                       <family>AR PL Mingti2L Big5</family>
+                       <family>AR PL Zenkai Uni</family>
+                       <family>MS 明朝</family>
+                       <family>ZYSong18030</family>
+                       <family>UnBatang</family>
+                       <family>Baekmuk Batang</family>
+                       <family>KacstQura</family>
+                       <family>Frank Ruehl CLM</family>
+                       <family>Lohit Bengali</family>
+                       <family>Lohit Gujarati</family>
+                       <family>Lohit Hindi</family>
+                       <family>Lohit Marathi</family>
+                       <family>Lohit Maithili</family>
+                       <family>Lohit Kashmiri</family>
+                       <family>Lohit Konkani</family>
+                       <family>Lohit Nepali</family>
+                       <family>Lohit Sindhi</family>
+                       <family>Lohit Punjabi</family>
+                       <family>Lohit Tamil</family>
+                       <family>Meera</family>
+                       <family>Lohit Malayalam</family>
+                       <family>Lohit Kannada</family>
+                       <family>Lohit Telugu</family>
+                       <family>Lohit Oriya</family>
+                       <family>LKLUG</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>Nachlieli</family> <!-- hebrew -->
+                       <family>Lucida Sans Unicode</family>
+                       <family>Yudit Unicode</family>
+                       <family>Kerkis</family> <!-- greek -->
+                       <family>ArmNet Helvetica</family> <!-- armenian -->
+                       <family>Artsounk</family> <!-- armenian -->
+                       <family>BPG UTF8 M</family> <!-- georgian -->
+                       <family>Waree</family> <!-- thai -->
+                       <family>Loma</family> <!-- thai -->
+                       <family>Garuda</family> <!-- thai -->
+                       <family>Umpush</family> <!-- thai -->
+                       <family>Saysettha Unicode</family> <!-- lao? -->
+                       <family>JG Lao Old Arial</family> <!-- lao -->
+                       <family>GF Zemen Unicode</family> <!-- ethiopic -->
+                       <family>Pigiarniq</family> <!-- canadian syllabics -->
+                       <family>B Davat</family> <!-- arabic (fa) -->
+                       <family>B Compset</family> <!-- arabic (fa) -->
+                       <family>Kacst-Qr</family> <!-- arabic (ar) -->
+                       <family>Urdu Nastaliq Unicode</family> <!-- arabic (ur) -->
+                       <family>Raghindi</family> <!-- devanagari -->
+                       <family>Mukti Narrow</family> <!-- bengali -->
+                       <family>malayalam</family> <!-- malayalam -->
+                       <family>Sampige</family> <!-- kannada -->
+                       <family>padmaa</family> <!-- gujarati -->
+                       <family>Hapax Berbère</family> <!-- tifinagh -->
+                       <family>MS Gothic</family> <!-- han (ja) -->
+                       <family>UmePlus P Gothic</family> <!-- han (ja) -->
+                       <!-- chinese fonts are actually serifed -->
+                       <family>SimSun</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>PMingLiu</family> <!-- han (zh-tw) -->
+                       <family>WenQuanYi Zen Hei</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>WenQuanYi Bitmap Song</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>AR PL ShanHeiSun Uni</family> <!--han (ja,zh-cn,zh-tw) -->
+                       <family>AR PL New Sung</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>MgOpen Modata</family>
+                       <family>VL Gothic</family>
+                       <family>IPAMonaGothic</family>
+                       <family>IPAGothic</family>
+                       <family>Sazanami Gothic</family>
+                       <family>Kochi Gothic</family>
+                       <family>AR PL KaitiM GB</family>
+                       <family>AR PL KaitiM Big5</family>
+                       <family>AR PL ShanHeiSun Uni</family>
+                       <family>AR PL SungtiL GB</family>
+                       <family>AR PL Mingti2L Big5</family>
+                       <family>MS ゴシック</family>
+                       <family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>TSCu_Paranar</family> <!-- tamil -->
+                       <family>UnDotum</family>
+                       <family>Baekmuk Dotum</family>
+                       <family>Baekmuk Gulim</family>
+                       <family>KacstQura</family>
+                       <family>Lohit Bengali</family>
+                       <family>Lohit Gujarati</family>
+                       <family>Lohit Hindi</family>
+                       <family>Lohit Marathi</family>
+                       <family>Lohit Maithili</family>
+                       <family>Lohit Kashmiri</family>
+                       <family>Lohit Konkani</family>
+                       <family>Lohit Nepali</family>
+                       <family>Lohit Sindhi</family>
+                       <family>Lohit Punjabi</family>
+                       <family>Lohit Tamil</family>
+                       <family>Meera</family>
+                       <family>Lohit Malayalam</family>
+                       <family>Lohit Kannada</family>
+                       <family>Lohit Telugu</family>
+                       <family>Lohit Oriya</family>
+                       <family>LKLUG</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>monospace</family>
+               <prefer>
+                       <family>Miriam Mono</family> <!-- hebrew -->
+                       <family>VL Gothic</family>
+                       <family>IPAMonaGothic</family>
+                       <family>IPAGothic</family>
+                       <family>Sazanami Gothic</family>
+                       <family>Kochi Gothic</family>
+                       <family>AR PL KaitiM GB</family>
+                       <family>MS Gothic</family> <!-- han (ja) -->
+                       <family>UmePlus Gothic</family> <!-- han (ja) -->
+                       <family>NSimSun</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>MingLiu</family> <!-- han (zh-tw) -->
+                       <family>AR PL ShanHeiSun Uni</family> <!-- han (ja,zh-cn,zh-tw) -->
+                       <family>AR PL New Sung Mono</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>HanyiSong</family> <!-- han (zh-cn) -->
+                       <family>AR PL SungtiL GB</family>
+                       <family>AR PL Mingti2L Big5</family>
+                       <family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>UnBatang</family>
+                       <family>UnDotum</family>
+                       <family>Baekmuk Batang</family> <!-- hangul -->
+                       <family>Baekmuk Dotum</family>
+                       <family>Baekmuk Gulim</family>
+                       <family>TlwgTypo</family> <!-- thai -->
+                       <family>TlwgTypist</family> <!-- thai -->
+                       <family>TlwgTypewriter</family> <!-- thai -->
+                       <family>TlwgMono</family> <!-- thai -->
+                       <family>Hasida</family> <!-- hebrew -->
+                       <family>Mitra Mono</family> <!-- bengali -->
+                       <family>GF Zemen Unicode</family> <!-- ethiopic -->
+                       <family>Hapax Berbère</family> <!-- tifinagh -->
+                       <family>Lohit Bengali</family>
+                       <family>Lohit Gujarati</family>
+                       <family>Lohit Hindi</family>
+                       <family>Lohit Marathi</family>
+                       <family>Lohit Maithili</family>
+                       <family>Lohit Kashmiri</family>
+                       <family>Lohit Konkani</family>
+                       <family>Lohit Nepali</family>
+                       <family>Lohit Sindhi</family>
+                       <family>Lohit Punjabi</family>
+                       <family>Lohit Tamil</family>
+                       <family>Meera</family>
+                       <family>Lohit Malayalam</family>
+                       <family>Lohit Kannada</family>
+                       <family>Lohit Telugu</family>
+                       <family>Lohit Oriya</family>
+                       <family>LKLUG</family>
+               </prefer>
+       </alias>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/69-unifont.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/69-unifont.conf
new file mode 100644 (file)
index 0000000..177dec5
--- /dev/null
@@ -0,0 +1,28 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>FreeSerif</family>
+                       <family>Code2000</family>
+                       <family>Code2001</family> <!-- plane1 and beyond -->
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>FreeSans</family>
+                       <family>Arial Unicode MS</family>
+                       <family>Arial Unicode</family>
+                       <family>Code2000</family> <!-- almost everything; serif actually -->
+                       <family>Code2001</family> <!-- plane1 and beyond -->
+               </prefer>
+       </alias>
+       <alias>
+               <family>monospace</family>
+               <prefer>
+                       <family>FreeMono</family>
+               </prefer>
+       </alias>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/70-no-bitmaps.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/70-no-bitmaps.conf
new file mode 100644 (file)
index 0000000..6b506e8
--- /dev/null
@@ -0,0 +1,12 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- Reject bitmap fonts -->
+ <selectfont>
+  <rejectfont>
+   <pattern>
+     <patelt name="scalable"><bool>false</bool></patelt>
+   </pattern>
+  </rejectfont>
+ </selectfont>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/70-yes-bitmaps.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/70-yes-bitmaps.conf
new file mode 100644 (file)
index 0000000..c153aeb
--- /dev/null
@@ -0,0 +1,12 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- Accept bitmap fonts -->
+ <selectfont>
+  <acceptfont>
+   <pattern>
+     <patelt name="scalable"><bool>false</bool></patelt>
+   </pattern>
+  </acceptfont>
+ </selectfont>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/80-delicious.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/80-delicious.conf
new file mode 100644 (file)
index 0000000..728f50c
--- /dev/null
@@ -0,0 +1,19 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- Fix-ups for Delicious family -->
+
+<!-- Delicious 'heavy' variant says its Medium weight -->
+<match target="scan">
+       <test name="family">
+               <string>Delicious</string>
+       </test>
+       <test name="style">
+               <string>Heavy</string>
+       </test>
+       <edit name="weight">
+               <const>heavy</const>
+       </edit>
+</match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.avail/90-synthetic.conf b/tools/windows_packaging/mingw64/fonts/conf.avail/90-synthetic.conf
new file mode 100644 (file)
index 0000000..b8d1e85
--- /dev/null
@@ -0,0 +1,64 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- 
+ Artificial oblique for fonts without an italic or oblique version
+ -->
+       <match target="font">
+               <!-- check to see if the font is roman -->
+               <test name="slant">
+                       <const>roman</const>
+               </test>
+               <!-- check to see if the pattern requested non-roman -->
+               <test target="pattern" name="slant" compare="not_eq">
+                       <const>roman</const>
+               </test>
+               <!-- multiply the matrix to slant the font -->
+               <edit name="matrix" mode="assign">
+                       <times>
+                               <name>matrix</name>
+                               <matrix><double>1</double><double>0.2</double>
+                                       <double>0</double><double>1</double>
+                               </matrix>
+                       </times>
+               </edit>
+               <!-- pretend the font is oblique now -->
+               <edit name="slant" mode="assign">
+                       <const>oblique</const>
+               </edit>
+               <!-- and disable embedded bitmaps for artificial oblique -->
+               <edit name="embeddedbitmap" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+<!--
+ Synthetic emboldening for fonts that do not have bold face available
+ -->
+
+       <match target="font">
+               <!-- check to see if the font is just regular -->
+               <test name="weight" compare="less_eq">
+                       <const>medium</const>
+               </test>
+               <!-- check to see if the pattern requests bold -->
+               <test target="pattern" name="weight" compare="more">
+                       <const>medium</const>
+               </test>
+               <!--
+                 set the embolden flag
+                 needed for applications using cairo, e.g. gucharmap, gedit, ...
+               -->
+               <edit name="embolden" mode="assign">
+                       <bool>true</bool>
+               </edit>
+               <!--
+                set weight to bold
+                needed for applications using Xft directly, e.g. Firefox, ...
+               -->
+               <edit name="weight" mode="assign">
+                       <const>bold</const>
+               </edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/20-fix-globaladvance.conf b/tools/windows_packaging/mingw64/fonts/conf.d/20-fix-globaladvance.conf
new file mode 100644 (file)
index 0000000..2a9c063
--- /dev/null
@@ -0,0 +1,28 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  Some Asian fonts misadvertise themselves as monospaced when
+  in fact they are dual-spaced (half and full).  This makes
+  FreeType very confused as it forces all widths to match.
+  Undo this magic by disabling the width forcing code -->
+       <match target="font">
+               <test name="family"><string>GulimChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+
+       <match target="font">
+               <test name="family"><string>DotumChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+
+       <match target="font">
+               <test name="family"><string>BatangChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+
+       <match target="font">
+               <test name="family"><string>GungsuhChe</string></test>
+               <edit name="globaladvance"><bool>false</bool></edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/20-unhint-small-vera.conf b/tools/windows_packaging/mingw64/fonts/conf.d/20-unhint-small-vera.conf
new file mode 100644 (file)
index 0000000..c4ebee9
--- /dev/null
@@ -0,0 +1,48 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- 
+       The Bitstream Vera fonts have GASP entries suggesting that hinting be
+       disabled below 8 ppem, but FreeType ignores those, preferring to use
+       the data found in the instructed hints.  The initial Vera release
+       didn't include the right instructions in the 'prep' table. Fix this
+       by disabling hinting manually at smaller sizes (< 8ppem)
+ -->
+
+       <match target="font">
+               <test name="family">
+                       <string>Bitstream Vera Sans</string>
+               </test>
+               <test name="pixelsize" compare="less">
+                       <double>7.5</double>
+               </test>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+       <match target="font">
+               <test name="family">
+                       <string>Bitstream Vera Serif</string>
+               </test>
+               <test name="pixelsize" compare="less">
+                       <double>7.5</double>
+               </test>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+       <match target="font">
+               <test name="family">
+                       <string>Bitstream Vera Sans Mono</string>
+               </test>
+               <test name="pixelsize" compare="less">
+                       <double>7.5</double>
+               </test>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/30-metric-aliases.conf b/tools/windows_packaging/mingw64/fonts/conf.d/30-metric-aliases.conf
new file mode 100644 (file)
index 0000000..702a495
--- /dev/null
@@ -0,0 +1,211 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+
+       <!-- Alias similar/metric-compatible families from various sources:
+
+               PostScript fonts:
+                       Helvetica
+                       Times
+                       Courier
+               URW fonts:
+                       Nimbus Sans L
+                       Nimbus Roman No9 L
+                       Nimbus Mono L
+
+               Microsoft fonts:
+                       Arial
+                       Times New Roman
+                       Courier New
+               Liberation fonts:
+                       Liberation Sans
+                       Liberation Serif
+                       Liberation Mono
+               StarOffice fonts:
+                       Albany
+                       Thorndale
+                       Cumberland
+               AMT fonts:
+                       Albany AMT
+                       Thorndale AMT
+                       Cumberland AMT
+
+            Of these, URW fonts are design compatible with PostScrict fonts,
+            and the Liberation, StarOffice, and AMT ones are compatible with
+            Microsoft fonts.
+
+            We want for each of them to fallback to any of these
+            available, but in an order preferring similar designs
+            first.  We do this in three steps:
+
+               1) Alias each specific to it's generic family.
+                  eg. Liberation Sans to Arial
+
+               2) Weak alias each generic to the other generic of its family.
+                  eg. Arial to Helvetica
+
+               3) Alias each generic to its specifics.
+                  eg. Arial to Liberation Sans, Albany, and Albany AMT
+       -->
+
+<!-- Map specifics to generics -->
+
+       <!-- PostScript -->
+       <alias binding="same">
+         <family>Nimbus Sans L</family>
+         <default>
+         <family>Helvetica</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Nimbus Roman No9 L</family>
+         <default>
+         <family>Times</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Nimbus Mono L</family>
+         <default>
+         <family>Courier</family>
+         </default>
+       </alias>
+
+
+       <!-- Microsoft -->
+       <alias binding="same">
+         <family>Liberation Sans</family>
+         <family>Albany</family>
+         <family>Albany AMT</family>
+         <default>
+         <family>Arial</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Liberation Serif</family>
+         <family>Thorndale</family>
+         <family>Thorndale AMT</family>
+         <default>
+         <family>Times New Roman</family>
+         </default>
+       </alias>
+
+       <alias binding="same">
+         <family>Liberation Mono</family>
+         <family>Cumberland</family>
+         <family>Cumberland AMT</family>
+         <default>
+         <family>Courier New</family>
+         </default>
+       </alias>
+
+
+
+<!-- Accept the other group as fallback -->
+
+
+       <!-- PostScript -->
+       <alias>
+         <family>Helvetica</family>
+         <default>
+         <family>Arial</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Times</family>
+         <default>
+         <family>Times New Roman</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Courier</family>
+         <default>
+         <family>Courier New</family>
+         </default>
+       </alias>
+
+
+       <!-- Microsoft -->
+       <alias>
+         <family>Arial</family>
+         <default>
+         <family>Helvetica</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Times New Roman</family>
+         <default>
+         <family>Times</family>
+         </default>
+       </alias>
+
+       <alias>
+         <family>Courier New</family>
+         <default>
+         <family>Courier</family>
+         </default>
+       </alias>
+
+
+
+<!-- Map generics to specifics -->
+
+
+       <!-- PostScript -->
+       <alias binding="same">
+         <family>Helvetica</family>
+         <accept>
+         <family>Nimbus Sans L</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Times</family>
+         <accept>
+         <family>Nimbus Roman No9 L</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Courier</family>
+         <accept>
+         <family>Nimbus Mono L</family>
+         </accept>
+       </alias>
+
+
+       <!-- Microsoft -->
+       <alias binding="same">
+         <family>Arial</family>
+         <accept>
+         <family>Liberation Sans</family>
+         <family>Albany</family>
+         <family>Albany AMT</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Times New Roman</family>
+         <accept>
+         <family>Liberation Serif</family>
+         <family>Thorndale</family>
+         <family>Thorndale AMT</family>
+         </accept>
+       </alias>
+
+       <alias binding="same">
+         <family>Courier New</family>
+         <accept>
+         <family>Liberation Mono</family>
+         <family>Cumberland</family>
+         <family>Cumberland AMT</family>
+         </accept>
+       </alias>
+
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/30-urw-aliases.conf b/tools/windows_packaging/mingw64/fonts/conf.d/30-urw-aliases.conf
new file mode 100644 (file)
index 0000000..9d59203
--- /dev/null
@@ -0,0 +1,40 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  URW provides metric and shape compatible fonts for some Adobe families.
+  Helvetica, Courier, and Times are handled in 30-metric-aliases.conf.
+  -->
+       <alias binding="same">
+         <family>Avant Garde</family>
+         <accept><family>URW Gothic L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Bookman</family>
+         <accept><family>URW Bookman L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>New Century Schoolbook</family>
+         <accept><family>Century Schoolbook L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Palatino</family>
+         <accept><family>URW Palladio L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Zapf Chancery</family>
+         <accept><family>URW Chancery L</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Zapf Dingbats</family>
+         <accept><family>Dingbats</family></accept>
+       </alias>
+       <match target="pattern">
+         <test name="family">
+           <string>Symbol</string>
+         </test>
+         <edit name="family" mode="append" binding="same">
+           <string>Standard Symbols L</string>
+         </edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/40-nonlatin.conf b/tools/windows_packaging/mingw64/fonts/conf.d/40-nonlatin.conf
new file mode 100644 (file)
index 0000000..a875db0
--- /dev/null
@@ -0,0 +1,90 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  Mark common families with their generics so we'll get
+  something reasonable
+-->
+
+<!--
+  Serif faces
+ -->
+       <alias>
+               <family>Nazli</family>
+               <family>Lotoos</family>
+               <family>Mitra</family>
+               <family>Ferdosi</family>
+               <family>Badr</family>
+               <family>Zar</family>
+               <family>Titr</family>
+               <family>Jadid</family>
+               <family>Kochi Mincho</family>
+               <family>AR PL SungtiL GB</family>
+               <family>AR PL Mingti2L Big5</family>
+               <family>MS 明朝</family>
+               <family>UnBatang</family>
+               <family>Baekmuk Batang</family>
+               <family>MgOpen Canonica</family>
+               <family>Sazanami Mincho</family>
+               <family>AR PL ZenKai Uni</family>
+               <family>ZYSong18030</family>
+               <family>FreeSerif</family>
+               <default><family>serif</family></default>
+       </alias>
+<!--
+  Sans-serif faces
+ -->
+       <alias>
+               <family>Arshia</family>
+               <family>Elham</family>
+               <family>Farnaz</family>
+               <family>Nasim</family>
+               <family>Sina</family>
+               <family>Roya</family>
+               <family>Koodak</family>
+               <family>Terafik</family>
+               <family>Kochi Gothic</family>
+               <family>AR PL KaitiM GB</family>
+               <family>AR PL KaitiM Big5</family>
+               <family>MS ゴシック</family>
+               <family>UnDotum</family>
+               <family>Baekmuk Dotum</family>
+               <family>SimSun</family>
+               <family>MgOpen Modata</family>
+               <family>Sazanami Gothic</family>
+               <family>AR PL ShanHeiSun Uni</family>
+               <family>ZYSong18030</family>
+               <family>FreeSans</family>
+               <default><family>sans-serif</family></default>
+       </alias>
+<!--
+  Monospace faces
+ -->
+       <alias>
+               <family>NSimSun</family>
+               <family>ZYSong18030</family>
+               <family>FreeMono</family>
+               <default><family>monospace</family></default>
+       </alias>
+
+<!--
+  Fantasy faces
+ -->
+       <alias>
+               <family>Homa</family>
+               <family>Kamran</family>
+               <family>Fantezi</family>
+               <family>Tabassom</family>
+               <default><family>fantasy</family></default>
+       </alias>
+
+<!--
+  Cursive faces
+ -->
+       <alias>
+               <family>IranNastaliq</family>
+               <family>Nafees Nastaleeq</family>
+               <default><family>cursive</family></default>
+       </alias>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/45-latin.conf b/tools/windows_packaging/mingw64/fonts/conf.d/45-latin.conf
new file mode 100644 (file)
index 0000000..7e41264
--- /dev/null
@@ -0,0 +1,77 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  Mark common families with their generics so we'll get
+  something reasonable
+-->
+
+<!--
+  Serif faces
+ -->
+       <alias>
+               <family>Bitstream Vera Serif</family>
+               <family>DejaVu Serif</family>
+               <family>Liberation Serif</family>
+               <family>Times New Roman</family>
+               <family>Times</family>
+               <family>Nimbus Roman No9 L</family>
+               <family>Luxi Serif</family>
+               <family>Thorndale AMT</family>
+               <family>Thorndale</family>
+               <default><family>serif</family></default>
+       </alias>
+<!--
+  Sans-serif faces
+ -->
+       <alias>
+               <family>Bitstream Vera Sans</family>
+               <family>DejaVu Sans</family>
+               <family>Liberation Sans</family>
+               <family>Arial</family>
+               <family>Helvetica</family>
+               <family>Verdana</family>
+               <family>Albany AMT</family>
+               <family>Albany</family>
+               <family>Nimbus Sans L</family>
+               <family>Luxi Sans</family>
+               <default><family>sans-serif</family></default>
+       </alias>
+<!--
+  Monospace faces
+ -->
+       <alias>
+               <family>Bitstream Vera Sans Mono</family>
+               <family>DejaVu Sans Mono</family>
+               <family>Liberation Mono</family>
+               <family>Inconsolata</family>
+               <family>Courier New</family>
+               <family>Courier</family>
+               <family>Andale Mono</family>
+               <family>Luxi Mono</family>
+               <family>Cumberland AMT</family>
+               <family>Cumberland</family>
+               <family>Nimbus Mono L</family>
+               <default><family>monospace</family></default>
+       </alias>
+<!--
+  Fantasy faces
+ -->
+       <alias>
+               <family>Impact</family>
+               <family>Copperplate Gothic Std</family>
+               <family>Cooper Std</family>
+               <family>Bauhaus Std</family>
+               <default><family>fantasy</family></default>
+       </alias>
+<!--
+  Cursive faces
+  -->
+       <alias>
+               <family>ITC Zapf Chancery Std</family>
+               <family>Zapfino</family>
+               <family>Comic Sans MS</family>
+               <default><family>cursive</family></default>
+       </alias>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/49-sansserif.conf b/tools/windows_packaging/mingw64/fonts/conf.d/49-sansserif.conf
new file mode 100644 (file)
index 0000000..c6209a7
--- /dev/null
@@ -0,0 +1,21 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!--
+  If the font still has no generic name, add sans-serif
+ -->
+       <match target="pattern">
+               <test qual="all" name="family" compare="not_eq">
+                       <string>sans-serif</string>
+               </test>
+               <test qual="all" name="family" compare="not_eq">
+                       <string>serif</string>
+               </test>
+               <test qual="all" name="family" compare="not_eq">
+                       <string>monospace</string>
+               </test>
+               <edit name="family" mode="append_last">
+                       <string>sans-serif</string>
+               </edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/50-user.conf b/tools/windows_packaging/mingw64/fonts/conf.d/50-user.conf
new file mode 100644 (file)
index 0000000..3f89012
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <!-- Load per-user customization file -->
+       <include ignore_missing="yes">~/.fonts.conf.d</include>
+       <include ignore_missing="yes">~/.fonts.conf</include>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/51-local.conf b/tools/windows_packaging/mingw64/fonts/conf.d/51-local.conf
new file mode 100644 (file)
index 0000000..ca9fbe1
--- /dev/null
@@ -0,0 +1,6 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <!-- Load local system customization file -->
+       <include ignore_missing="yes">local.conf</include>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/60-latin.conf b/tools/windows_packaging/mingw64/fonts/conf.d/60-latin.conf
new file mode 100644 (file)
index 0000000..2107e31
--- /dev/null
@@ -0,0 +1,70 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>Bitstream Vera Serif</family>
+                       <family>DejaVu Serif</family>
+                       <family>Times New Roman</family>
+                       <family>Thorndale AMT</family>
+                       <family>Luxi Serif</family>
+                       <family>Nimbus Roman No9 L</family>
+                       <family>Times</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>Bitstream Vera Sans</family>
+                       <family>DejaVu Sans</family>
+                       <family>Verdana</family>
+                       <family>Arial</family>
+                       <family>Albany AMT</family>
+                       <family>Luxi Sans</family>
+                       <family>Nimbus Sans L</family>
+                       <family>Helvetica</family>
+                       <family>Lucida Sans Unicode</family>
+                       <family>BPG Glaho International</family> <!-- lat,cyr,arab,geor -->
+                       <family>Tahoma</family> <!-- lat,cyr,greek,heb,arab,thai -->
+               </prefer>
+       </alias>
+       <alias>
+               <family>monospace</family>
+               <prefer>
+                       <family>Bitstream Vera Sans Mono</family>
+                       <family>DejaVu Sans Mono</family>
+                       <family>Inconsolata</family>
+                       <family>Andale Mono</family>
+                       <family>Courier New</family>
+                       <family>Cumberland AMT</family>
+                       <family>Luxi Mono</family>
+                       <family>Nimbus Mono L</family>
+                       <family>Courier</family>
+               </prefer>
+       </alias>
+<!--
+  Fantasy faces
+ -->
+       <alias>
+               <family>fantasy</family>
+               <prefer>
+                       <family>Impact</family>
+                       <family>Copperplate Gothic Std</family>
+                       <family>Cooper Std</family>
+                       <family>Bauhaus Std</family>
+               </prefer>
+       </alias>
+<!--
+  Cursive faces
+  -->
+       <alias>
+               <family>cursive</family>
+               <prefer>
+                       <family>ITC Zapf Chancery Std</family>
+                       <family>Zapfino</family>
+                       <family>Comic Sans MS</family>
+               </prefer>
+       </alias>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/65-fonts-persian.conf b/tools/windows_packaging/mingw64/fonts/conf.d/65-fonts-persian.conf
new file mode 100644 (file)
index 0000000..0033675
--- /dev/null
@@ -0,0 +1,419 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<!--
+  fonts-persian.conf
+  To configure Persian fonts from The FarsiWeb Project.
+
+  Copyright (C) 2005  Sharif FarsiWeb, Inc. <license@farsiweb.info>
+
+  Permission to use, copy, modify, distribute, and sell this software and its
+  documentation for any purpose is hereby granted without fee, provided that
+  the above copyright notice appear in all copies and that both that
+  copyright notice and this permission notice appear in supporting
+  documentation, and that the name of Sharif FarsiWeb, Inc. not be used in
+  advertising or publicity pertaining to distribution of the software without
+  specific, written prior permission.  Sharif FarsiWeb, Inc. makes no
+  representations about the suitability of this software for any purpose.  It
+  is provided "as is" without express or implied warranty.
+
+  SHARIF FARSIWEB, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+  INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+  EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+  CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+  DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+  PERFORMANCE OF THIS SOFTWARE.
+
+  ChangeLog:
+    2005-04-03  Behdad Esfahbod:  Initial revision.
+    2005-10-09  Behdad Esfahbod:  Turned off back-slant and Tahoma sections.
+    2005-11-30  Behdad Esfahbod:  Set Titr susbtitution size to 24 points.
+    2008       Behdad Esfahbod:  Cleanup.  Add fantasy and cursive.
+  -->
+<fontconfig>
+
+
+<!-- Deprecated fonts are discouraged -->
+
+       <!-- Nesf[2] is officially deprecated and has problematic tables -->
+       <alias binding="same">
+         <family>Nesf</family>
+         <accept><family>Nesf2</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Nesf2</family>
+         <accept><family>Persian_sansserif_default</family></accept>
+       </alias>
+
+<!-- Name changes and spelling variant aliases -->
+
+       <alias binding="same">
+         <family>Nazanin</family>
+         <accept><family>Nazli</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Lotus</family>
+         <accept><family>Lotoos</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Yaqut</family>
+         <accept><family>Yaghoot</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Yaghut</family>
+         <accept><family>Yaghoot</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Traffic</family>
+         <accept><family>Terafik</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Ferdowsi</family>
+         <accept><family>Ferdosi</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Fantezy</family>
+         <accept><family>Fantezi</family></accept>
+       </alias>
+
+
+<!-- Classify fonts. -->
+
+       <!-- Persian_title class -->
+       <alias binding="same">
+         <family>Jadid</family>
+         <accept><family>Persian_title</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Titr</family>
+         <accept><family>Persian_title</family></accept>
+       </alias>
+
+       <!-- Persian_fantasy class -->
+       <alias binding="same">
+         <family>Kamran</family>
+         <accept>
+         <family>Persian_fantasy</family>
+         <family>Homa</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Homa</family>
+         <accept>
+         <family>Persian_fantasy</family>
+         <family>Kamran</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Fantezi</family>
+         <accept><family>Persian_fantasy</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Tabassom</family>
+         <accept><family>Persian_fantasy</family></accept>
+       </alias>
+
+       <!-- Persian_square class -->
+       <alias binding="same">
+         <family>Arshia</family>
+         <accept><family>Persian_square</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Nasim</family>
+         <accept><family>Persian_square</family></accept>
+       </alias>
+       <alias binding="same">
+         <family>Elham</family>
+         <accept>
+         <family>Persian_square</family>
+         <family>Farnaz</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Farnaz</family>
+         <accept>
+         <family>Persian_square</family>
+         <family>Elham</family>
+         </accept>
+       </alias>
+       <alias binding="same">
+         <family>Sina</family>
+         <accept><family>Persian_square</family></accept>
+       </alias>
+
+<!-- Font ordering per class -->
+
+       <!-- Persian_title class -->
+       <alias binding="same">
+         <family>Persian_title</family>
+         <accept>
+         <family>Titr</family>
+         <family>Jadid</family>
+         <family>Persian_serif</family>
+         </accept>
+       </alias>
+
+       <!-- Persian_fantasy class -->
+       <alias binding="same">
+         <family>Persian_fantasy</family>
+         <accept>
+         <family>Homa</family>
+         <family>Kamran</family>
+         <family>Fantezi</family>
+         <family>Tabassom</family>
+         <family>Persian_square</family>
+         </accept>
+       </alias>
+
+       <!-- Persian_square class -->
+       <alias binding="same">
+         <family>Persian_square</family>
+         <accept>
+         <family>Arshia</family>
+         <family>Elham</family>
+         <family>Farnaz</family>
+         <family>Nasim</family>
+         <family>Sina</family>
+         <family>Persian_serif</family>
+         </accept>
+       </alias>
+
+<!-- Register the fonts that we actually do have -->
+
+       <match target="scan">
+               <test name="family">
+                       <string>Elham</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Homa</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Koodak</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Nazli</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Roya</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Terafik</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+       <match target="scan">
+               <test name="family">
+                       <string>Titr</string>
+               </test>
+               <edit name="foundry">
+                       <string>farsiweb</string>
+               </edit>
+       </match>
+
+
+<!-- Our fonts should oblique to the other side (TURNED-OFF) -->
+
+       <match target="font">
+               <test name="foundry">
+                       <!--string>farsiweb</string-->
+                       <string>TURNED-OFF</string>
+               </test>
+               <test name="foundry">
+                       <string>farsiweb</string>
+               </test>
+               <!-- check to see if the font is roman -->
+               <test name="slant">
+                       <const>roman</const>
+               </test>
+               <!-- check to see if the pattern requested non-roman -->
+               <test target="pattern" name="slant" compare="not_eq">
+                       <const>roman</const>
+               </test>
+               <!-- multiply the matrix to slant the font -->
+               <edit name="matrix" mode="assign">
+                       <times>
+                               <name>matrix</name>
+                               <matrix><double>1</double><double>-0.2</double>
+                                       <double>0</double><double>1</double>
+                               </matrix>
+                       </times>
+               </edit>
+               <!-- pretend the font is oblique now -->
+               <edit name="slant" mode="assign">
+                       <const>oblique</const>
+               </edit>
+       </match>
+
+
+<!--
+  We can't hint our fonts well, so turn off hinting.
+  Moreover, the bitmaps we have designed (well, they
+  have designed), suck, so disable them too.
+  -->
+
+       <match target="font">
+               <test name="foundry">
+                       <string>farsiweb</string>
+               </test>
+               <edit name="autohint">
+                       <bool>false</bool>
+               </edit>
+               <edit name="hinting">
+                       <bool>false</bool>
+               </edit>
+               <edit name="embeddedbitmap">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+
+<!-- Alias our fonts to common families -->
+
+       <!-- Persian serif fonts -->
+       <alias>
+               <family>serif</family>
+               <accept>
+                       <family>Nazli</family>
+                       <family>Lotoos</family>
+                       <family>Mitra</family>
+                       <family>Ferdosi</family>
+                       <family>Badr</family>
+                       <family>Zar</family>
+               </accept>
+       </alias>
+
+       <!-- Persian sans-serif fonts -->
+       <alias>
+               <family>sans-serif</family>
+               <accept>
+                       <family>Roya</family>
+                       <family>Koodak</family>
+                       <family>Terafik</family>
+               </accept>
+       </alias>
+
+       <!-- Persian monospace fonts -->
+       <alias>
+               <family>monospace</family>
+               <accept>
+                       <!-- Not really monospace -->
+                       <family>Terafik</family>
+               </accept>
+       </alias>
+
+       <!-- Persian fantasy fonts -->
+       <alias>
+               <family>fantasy</family>
+               <accept>
+                       <family>Homa</family>
+                       <family>Kamran</family>
+                       <family>Fantezi</family>
+                       <family>Tabassom</family>
+               </accept>
+       </alias>
+
+       <!-- Persian (and Urdu) Nastaliq/cursive fonts -->
+       <alias>
+               <family>cursive</family>
+               <accept>
+                       <family>IranNastaliq</family>
+                       <family>Nafees Nastaleeq</family>
+               </accept>
+       </alias>
+
+<!-- Use Titr in titles -->
+
+       <!-- Both serif... -->
+       <match>
+               <test name="family">
+                       <string>serif</string>
+               </test>
+               <test name="weight" compare="more_eq">
+                       <int>200</int>
+               </test>
+               <test name="size" compare="more_eq">
+                       <double>24</double>
+               </test>
+               <edit name="family" mode="prepend">
+                       <string>Titr</string>
+               </edit>
+       </match>
+
+       <!-- and sans-serif. -->
+       <match>
+               <test name="family">
+                       <string>sans-serif</string>
+               </test>
+               <test name="weight" compare="more_eq">
+                       <int>200</int>
+               </test>
+               <test name="size" compare="more_eq">
+                       <double>24</double>
+               </test>
+               <edit name="family" mode="prepend">
+                       <string>Titr</string>
+               </edit>
+       </match>
+
+       <!-- and more. -->
+       <match>
+               <test name="family">
+                       <string>Persian_sansserif_default</string>
+               </test>
+               <test name="weight" compare="more_eq">
+                       <int>200</int>
+               </test>
+               <test name="size" compare="more_eq">
+                       <double>24</double>
+               </test>
+               <edit name="family" mode="prepend" binding="same">
+                       <string>Titr</string>
+               </edit>
+       </match>
+
+
+<!-- Default substituted for deprecated sans-serif fonts -->
+
+       <match>
+               <test name="family">
+                       <string>Persian_sansserif_default</string>
+               </test>
+               <edit name="family" mode="assign" binding="same">
+                       <string>Roya</string>
+               </edit>
+       </match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/65-nonlatin.conf b/tools/windows_packaging/mingw64/fonts/conf.d/65-nonlatin.conf
new file mode 100644 (file)
index 0000000..53ac064
--- /dev/null
@@ -0,0 +1,195 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>Artsounk</family> <!-- armenian -->
+                       <family>BPG UTF8 M</family> <!-- georgian -->
+                       <family>Kinnari</family> <!-- thai -->
+                       <family>Norasi</family> <!-- thai -->
+                       <family>Frank Ruehl</family> <!-- hebrew -->
+                       <family>Dror</family>  <!-- hebrew -->
+                       <family>JG LaoTimes</family>  <!-- lao -->
+                       <family>Saysettha Unicode</family>  <!-- lao -->
+                       <family>Pigiarniq</family> <!-- canadian syllabics -->
+                       <family>B Davat</family> <!-- arabic (fa) -->
+                       <family>B Compset</family>  <!-- arabic (fa) -->
+                       <family>Kacst-Qr</family> <!-- arabic (ar) -->
+                       <family>Urdu Nastaliq Unicode</family> <!-- arabic (ur) -->
+                       <family>Raghindi</family> <!-- devanagari -->
+                       <family>Mukti Narrow</family> <!-- bengali -->
+                       <family>malayalam</family> <!-- malayalam -->
+                       <family>Sampige</family> <!-- kannada -->
+                       <family>padmaa</family> <!-- gujarati -->
+                       <family>Hapax Berbère</family> <!-- tifinagh -->
+                       <family>MS Gothic</family> <!-- han (ja) -->
+                       <family>UmePlus P Gothic</family> <!-- han (ja) -->
+                       <family>SimSun</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>PMingLiu</family> <!-- han (zh-tw) -->
+                       <family>WenQuanYi Zen Hei</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>WenQuanYi Bitmap Song</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>AR PL ShanHeiSun Uni</family> <!-- han (ja,zh-cn,zh-tw) -->
+                       <family>AR PL New Sung</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>HanyiSong</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>MgOpen Canonica</family>
+                       <family>Sazanami Mincho</family>
+                       <family>IPAMonaMincho</family>
+                       <family>IPAMincho</family>
+                       <family>Kochi Mincho</family>
+                       <family>AR PL SungtiL GB</family>
+                       <family>AR PL Mingti2L Big5</family>
+                       <family>AR PL Zenkai Uni</family>
+                       <family>MS 明朝</family>
+                       <family>ZYSong18030</family>
+                       <family>UnBatang</family>
+                       <family>Baekmuk Batang</family>
+                       <family>KacstQura</family>
+                       <family>Frank Ruehl CLM</family>
+                       <family>Lohit Bengali</family>
+                       <family>Lohit Gujarati</family>
+                       <family>Lohit Hindi</family>
+                       <family>Lohit Marathi</family>
+                       <family>Lohit Maithili</family>
+                       <family>Lohit Kashmiri</family>
+                       <family>Lohit Konkani</family>
+                       <family>Lohit Nepali</family>
+                       <family>Lohit Sindhi</family>
+                       <family>Lohit Punjabi</family>
+                       <family>Lohit Tamil</family>
+                       <family>Meera</family>
+                       <family>Lohit Malayalam</family>
+                       <family>Lohit Kannada</family>
+                       <family>Lohit Telugu</family>
+                       <family>Lohit Oriya</family>
+                       <family>LKLUG</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>Nachlieli</family> <!-- hebrew -->
+                       <family>Lucida Sans Unicode</family>
+                       <family>Yudit Unicode</family>
+                       <family>Kerkis</family> <!-- greek -->
+                       <family>ArmNet Helvetica</family> <!-- armenian -->
+                       <family>Artsounk</family> <!-- armenian -->
+                       <family>BPG UTF8 M</family> <!-- georgian -->
+                       <family>Waree</family> <!-- thai -->
+                       <family>Loma</family> <!-- thai -->
+                       <family>Garuda</family> <!-- thai -->
+                       <family>Umpush</family> <!-- thai -->
+                       <family>Saysettha Unicode</family> <!-- lao? -->
+                       <family>JG Lao Old Arial</family> <!-- lao -->
+                       <family>GF Zemen Unicode</family> <!-- ethiopic -->
+                       <family>Pigiarniq</family> <!-- canadian syllabics -->
+                       <family>B Davat</family> <!-- arabic (fa) -->
+                       <family>B Compset</family> <!-- arabic (fa) -->
+                       <family>Kacst-Qr</family> <!-- arabic (ar) -->
+                       <family>Urdu Nastaliq Unicode</family> <!-- arabic (ur) -->
+                       <family>Raghindi</family> <!-- devanagari -->
+                       <family>Mukti Narrow</family> <!-- bengali -->
+                       <family>malayalam</family> <!-- malayalam -->
+                       <family>Sampige</family> <!-- kannada -->
+                       <family>padmaa</family> <!-- gujarati -->
+                       <family>Hapax Berbère</family> <!-- tifinagh -->
+                       <family>MS Gothic</family> <!-- han (ja) -->
+                       <family>UmePlus P Gothic</family> <!-- han (ja) -->
+                       <!-- chinese fonts are actually serifed -->
+                       <family>SimSun</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>PMingLiu</family> <!-- han (zh-tw) -->
+                       <family>WenQuanYi Zen Hei</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>WenQuanYi Bitmap Song</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>AR PL ShanHeiSun Uni</family> <!--han (ja,zh-cn,zh-tw) -->
+                       <family>AR PL New Sung</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>MgOpen Modata</family>
+                       <family>VL Gothic</family>
+                       <family>IPAMonaGothic</family>
+                       <family>IPAGothic</family>
+                       <family>Sazanami Gothic</family>
+                       <family>Kochi Gothic</family>
+                       <family>AR PL KaitiM GB</family>
+                       <family>AR PL KaitiM Big5</family>
+                       <family>AR PL ShanHeiSun Uni</family>
+                       <family>AR PL SungtiL GB</family>
+                       <family>AR PL Mingti2L Big5</family>
+                       <family>MS ゴシック</family>
+                       <family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>TSCu_Paranar</family> <!-- tamil -->
+                       <family>UnDotum</family>
+                       <family>Baekmuk Dotum</family>
+                       <family>Baekmuk Gulim</family>
+                       <family>KacstQura</family>
+                       <family>Lohit Bengali</family>
+                       <family>Lohit Gujarati</family>
+                       <family>Lohit Hindi</family>
+                       <family>Lohit Marathi</family>
+                       <family>Lohit Maithili</family>
+                       <family>Lohit Kashmiri</family>
+                       <family>Lohit Konkani</family>
+                       <family>Lohit Nepali</family>
+                       <family>Lohit Sindhi</family>
+                       <family>Lohit Punjabi</family>
+                       <family>Lohit Tamil</family>
+                       <family>Meera</family>
+                       <family>Lohit Malayalam</family>
+                       <family>Lohit Kannada</family>
+                       <family>Lohit Telugu</family>
+                       <family>Lohit Oriya</family>
+                       <family>LKLUG</family>
+               </prefer>
+       </alias>
+       <alias>
+               <family>monospace</family>
+               <prefer>
+                       <family>Miriam Mono</family> <!-- hebrew -->
+                       <family>VL Gothic</family>
+                       <family>IPAMonaGothic</family>
+                       <family>IPAGothic</family>
+                       <family>Sazanami Gothic</family>
+                       <family>Kochi Gothic</family>
+                       <family>AR PL KaitiM GB</family>
+                       <family>MS Gothic</family> <!-- han (ja) -->
+                       <family>UmePlus Gothic</family> <!-- han (ja) -->
+                       <family>NSimSun</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>MingLiu</family> <!-- han (zh-tw) -->
+                       <family>AR PL ShanHeiSun Uni</family> <!-- han (ja,zh-cn,zh-tw) -->
+                       <family>AR PL New Sung Mono</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>HanyiSong</family> <!-- han (zh-cn) -->
+                       <family>AR PL SungtiL GB</family>
+                       <family>AR PL Mingti2L Big5</family>
+                       <family>ZYSong18030</family> <!-- han (zh-cn,zh-tw) -->
+                       <family>UnBatang</family>
+                       <family>UnDotum</family>
+                       <family>Baekmuk Batang</family> <!-- hangul -->
+                       <family>Baekmuk Dotum</family>
+                       <family>Baekmuk Gulim</family>
+                       <family>TlwgTypo</family> <!-- thai -->
+                       <family>TlwgTypist</family> <!-- thai -->
+                       <family>TlwgTypewriter</family> <!-- thai -->
+                       <family>TlwgMono</family> <!-- thai -->
+                       <family>Hasida</family> <!-- hebrew -->
+                       <family>Mitra Mono</family> <!-- bengali -->
+                       <family>GF Zemen Unicode</family> <!-- ethiopic -->
+                       <family>Hapax Berbère</family> <!-- tifinagh -->
+                       <family>Lohit Bengali</family>
+                       <family>Lohit Gujarati</family>
+                       <family>Lohit Hindi</family>
+                       <family>Lohit Marathi</family>
+                       <family>Lohit Maithili</family>
+                       <family>Lohit Kashmiri</family>
+                       <family>Lohit Konkani</family>
+                       <family>Lohit Nepali</family>
+                       <family>Lohit Sindhi</family>
+                       <family>Lohit Punjabi</family>
+                       <family>Lohit Tamil</family>
+                       <family>Meera</family>
+                       <family>Lohit Malayalam</family>
+                       <family>Lohit Kannada</family>
+                       <family>Lohit Telugu</family>
+                       <family>Lohit Oriya</family>
+                       <family>LKLUG</family>
+               </prefer>
+       </alias>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/69-unifont.conf b/tools/windows_packaging/mingw64/fonts/conf.d/69-unifont.conf
new file mode 100644 (file)
index 0000000..177dec5
--- /dev/null
@@ -0,0 +1,28 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+       <alias>
+               <family>serif</family>
+               <prefer>
+                       <family>FreeSerif</family>
+                       <family>Code2000</family>
+                       <family>Code2001</family> <!-- plane1 and beyond -->
+               </prefer>
+       </alias>
+       <alias>
+               <family>sans-serif</family>
+               <prefer>
+                       <family>FreeSans</family>
+                       <family>Arial Unicode MS</family>
+                       <family>Arial Unicode</family>
+                       <family>Code2000</family> <!-- almost everything; serif actually -->
+                       <family>Code2001</family> <!-- plane1 and beyond -->
+               </prefer>
+       </alias>
+       <alias>
+               <family>monospace</family>
+               <prefer>
+                       <family>FreeMono</family>
+               </prefer>
+       </alias>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/80-delicious.conf b/tools/windows_packaging/mingw64/fonts/conf.d/80-delicious.conf
new file mode 100644 (file)
index 0000000..728f50c
--- /dev/null
@@ -0,0 +1,19 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- Fix-ups for Delicious family -->
+
+<!-- Delicious 'heavy' variant says its Medium weight -->
+<match target="scan">
+       <test name="family">
+               <string>Delicious</string>
+       </test>
+       <test name="style">
+               <string>Heavy</string>
+       </test>
+       <edit name="weight">
+               <const>heavy</const>
+       </edit>
+</match>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/90-synthetic.conf b/tools/windows_packaging/mingw64/fonts/conf.d/90-synthetic.conf
new file mode 100644 (file)
index 0000000..b8d1e85
--- /dev/null
@@ -0,0 +1,64 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+<!-- 
+ Artificial oblique for fonts without an italic or oblique version
+ -->
+       <match target="font">
+               <!-- check to see if the font is roman -->
+               <test name="slant">
+                       <const>roman</const>
+               </test>
+               <!-- check to see if the pattern requested non-roman -->
+               <test target="pattern" name="slant" compare="not_eq">
+                       <const>roman</const>
+               </test>
+               <!-- multiply the matrix to slant the font -->
+               <edit name="matrix" mode="assign">
+                       <times>
+                               <name>matrix</name>
+                               <matrix><double>1</double><double>0.2</double>
+                                       <double>0</double><double>1</double>
+                               </matrix>
+                       </times>
+               </edit>
+               <!-- pretend the font is oblique now -->
+               <edit name="slant" mode="assign">
+                       <const>oblique</const>
+               </edit>
+               <!-- and disable embedded bitmaps for artificial oblique -->
+               <edit name="embeddedbitmap" mode="assign">
+                       <bool>false</bool>
+               </edit>
+       </match>
+
+<!--
+ Synthetic emboldening for fonts that do not have bold face available
+ -->
+
+       <match target="font">
+               <!-- check to see if the font is just regular -->
+               <test name="weight" compare="less_eq">
+                       <const>medium</const>
+               </test>
+               <!-- check to see if the pattern requests bold -->
+               <test target="pattern" name="weight" compare="more">
+                       <const>medium</const>
+               </test>
+               <!--
+                 set the embolden flag
+                 needed for applications using cairo, e.g. gucharmap, gedit, ...
+               -->
+               <edit name="embolden" mode="assign">
+                       <bool>true</bool>
+               </edit>
+               <!--
+                set weight to bold
+                needed for applications using Xft directly, e.g. Firefox, ...
+               -->
+               <edit name="weight" mode="assign">
+                       <const>bold</const>
+               </edit>
+       </match>
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/conf.d/README b/tools/windows_packaging/mingw64/fonts/conf.d/README
new file mode 100644 (file)
index 0000000..c2fb52c
--- /dev/null
@@ -0,0 +1,23 @@
+conf.d/README
+
+Each file in this directory is a fontconfig configuration file.  Fontconfig
+scans this directory, loading all files of the form [0-9][0-9]*.conf.
+These files are normally installed in ../conf.avail and then symlinked here,
+allowing them to be easily installed and then enabled/disabled by adjusting
+the symlinks.
+
+The files are loaded in numeric order, the structure of the configuration
+has led to the following conventions in usage:
+
+ Files begining with:  Contain:
+ 00 through 09         Font directories
+ 10 through 19         system rendering defaults (AA, etc)
+ 20 through 29         font rendering options
+ 30 through 39         family substitution
+ 40 through 49         generic identification, map family->generic
+ 50 through 59         alternate config file loading
+ 60 through 69         generic aliases, map generic->family
+ 70 through 79         select font (adjust which fonts are available)
+ 80 through 89         match target="scan" (modify scanned patterns)
+ 90 through 99         font synthesis
diff --git a/tools/windows_packaging/mingw64/fonts/fonts.conf b/tools/windows_packaging/mingw64/fonts/fonts.conf
new file mode 100644 (file)
index 0000000..6f5fe4b
--- /dev/null
@@ -0,0 +1,151 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<!-- /etc/fonts/fonts.conf file to configure system font access -->
+<fontconfig>
+
+<!--
+       DO NOT EDIT THIS FILE.
+       IT WILL BE REPLACED WHEN FONTCONFIG IS UPDATED.
+       LOCAL CHANGES BELONG IN 'local.conf'.
+
+       The intent of this standard configuration file is to be adequate for
+       most environments.  If you have a reasonably normal environment and
+       have found problems with this configuration, they are probably
+       things that others will also want fixed.  Please submit any
+       problems to the fontconfig bugzilla system located at fontconfig.org
+
+       Note that the normal 'make install' procedure for fontconfig is to
+       replace any existing fonts.conf file with the new version.  Place
+       any local customizations in local.conf which this file references.
+
+       Keith Packard
+-->
+
+<!-- Font directory list -->
+
+       <dir>WINDOWSFONTDIR</dir>
+       
+       <dir>~/.fonts</dir>
+
+<!--
+  Accept deprecated 'mono' alias, replacing it with 'monospace'
+-->
+       <match target="pattern">
+               <test qual="any" name="family">
+                       <string>mono</string>
+               </test>
+               <edit name="family" mode="assign">
+                       <string>monospace</string>
+               </edit>
+       </match>
+
+<!--
+  Accept alternate 'sans serif' spelling, replacing it with 'sans-serif'
+-->
+       <match target="pattern">
+               <test qual="any" name="family">
+                       <string>sans serif</string>
+               </test>
+               <edit name="family" mode="assign">
+                       <string>sans-serif</string>
+               </edit>
+       </match>
+
+<!--
+  Accept deprecated 'sans' alias, replacing it with 'sans-serif'
+-->
+       <match target="pattern">
+               <test qual="any" name="family">
+                       <string>sans</string>
+               </test>
+               <edit name="family" mode="assign">
+                       <string>sans-serif</string>
+               </edit>
+       </match>
+
+<!--
+  Load local system customization file
+-->
+       <include ignore_missing="yes">conf.d</include>
+
+<!-- Font cache directory list -->
+
+       <cachedir>WINDOWSTEMPDIR_FONTCONFIG_CACHE</cachedir>
+       <cachedir>~/.fontconfig</cachedir>
+
+       <config>
+<!--
+  These are the default Unicode chars that are expected to be blank
+  in fonts.  All other blank chars are assumed to be broken and
+  won't appear in the resulting charsets
+ -->
+               <blank>
+                       <int>0x0020</int>       <!-- SPACE -->
+                       <int>0x00A0</int>       <!-- NO-BREAK SPACE -->
+                       <int>0x00AD</int>       <!-- SOFT HYPHEN -->
+                       <int>0x034F</int>       <!-- COMBINING GRAPHEME JOINER -->
+                       <int>0x0600</int>       <!-- ARABIC NUMBER SIGN -->
+                       <int>0x0601</int>       <!-- ARABIC SIGN SANAH -->
+                       <int>0x0602</int>       <!-- ARABIC FOOTNOTE MARKER -->
+                       <int>0x0603</int>       <!-- ARABIC SIGN SAFHA -->
+                       <int>0x06DD</int>       <!-- ARABIC END OF AYAH -->
+                       <int>0x070F</int>       <!-- SYRIAC ABBREVIATION MARK -->
+                       <int>0x115F</int>       <!-- HANGUL CHOSEONG FILLER -->
+                       <int>0x1160</int>       <!-- HANGUL JUNGSEONG FILLER -->
+                       <int>0x1680</int>       <!-- OGHAM SPACE MARK -->
+                       <int>0x17B4</int>       <!-- KHMER VOWEL INHERENT AQ -->
+                       <int>0x17B5</int>       <!-- KHMER VOWEL INHERENT AA -->
+                       <int>0x180E</int>       <!-- MONGOLIAN VOWEL SEPARATOR -->
+                       <int>0x2000</int>       <!-- EN QUAD -->
+                       <int>0x2001</int>       <!-- EM QUAD -->
+                       <int>0x2002</int>       <!-- EN SPACE -->
+                       <int>0x2003</int>       <!-- EM SPACE -->
+                       <int>0x2004</int>       <!-- THREE-PER-EM SPACE -->
+                       <int>0x2005</int>       <!-- FOUR-PER-EM SPACE -->
+                       <int>0x2006</int>       <!-- SIX-PER-EM SPACE -->
+                       <int>0x2007</int>       <!-- FIGURE SPACE -->
+                       <int>0x2008</int>       <!-- PUNCTUATION SPACE -->
+                       <int>0x2009</int>       <!-- THIN SPACE -->
+                       <int>0x200A</int>       <!-- HAIR SPACE -->
+                       <int>0x200B</int>       <!-- ZERO WIDTH SPACE -->
+                       <int>0x200C</int>       <!-- ZERO WIDTH NON-JOINER -->
+                       <int>0x200D</int>       <!-- ZERO WIDTH JOINER -->
+                       <int>0x200E</int>       <!-- LEFT-TO-RIGHT MARK -->
+                       <int>0x200F</int>       <!-- RIGHT-TO-LEFT MARK -->
+                       <int>0x2028</int>       <!-- LINE SEPARATOR -->
+                       <int>0x2029</int>       <!-- PARAGRAPH SEPARATOR -->
+                       <int>0x202A</int>       <!-- LEFT-TO-RIGHT EMBEDDING -->
+                       <int>0x202B</int>       <!-- RIGHT-TO-LEFT EMBEDDING -->
+                       <int>0x202C</int>       <!-- POP DIRECTIONAL FORMATTING -->
+                       <int>0x202D</int>       <!-- LEFT-TO-RIGHT OVERRIDE -->
+                       <int>0x202E</int>       <!-- RIGHT-TO-LEFT OVERRIDE -->
+                       <int>0x202F</int>       <!-- NARROW NO-BREAK SPACE -->
+                       <int>0x205F</int>       <!-- MEDIUM MATHEMATICAL SPACE -->
+                       <int>0x2060</int>       <!-- WORD JOINER -->
+                       <int>0x2061</int>       <!-- FUNCTION APPLICATION -->
+                       <int>0x2062</int>       <!-- INVISIBLE TIMES -->
+                       <int>0x2063</int>       <!-- INVISIBLE SEPARATOR -->
+                       <int>0x206A</int>       <!-- INHIBIT SYMMETRIC SWAPPING -->
+                       <int>0x206B</int>       <!-- ACTIVATE SYMMETRIC SWAPPING -->
+                       <int>0x206C</int>       <!-- INHIBIT ARABIC FORM SHAPING -->
+                       <int>0x206D</int>       <!-- ACTIVATE ARABIC FORM SHAPING -->
+                       <int>0x206E</int>       <!-- NATIONAL DIGIT SHAPES -->
+                       <int>0x206F</int>       <!-- NOMINAL DIGIT SHAPES -->
+                       <int>0x2800</int>       <!-- BRAILLE PATTERN BLANK -->
+                       <int>0x3000</int>       <!-- IDEOGRAPHIC SPACE -->
+                       <int>0x3164</int>       <!-- HANGUL FILLER -->
+                       <int>0xFEFF</int>       <!-- ZERO WIDTH NO-BREAK SPACE -->
+                       <int>0xFFA0</int>       <!-- HALFWIDTH HANGUL FILLER -->
+                       <int>0xFFF9</int>       <!-- INTERLINEAR ANNOTATION ANCHOR -->
+                       <int>0xFFFA</int>       <!-- INTERLINEAR ANNOTATION SEPARATOR -->
+                       <int>0xFFFB</int>       <!-- INTERLINEAR ANNOTATION TERMINATOR -->
+               </blank>
+<!--
+  Rescan configuration every 30 seconds when FcFontSetList is called
+ -->
+               <rescan>
+                       <int>30</int>
+               </rescan>
+       </config>
+
+</fontconfig>
diff --git a/tools/windows_packaging/mingw64/fonts/fonts.dtd b/tools/windows_packaging/mingw64/fonts/fonts.dtd
new file mode 100644 (file)
index 0000000..cbdfdab
--- /dev/null
@@ -0,0 +1,224 @@
+<!-- This is the Document Type Definition for font configuration files -->
+<!ELEMENT fontconfig (dir | 
+                     cache | 
+                     cachedir |
+                     include | 
+                     config |
+                     selectfont |
+                     match | 
+                     alias)* >
+
+<!-- 
+    Add a directory that provides fonts
+-->
+<!ELEMENT dir (#PCDATA)>
+<!ATTLIST dir xml:space (default|preserve) 'preserve'>
+
+<!--
+    Define the per-user file that holds cache font information.
+
+    If the filename begins with '~', it is replaced with the users
+    home directory path.
+-->
+<!ELEMENT cache (#PCDATA)>
+<!ATTLIST cache xml:space (default|preserve) 'preserve'>
+
+<!--
+    Add a directory that is searched for font cache files.
+    These hold per-directory cache data and are searched in
+    order for each directory. When writing cache files, the first
+    directory which allows the cache file to be created is used.
+
+    A leading '~' in a directory name is replaced with the users
+    home directory path.
+-->
+<!ELEMENT cachedir (#PCDATA)>
+<!ATTLIST cachedir xml:space (default|preserve) 'preserve'>
+
+<!--
+    Reference another configuration file; note that this
+    is another complete font configuration file and not
+    just a file included by the XML parser.
+
+    Set 'ignore_missing' to 'yes' if errors are to be ignored.
+
+    If the filename begins with '~', it is replaced with the users
+    home directory path.
+-->
+<!ELEMENT include (#PCDATA)>
+<!ATTLIST include
+         ignore_missing    (no|yes)            "no"
+         xml:space         (default|preserve)  "preserve">
+
+<!--
+    Global library configuration data
+ -->
+<!ELEMENT config (blank|rescan)*>
+
+<!--
+    Specify the set of Unicode encoding values which
+    represent glyphs that are allowed to contain no
+    data.  With this list, fontconfig can examine
+    fonts for broken glyphs and eliminate them from
+    the set of valid Unicode chars.  This idea
+    was borrowed from Mozilla
+ -->
+<!ELEMENT blank (int)*>
+
+<!--
+    Aliases are just a special case for multiple match elements
+
+    They are syntactically equivalent to:
+
+    <match>
+       <test name="family">
+           <string value=[family]/>
+       </test>
+       <edit name="family" mode="prepend">
+           <string value=[prefer]/>
+           ...
+       </edit>
+       <edit name="family" mode="append">
+           <string value=[accept]/>
+           ...
+       </edit>
+       <edit name="family" mode="append_last">
+           <string value=[default]/>
+           ...
+       </edit>
+    </match>
+-->
+<!--
+    Periodically rescan the font configuration and
+    directories to synch internal state with filesystem
+ -->
+<!ELEMENT rescan (int)>
+
+<!--
+    Edit list of available fonts at startup/reload time
+ -->
+<!ELEMENT selectfont (rejectfont | acceptfont)* >
+
+<!ELEMENT rejectfont (glob | pattern)*>
+
+<!ELEMENT acceptfont (glob | pattern)*>
+
+<!ELEMENT glob (#PCDATA)>
+
+<!ELEMENT pattern (patelt)*>
+
+<!ENTITY % constant 'int|double|string|matrix|bool|charset|const'>
+
+<!ELEMENT patelt (%constant;)*>
+<!ATTLIST patelt
+         name CDATA    #REQUIRED>
+
+<!ELEMENT alias (family*, prefer?, accept?, default?)>
+<!ATTLIST alias
+         binding (weak|strong|same) "weak">
+<!ELEMENT prefer (family)*>
+<!ELEMENT accept (family)*>
+<!ELEMENT default (family)*>
+<!ELEMENT family (#PCDATA)>
+<!ATTLIST family xml:space (default|preserve) 'preserve'>
+
+<!ENTITY % expr 'int|double|string|matrix|bool|charset
+               |name|const
+               |or|and|eq|not_eq|less|less_eq|more|more_eq|contains|not_contains
+               |plus|minus|times|divide|not|if|floor|ceil|round|trunc'>
+
+<!--
+    Match and edit patterns.
+
+    If 'target' is 'pattern', execute the match before selecting a font.
+    if 'target' is 'font', execute the match on the result of a font
+    selection.
+-->
+<!ELEMENT match (test*, edit*)>
+<!ATTLIST match
+         target (pattern|font|scan) "pattern">
+
+<!--
+    Match a field in a pattern
+
+    if 'qual' is 'any', then the match succeeds if any value in the field matches.
+    if 'qual' is 'all', then the match succeeds only if all values match.
+    if 'qual' is 'first', then the match succeeds only if the first value matches.
+    if 'qual' is 'not_first', then the match succeeds only if any value other than
+       the first matches.
+    For match elements with target=font, if test 'target' is 'pattern',
+    then the test is applied to the pattern used in matching rather than
+    to the resulting font.
+
+    Match elements with target=scan are applied as fonts are scanned.
+    They edit the pattern generated from the scanned font and affect
+    what the fontconfig database contains.
+-->
+<!ELEMENT test (%expr;)*>
+<!ATTLIST test 
+         qual (any|all|first|not_first)    "any"
+         name CDATA        #REQUIRED
+         target (pattern|font|default)         "default"
+         compare (eq|not_eq|less|less_eq|more|more_eq|contains|not_contains)   "eq">
+
+<!--
+    Edit a field in a pattern
+
+    The enclosed values are used together to edit the list of values
+    associated with 'name'.
+
+    If 'name' matches one of those used in a test element for this match element:
+       if 'mode' is 'assign', replace the matched value.
+       if 'mode' is 'assign_replace', replace all of the values
+       if 'mode' is 'prepend', insert before the matched value
+       if 'mode' is 'append', insert after the matched value
+       if 'mode' is 'prepend_first', insert before all of the values
+       if 'mode' is 'append_last', insert after all of the values
+    If 'name' doesn't match any of those used in a test element:
+       if 'mode' is 'assign' or 'assign_replace, replace all of the values
+       if 'mode' is 'prepend' or 'prepend_first', insert before all of the values
+       if 'mode' is 'append' or 'append_last', insert after all of the values
+-->
+<!ELEMENT edit (%expr;)*>
+<!ATTLIST edit
+         name CDATA        #REQUIRED
+         mode (assign|assign_replace|prepend|append|prepend_first|append_last) "assign"
+         binding (weak|strong|same) "weak">
+
+<!--
+    Elements of expressions follow
+-->
+<!ELEMENT int (#PCDATA)>
+<!ATTLIST int xml:space (default|preserve) 'preserve'>
+<!ELEMENT double (#PCDATA)>
+<!ATTLIST double xml:space (default|preserve) 'preserve'>
+<!ELEMENT string (#PCDATA)>
+<!ATTLIST string xml:space (default|preserve) 'preserve'>
+<!ELEMENT matrix (double,double,double,double)>
+<!ELEMENT bool (#PCDATA)>
+<!ELEMENT charset (#PCDATA)>
+<!ATTLIST charset xml:space (default|preserve) 'preserve'>
+<!ELEMENT name (#PCDATA)>
+<!ATTLIST name xml:space (default|preserve) 'preserve'>
+<!ELEMENT const (#PCDATA)>
+<!ATTLIST const xml:space (default|preserve) 'preserve'>
+<!ELEMENT or (%expr;)*>
+<!ELEMENT and (%expr;)*>
+<!ELEMENT eq ((%expr;), (%expr;))>
+<!ELEMENT not_eq ((%expr;), (%expr;))>
+<!ELEMENT less ((%expr;), (%expr;))>
+<!ELEMENT less_eq ((%expr;), (%expr;))>
+<!ELEMENT more ((%expr;), (%expr;))>
+<!ELEMENT more_eq ((%expr;), (%expr;))>
+<!ELEMENT contains ((%expr;), (%expr;))>
+<!ELEMENT not_contains ((%expr;), (%expr;))>
+<!ELEMENT plus (%expr;)*>
+<!ELEMENT minus (%expr;)*>
+<!ELEMENT times (%expr;)*>
+<!ELEMENT divide (%expr;)*>
+<!ELEMENT not (%expr;)>
+<!ELEMENT if ((%expr;), (%expr;), (%expr;))>
+<!ELEMENT floor (%expr;)>
+<!ELEMENT ceil (%expr;)>
+<!ELEMENT round (%expr;)>
+<!ELEMENT trunc (%expr;)>
diff --git a/tools/windows_packaging/mingw64/gtk-2.0/gtk.immodules b/tools/windows_packaging/mingw64/gtk-2.0/gtk.immodules
new file mode 100644 (file)
index 0000000..3eaf413
--- /dev/null
@@ -0,0 +1,39 @@
+# GTK+ Input Method Modules file\r
+# Automatically generated file, do not edit\r
+# Created by c:/Users/VKamyshniy/gtk/source/gtk+-2.24.18/gtk/.libs/gtk-query-immodules-2.0.exe from gtk+-2.24.18\r
+#\r
+# ModulesPath = c:\Users\VKamyshniy\.gtk-2.0\2.10.0\i686-pc-mingw32\immodules;c:\Users\VKamyshniy\.gtk-2.0\2.10.0\immodules;c:\Users\VKamyshniy\.gtk-2.0\i686-pc-mingw32\immodules;c:\Users\VKamyshniy\.gtk-2.0\immodules;c:/Users/VKamyshniy/gtk/inst/lib\gtk-2.0\2.10.0\i686-pc-mingw32\immodules;c:/Users/VKamyshniy/gtk/inst/lib\gtk-2.0\2.10.0\immodules;c:/Users/VKamyshniy/gtk/inst/lib\gtk-2.0\i686-pc-mingw32\immodules;c:/Users/VKamyshniy/gtk/inst/lib\gtk-2.0\immodules\r
+#\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-am-et.dll" \r
+"am_et" "Amharic (EZ+)" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "am" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-cedilla.dll" \r
+"cedilla" "Cedilla" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "az:ca:co:fr:gv:oc:pt:sq:tr:wa" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-cyrillic-translit.dll" \r
+"cyrillic_translit" "Cyrillic (Transliterated)" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-ime.dll" \r
+"ime" "Windows IME" "gtk+" "" "ja:ko:zh" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-inuktitut.dll" \r
+"inuktitut" "Inuktitut (Transliterated)" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "iu" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-ipa.dll" \r
+"ipa" "IPA" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-multipress.dll" \r
+"multipress" "Multipress" "gtk20" "" "" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-thai.dll" \r
+"thai" "Thai-Lao" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "lo:th" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-ti-er.dll" \r
+"ti_er" "Tigrigna-Eritrean (EZ+)" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "ti" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-ti-et.dll" \r
+"ti_et" "Tigrigna-Ethiopian (EZ+)" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "ti" \r
+\r
+"c:/Users/VKamyshniy/gtk/inst/lib/gtk-2.0/2.10.0/immodules/im-viqr.dll" \r
+"viqr" "Vietnamese (VIQR)" "gtk20" "/Users/VKamyshniy/gtk/inst/share/locale" "vi" \r
+\r
diff --git a/tools/windows_packaging/mingw64/gtk-2.0/im-multipress.conf b/tools/windows_packaging/mingw64/gtk-2.0/im-multipress.conf
new file mode 100644 (file)
index 0000000..d6c8129
--- /dev/null
@@ -0,0 +1,22 @@
+# Example configuration file for the GTK+ Multipress Input Method
+# Authored by Openismus GmbH, 2009.
+#
+# This file follows the GKeyFile format.  On the left of the equal sign goes
+# the key that you press repeatedly to iterate through the text items listed
+# on the right-hand side.  The list items are separated by semicolons ";" and
+# consist of one or more characters each.  The backslash "\" is used to escape
+# characters; for instance "\;" for a literal semicolon.
+#
+# The example configuration below imitates the behavior of a standard mobile
+# phone by a major manufacturer, with German language setting.
+[keys]
+KP_1 = .;,;?;!;';";1;-;(;);@;/;:;_
+KP_2 = a;b;c;2;ä;à;á;ã;â;å;æ;ç
+KP_3 = d;e;f;3;è;é;ë;ê;ð
+KP_4 = g;h;i;4;ì;í;î;ï
+KP_5 = j;k;l;5;£
+KP_6 = m;n;o;6;ö;ò;ó;ô;õ;ø;ñ
+KP_7 = p;q;r;s;7;ß;$
+KP_8 = t;u;v;8;ü;ù;ú;û
+KP_9 = w;x;y;z;9;ý;þ
+KP_0 = \s;0
diff --git a/tools/windows_packaging/mingw64/pango/pango.modules b/tools/windows_packaging/mingw64/pango/pango.modules
new file mode 100644 (file)
index 0000000..1920229
--- /dev/null
@@ -0,0 +1,35 @@
+# Pango Modules file\r
+# Automatically generated file, do not edit\r
+#\r
+# ModulesPath = c:/Users/VKamyshniy/gtk/inst/lib/pango\1.6.0\modules\r
+#\r
+"./lib/pango/1.6.0/modules/pango-arabic-fc.dll" ArabicScriptEngineFc PangoEngineShape PangoRenderFc arabic:* nko:*\r
+"./lib/pango/1.6.0/modules/pango-arabic-lang.dll" ArabicScriptEngineLang PangoEngineLang PangoRenderNone arabic:*\r
+"./lib/pango/1.6.0/modules/pango-basic-fc.dll" BasicScriptEngineFc PangoEngineShape PangoRenderFc latin:* cyrillic:* greek:* armenian:* georgian:* runic:* ogham:* bopomofo:* cherokee:* coptic:* deseret:* ethiopic:* gothic:* han:* hiragana:* katakana:* old-italic:* canadian-aboriginal:* yi:* braille:* cypriot:* limbu:* osmanya:* shavian:* linear-b:* ugaritic:* glagolitic:* cuneiform:* phoenician:* common:\r
+"./lib/pango/1.6.0/modules/pango-basic-win32.dll" BasicScriptEngineWin32 PangoEngineShape PangoRenderWin32 common:\r
+"./lib/pango/1.6.0/modules/pango-hangul-fc.dll" HangulScriptEngineFc PangoEngineShape PangoRenderFc hangul:*\r
+"./lib/pango/1.6.0/modules/pango-hebrew-fc.dll" HebrewScriptEngineFc PangoEngineShape PangoRenderFc hebrew:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" devaScriptEngineFc PangoEngineShape PangoRenderFc devanagari:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" bengScriptEngineFc PangoEngineShape PangoRenderFc bengali:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" guruScriptEngineFc PangoEngineShape PangoRenderFc gurmukhi:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" gujrScriptEngineFc PangoEngineShape PangoRenderFc gujarati:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" oryaScriptEngineFc PangoEngineShape PangoRenderFc oriya:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" tamlScriptEngineFc PangoEngineShape PangoRenderFc tamil:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" teluScriptEngineFc PangoEngineShape PangoRenderFc telugu:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" kndaScriptEngineFc PangoEngineShape PangoRenderFc kannada:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" mlymScriptEngineFc PangoEngineShape PangoRenderFc malayalam:*\r
+"./lib/pango/1.6.0/modules/pango-indic-fc.dll" sinhScriptEngineFc PangoEngineShape PangoRenderFc sinhala:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" devaIndicScriptEngineLang PangoEngineLang PangoRenderNone devanagari:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" bengIndicScriptEngineLang PangoEngineLang PangoRenderNone bengali:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" guruIndicScriptEngineLang PangoEngineLang PangoRenderNone gurmukhi:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" gujrIndicScriptEngineLang PangoEngineLang PangoRenderNone gujarati:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" oryaIndicScriptEngineLang PangoEngineLang PangoRenderNone oriya:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" tamlIndicScriptEngineLang PangoEngineLang PangoRenderNone tamil:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" teluIndicScriptEngineLang PangoEngineLang PangoRenderNone telugu:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" kndaIndicScriptEngineLang PangoEngineLang PangoRenderNone kannada:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" mlymIndicScriptEngineLang PangoEngineLang PangoRenderNone malayalam:*\r
+"./lib/pango/1.6.0/modules/pango-indic-lang.dll" sinhIndicScriptEngineLang PangoEngineLang PangoRenderNone sinhala:*\r
+"./lib/pango/1.6.0/modules/pango-khmer-fc.dll" KhmerScriptEngineFc PangoEngineShape PangoRenderFc khmer:*\r
+"./lib/pango/1.6.0/modules/pango-syriac-fc.dll" SyriacScriptEngineFc PangoEngineShape PangoRenderFc syriac:*\r
+"./lib/pango/1.6.0/modules/pango-thai-fc.dll" ThaiScriptEngineFc PangoEngineShape PangoRenderFc thai:* lao:*\r
+"./lib/pango/1.6.0/modules/pango-tibetan-fc.dll" TibetanScriptEngineFc PangoEngineShape PangoRenderFc tibetan:*\r
index 92f55e890669f9eae6aa1ada500c17750a848ce1..dd1ec881196a09ee7db8defee11f0a66c9cec2ef 100755 (executable)
@@ -54,6 +54,8 @@ mkdir -p $PACKAGE_DIR/lib/pango/1.6.0/modules
 cp -r $MINGW_ROOT/lib/pango/1.6.0/modules/*.dll $PACKAGE_DIR/lib/pango/1.6.0/modules
 cp $TOOLS_DIR/pango.modules $PACKAGE_DIR/etc/pango
 
+cp $TOOLS_DIR/README $PACKAGE_DIR
+
 DLLS='
 jack-0.dll
 jackserver-0.dll
@@ -144,7 +146,7 @@ libs/timecode
 libs/audiographer
 '
 
-if test x$DEBUG != x ; then
+if [ x$DEBUG = xT ]; then
 
        PACKAGE_SRC_DIR=$PACKAGE_DIR/src
        echo "Copying source files to $PACKAGE_SRC_DIR ..."
@@ -158,20 +160,21 @@ if test x$DEBUG != x ; then
        echo "Copying JACK utility programs to $PACKAGE_DIR ..."
        cp $MINGW_ROOT/bin/jack_*.exe $PACKAGE_DIR
 
-       echo "Copying any debug files to $PACKAGE_DIR ..."
-       cp $MINGW_ROOT/bin/*.debug $PACKAGE_DIR
+       #echo "Copying any debug files to $PACKAGE_DIR ..."
+       #cp $MINGW_ROOT/bin/*.debug $PACKAGE_DIR
 
-       echo "Copying gdb to $PACKAGE_DIR ..."
+       echo "Copying gdb and config files to $PACKAGE_DIR ..."
        cp $MINGW_ROOT/bin/gdb.exe $PACKAGE_DIR
-
-       echo "Copying .gdbinit to $PACKAGE_DIR ..."
        cp $TOOLS_DIR/gdbinit $PACKAGE_DIR/.gdbinit
+       cp $TOOLS_DIR/gdbinit_home $PACKAGE_DIR/gdbinit_home
+       cp $TOOLS_DIR/gdb.bat $PACKAGE_DIR/gdb.bat
+       cp $TOOLS_DIR/gdb-ardour.bat $PACKAGE_DIR/gdb-ardour.bat
 
        echo "Copying Gtk demo to $PACKAGE_DIR ..."
        cp $MINGW_ROOT/bin/gtk-demo.exe $PACKAGE_DIR
 else
        echo "Optimized build Stripping executable ..."
-       $STRIP $PACKAGE_DIR/ardour-3.0.exe
+       find $PACKAGE_DIR -type f -name "*.exe*" | xargs $STRIP
        echo "Stripping libraries ..."
        find $PACKAGE_DIR -type f -name "*.dll*" | xargs $STRIP
 fi
diff --git a/tools/windows_packaging/package_win32.sh b/tools/windows_packaging/package_win32.sh
new file mode 100755 (executable)
index 0000000..5ef6c17
--- /dev/null
@@ -0,0 +1,242 @@
+#!/bin/bash\r
+function copydll () {\r
+       if [ -f $GTK/bin/$1 ] ; then\r
+               echo "cp $GTK/bin/$1 $2"\r
+               cp $GTK/bin/$1 $2 || return 1\r
+               return 0\r
+       fi\r
+       \r
+       if [ -f $GTK/lib/$1 ] ; then\r
+               echo "cp $GTK/lib/$1 $2"\r
+               cp $GTK/lib/$1 $2 || return 1\r
+               return 0\r
+       fi\r
+       \r
+       if [ -f $A3/bin/$1 ] ; then\r
+               echo "cp $A3/bin/$1 $2"\r
+               cp $A3/bin/$1 $2 || return 1\r
+               return 0\r
+       fi\r
+\r
+       if [ -f $A3/lib/$1 ] ; then\r
+               echo "$A3/lib/$1 $2"\r
+               cp $A3/lib/$1 $2 || return 1\r
+               return 0\r
+       fi\r
+       if which $1 ; then        \r
+         echo "cp `which $1` $2"\r
+         cp `which $1` $2 || return 1\r
+         return 0\r
+       fi\r
+       \r
+       echo "there is no $1"\r
+       return 1\r
+}\r
+\r
+# libcrypto-10.dll -- OOPS\r
+# libgnomecanvasmm-2.6-1.dll -- OOPS\r
+# iconv.dll == libiconv-2.dll\r
+# libpng15-15.dll == libpng16-16.dll\r
+# liblo-7.dll == liblo.dll\r
+\r
+ABANDONEDDLLS='\r
+jack-0.dll\r
+jackserver-0.dll\r
+libbz2-1.dll\r
+libcppunit-1-12-1.dll\r
+libexpat-1.dll\r
+libgnurx-0.dll\r
+libharfbuzz-0.dll\r
+libFLAC-8.dll\r
+libvorbis-0.dll\r
+libvorbisenc-2.dll\r
+libidn-11.dll\r
+libssh2-1.dll\r
+libssl-10.dll\r
+pthreadGC2.dll\r
+'\r
+\r
+DLLS='\r
+libiconv-2.dll\r
+libpng16-16.dll\r
+liblo.dll\r
+libart_lgpl_2-2.dll\r
+libatk-1.0-0.dll\r
+libatkmm-1.6-1.dll\r
+libcairo-2.dll\r
+libcairo-gobject-2.dll\r
+libcairomm-1.0-1.dll\r
+libcairo-script-interpreter-2.dll\r
+libcurl-4.dll\r
+libfftw3-3.dll\r
+libfftw3f-3.dll\r
+libfontconfig-1.dll\r
+libfreetype-6.dll\r
+libgailutil-18.dll\r
+libgdkmm-2.4-1.dll\r
+libgdk_pixbuf-2.0-0.dll\r
+libgdk-win32-2.0-0.dll\r
+libgio-2.0-0.dll\r
+libgiomm-2.4-1.dll\r
+libglib-2.0-0.dll\r
+libglibmm-2.4-1.dll\r
+libglibmm_generate_extra_defs-2.4-1.dll\r
+libgmodule-2.0-0.dll\r
+libgnomecanvas-2-0.dll\r
+libgobject-2.0-0.dll\r
+libgthread-2.0-0.dll\r
+libgtkmm-2.4-1.dll\r
+libgtk-win32-2.0-0.dll\r
+libiconv-2.dll\r
+libogg-0.dll\r
+libffi-6.dll\r
+libintl-8.dll\r
+libpango-1.0-0.dll\r
+libpangocairo-1.0-0.dll\r
+libpangoft2-1.0-0.dll\r
+libpangomm-1.4-1.dll\r
+libpangowin32-1.0-0.dll\r
+libpixman-1-0.dll\r
+libsamplerate-0.dll\r
+libsigc-2.0-0.dll\r
+libsndfile-1.dll\r
+libxml2-2.dll\r
+zlib1.dll\r
+libstdc++-6.dll\r
+libgcc_s_sjlj-1.dll\r
+libwinpthread-1.dll\r
+libeay32.dll\r
+ssleay32.dll\r
+libregex-1.dll\r
+libportaudio-2.dll\r
+'\r
+. ./win32-env.sh\r
+. ./print-env.sh\r
+\r
+cd $BASE || exit 1\r
+\r
+if ! test -f $BUILD_CACHE_FILE; then\r
+       echo "ERROR: $APPNAME is not configured and built yet..."\r
+       exit 1\r
+fi\r
+\r
+if [ -d $PACKAGE_DIR ]; then\r
+       echo "Removing old package directory structure ..."\r
+       rm -rf $PACKAGE_DIR || exit 1\r
+fi\r
+echo "./waf --destdir=$PACKAGE_DIR install"\r
+\r
+./waf --destdir=$PACKAGE_DIR install || exit 1\r
+\r
+echo "Moving everything from $PACKAGE_DIR/msys to $PACKAGE_DIR ..."\r
+mv $PACKAGE_DIR/msys/* $PACKAGE_DIR || exit 1\r
+rmdir $PACKAGE_DIR/msys || exit 1\r
+\r
+\r
+echo "Moving Ardour dll's and executable to $PACKAGE_DIR ..."\r
+\r
+echo "mv $PACKAGE_DIR/lib/ardour3/*.dll $PACKAGE_DIR"\r
+echo "mv $PACKAGE_DIR/lib/ardour3/*.exe $PACKAGE_DIR"\r
+\r
+mv $PACKAGE_DIR/lib/ardour3/*.dll $PACKAGE_DIR || exit 1\r
+mv $PACKAGE_DIR/lib/ardour3/*.exe $PACKAGE_DIR || exit 1\r
+\r
+echo "Deleting import libs ..."\r
+\r
+rm $PACKAGE_DIR/lib/*dll.a || exit 1\r
+\r
+# delete sh script\r
+rm $PACKAGE_DIR/ardour3 || exit 1\r
+\r
+if test x$WITH_TESTS != x ; then\r
+       echo "Copying tests and test data to $PACKAGE_DIR ..."\r
+       cp $BUILD_DIR/libs/pbd/run-tests.exe $PACKAGE_DIR/pbd-run-tests.exe || exit 1\r
+       cp -r $BASE/libs/pbd/test $PACKAGE_DIR/pbd_testdata || exit 1\r
+\r
+       cp $BUILD_DIR/libs/evoral/run-tests.exe $PACKAGE_DIR/evoral-run-tests.exe || exit 1\r
+       mkdir -p $PACKAGE_DIR/test/testdata || exit 1\r
+       cp -r $BASE/libs/evoral/test/testdata/TakeFive.mid $PACKAGE_DIR/test/testdata || exit 1\r
+\r
+       cp -r $BASE/libs/ardour/test/data $PACKAGE_DIR/ardour_testdata || exit 1\r
+fi\r
+\r
+echo "Copying mingw config files to $PACKAGE_DIR ..."\r
+# just copy it all for now\r
+cp -r $MINGW_ROOT/etc $PACKAGE_DIR || exit 1\r
+\r
+cp -r $GTK/lib/gtk-2.0 $PACKAGE_DIR/lib || exit 1\r
+cp -r $GTK/lib/gdk-pixbuf-2.0 $PACKAGE_DIR/lib || exit 1\r
+cp $TOOLS_DIR/loaders.cache $PACKAGE_DIR/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache || exit 1\r
+\r
+mkdir -p $PACKAGE_DIR/lib/pango/1.6.0/modules || exit 1\r
+cp -r $GTK/lib/pango/1.6.0/modules/*.dll $PACKAGE_DIR/lib/pango/1.6.0/modules || exit 1\r
+\r
+cp -r $TOOLS_DIR/mingw64/* $PACKAGE_DIR/etc || exit 1\r
+\r
+echo "Copying mingw shared libraries to $PACKAGE_DIR ..."\r
+\r
+for i in $DLLS;\r
+do\r
+copydll "$i" "$PACKAGE_DIR" || exit 1\r
+done\r
+\r
+echo "Copying JACK server and drivers to $PACKAGE_DIR ..."\r
+\r
+# VK: -- FIXIT cp $MINGW_ROOT/bin/jackd.exe $PACKAGE_DIR || exit 1\r
+# VK: -- FIXIT cp -r $MINGW_ROOT/bin/jack $PACKAGE_DIR || exit 1\r
+# VK: -- FIXIT cp $MINGW_ROOT/bin/libportaudio-2.dll $PACKAGE_DIR || exit 1\r
+\r
+SRC_DIRS='\r
+libs/ardour\r
+libs/pbd\r
+libs/gtkmm2ext\r
+libs/midi++2\r
+libs/evoral\r
+libs/panners\r
+libs/timecode\r
+libs/audiographer\r
+'\r
+\r
+if test x$DEBUG != x ; then\r
+\r
+       PACKAGE_SRC_DIR=$PACKAGE_DIR/src\r
+       echo "Copying source files to $PACKAGE_SRC_DIR ..."\r
+       mkdir -p $PACKAGE_SRC_DIR/libs || exit 1\r
+       cp -r $BASE/gtk2_ardour $PACKAGE_SRC_DIR || exit 1\r
+       for i in $SRC_DIRS;\r
+       do\r
+       cp -r -p $BASE/$i $PACKAGE_SRC_DIR/libs || exit 1\r
+       done\r
+       \r
+       echo "Copying JACK utility programs to $PACKAGE_DIR ..."\r
+       # VK: -- FIXIT cp $MINGW_ROOT/bin/jack_*.exe $PACKAGE_DIR || exit 1\r
+\r
+       echo "Copying any debug files to $PACKAGE_DIR ..."\r
+       # VK: -- FIXIT cp $MINGW_ROOT/bin/*.debug $PACKAGE_DIR || exit 1\r
+\r
+       echo "Copying gdb to $PACKAGE_DIR ..."\r
+       cp $MINGW_ROOT/bin/gdb.exe $PACKAGE_DIR || exit 1\r
+\r
+       echo "Copying .gdbinit to $PACKAGE_DIR ..."\r
+       cp $TOOLS_DIR/gdbinit $PACKAGE_DIR/.gdbinit || exit 1\r
+\r
+       echo "Copying Gtk demo to $PACKAGE_DIR ..."\r
+       cp $GTK/bin/gtk-demo.exe $PACKAGE_DIR || exit 1\r
+else\r
+       echo "Optimized build Stripping executable ..."\r
+       $STRIP $PACKAGE_DIR/ardour-3.0.exe || exit 1\r
+       echo "Stripping libraries ..." || exit 1\r
+       find $PACKAGE_DIR -type f -name "*.dll*" | xargs $STRIP\r
+fi\r
+\r
+if [ "$1" == "--tarball" ]; then\r
+       echo "Creating tarball from $PACKAGE_DIR ..."\r
+       cd $BASE || exit 1\r
+       tar -cvJf $PACKAGE_DIR.tar.xz $PACKAGE_DIR || exit 1\r
+fi\r
+\r
+if [ "$1" == "--zip" ]; then\r
+       echo "Creating zip file from $PACKAGE_DIR ..."\r
+       cd $BASE || exit 1\r
+       zip -r $PACKAGE_DIR.zip $PACKAGE_DIR || exit 1\r
+fi\r
diff --git a/tools/windows_packaging/run-wine.sh b/tools/windows_packaging/run-wine.sh
deleted file mode 100755 (executable)
index 8641520..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/bin/bash
-
-. ./mingw-env.sh
-
-cd $BASE
-
-LIBS=$BUILD_DIR/libs
-
-export ARDOUR_PATH=$BASE/gtk2_ardour/icons:$BASE/gtk2_ardour/pixmaps:$BASE/build/default/gtk2_ardour:$BASE/gtk2_ardour:.
-export ARDOUR_SURFACES_PATH=$LIBS/surfaces/osc:$LIBS/surfaces/generic_midi:$LIBS/surfaces/tranzport:$LIBS/surfaces/powermate:$LIBS/surfaces/mackie
-export ARDOUR_PANNER_PATH=$LIBS/panners/2in2out:$LIBS/panners/1in2out:$LIBS/panners/vbap
-export ARDOUR_DATA_PATH=$BASE/gtk2_ardour:build/default/gtk2_ardour:.
-
-export VAMP_PATH=$LIBS/vamp-plugins${VAMP_PATH:+:$VAMP_PATH}
-
-export PBD_TEST_PATH=$BASE/libs/pbd/test/
-
-if test ! -d $PACKAGE_DIR; then
-       echo "Win32 package directory does not exist"
-       exit 1
-fi
-
-cd $PACKAGE_DIR 
-
-
-if [ "$1" == "--run-tests" ]; then
-       if test x$WITH_TESTS != x ; then
-               echo "<<<<<<<<<<<<<<<<<<  RUNNING LIBPBD TESTS >>>>>>>>>>>>>>>>>>>"
-               wine pbd-run-tests.exe
-               echo "<<<<<<<<<<<<<<<<<<  RUNNING EVORAL TESTS >>>>>>>>>>>>>>>>>>>"
-               wine evoral-run-tests.exe
-               echo "<<<<<<<<<<<<<<<<<<  RUNNING ARDOUR TESTS >>>>>>>>>>>>>>>>>>>"
-               wine ardour-run-tests.exe
-       else
-               echo "No tests to run ..."
-       fi
-else
-        wine ardour-3.0.exe
-fi
diff --git a/tools/windows_packaging/startvm.sh b/tools/windows_packaging/startvm.sh
deleted file mode 100755 (executable)
index de65be9..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/bash
-. mingw-env.sh
-
-qemu-kvm -smp 2 -m 1536 -hda $VIRT_IMAGE_PATH -net nic -net user -vga std -soundhw all
diff --git a/tools/windows_packaging/win32-env.sh b/tools/windows_packaging/win32-env.sh
new file mode 100755 (executable)
index 0000000..5bdf4d2
--- /dev/null
@@ -0,0 +1,54 @@
+#!/bin/bash\r
+\r
+BASE=$(readlink -f $0)\r
+BASE=$(dirname $BASE) # up one\r
+BASE=$(dirname $BASE) # up one more\r
+BASE=$(dirname $BASE) # up one more\r
+\r
+HOST=x86_64-w64-mingw32\r
+MINGW_ROOT=/mingw\r
+GTK=$HOME/gtk/inst\r
+A3=$HOME/A3/inst\r
+\r
+export PKG_CONFIG_PREFIX=$MINGW_ROOT\r
+export PKG_CONFIG_LIBDIR=$MINGW_ROOT/lib/pkgconfig\r
+export PKGCONFIG=pkg-config\r
+export AR=ar\r
+export RANLIB=ranlib\r
+export CC=gcc\r
+export CPP=g++\r
+export CXX=g++\r
+export AS=as\r
+export LINK_CC=gcc\r
+export LINK_CXX=g++\r
+export WINRC=windres\r
+export STRIP=strip\r
+\r
+BUILD_DIR=$BASE/build\r
+BUILD_CACHE_FILE=$BUILD_DIR/c4che/_cache.py\r
+TOOLS_DIR=$BASE/tools/windows_packaging\r
+\r
+. ../define_versions.sh\r
+\r
+APPNAME=`grep -m 1 '^APPNAME' $BASE/wscript | awk '{print $3}' | sed "s/'//g"`\r
+\r
+# These are only relevant after a build\r
+if test -f $BUILD_CACHE_FILE\r
+then\r
+       # Figure out the Build Type\r
+       if grep -q "DEBUG = True" $BUILD_CACHE_FILE; then\r
+               DEBUG=1\r
+               PACKAGE_DIR="$HOME/$APPNAME-win32-dbg"\r
+       else\r
+               PACKAGE_DIR="$HOME/$APPNAME-win32"\r
+       fi\r
+\r
+       if grep -q "BUILD_TESTS = True" $BUILD_CACHE_FILE; then\r
+               WITH_TESTS=1\r
+       fi\r
+\r
+       ARDOUR_DATA_DIR=$PACKAGE_DIR/msys/share/ardour3\r
+fi\r
+\r
+# put this somewhere better...\r
+VIRT_IMAGE_PATH=$HOME/Data/virt-images/winxp.raw\r
diff --git a/tools/windows_packaging/wine-ardour-tests.sh b/tools/windows_packaging/wine-ardour-tests.sh
new file mode 100755 (executable)
index 0000000..a4bd033
--- /dev/null
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+. ./wine-env.sh
+
+if [ "$1" == "--list" ]; then
+       TESTS='test_*'
+       for test_program in `find  -name "$TESTS" -type f -perm /u+x`;
+       do
+               echo "$test_program"
+       done
+       exit 0
+fi
+
+if [ "$1" == "--single" ] || [ "$2" == "--single" ]; then
+        if [ "$1" == "--single" ]; then
+               TESTS="test_*$2*"
+        elif [ "$2" == "--single" ]; then
+               TESTS="test_*$3*"
+       else
+                TESTS='test_*'
+        fi
+       for test_program in `find . -name "$TESTS" -type f -perm /u+x`;
+       do
+               echo "Running $test_program..."
+               wine "$test_program"
+       done
+else
+        wine run-tests.exe
+fi
diff --git a/tools/windows_packaging/wine-ardour.sh b/tools/windows_packaging/wine-ardour.sh
new file mode 100755 (executable)
index 0000000..cb65474
--- /dev/null
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+. ./wine-env.sh
+
+wine ardour-3.3.exe
diff --git a/tools/windows_packaging/wine-env.sh b/tools/windows_packaging/wine-env.sh
new file mode 100755 (executable)
index 0000000..95d0bf7
--- /dev/null
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+. ./mingw-env.sh
+
+cd $BASE
+
+if test ! -d $PACKAGE_DIR; then
+       echo "Win32 package directory does not exist"
+       exit 1
+fi
+
+LIBS=$BUILD_DIR/libs
+
+export ARDOUR_PATH=$BASE/gtk2_ardour/icons:$BASE/gtk2_ardour/pixmaps:$BASE/build/default/gtk2_ardour:$BASE/gtk2_ardour:.
+export ARDOUR_SURFACES_PATH=$LIBS/surfaces/osc:$LIBS/surfaces/generic_midi:$LIBS/surfaces/tranzport:$LIBS/surfaces/powermate:$LIBS/surfaces/mackie
+export ARDOUR_PANNER_PATH=$LIBS/panners/2in2out:$LIBS/panners/1in2out:$LIBS/panners/vbap
+export ARDOUR_DATA_PATH=$BASE/gtk2_ardour:build/default/gtk2_ardour:.
+
+export VAMP_PATH=$LIBS/vamp-plugins${VAMP_PATH:+:$VAMP_PATH}
+
+export PBD_TEST_PATH=$BASE/libs/pbd/test/
+
+cd $PACKAGE_DIR
diff --git a/tools/windows_packaging/wine-evoral-tests.sh b/tools/windows_packaging/wine-evoral-tests.sh
new file mode 100755 (executable)
index 0000000..50b77f7
--- /dev/null
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+. ./wine-env.sh
+
+wine evoral-run-tests.exe
diff --git a/tools/windows_packaging/wine-pbd-tests.sh b/tools/windows_packaging/wine-pbd-tests.sh
new file mode 100755 (executable)
index 0000000..a7306ca
--- /dev/null
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+. ./wine-env.sh
+
+wine pbd-run-tests.exe
diff --git a/waf b/waf
index 9d2582a24ae88927c870031947139253f1c7b959..d1d9ea72523d080ed943be74e8a1090e8689ca8f 100755 (executable)
Binary files a/waf and b/waf differ
diff --git a/wscript b/wscript
index b302fe9d5a71168ab0b5ec3eeb619641a833a19e..a0b439e48c6f86a451f5696019dc0908c8ad20e0 100644 (file)
--- a/wscript
+++ b/wscript
@@ -6,6 +6,7 @@ import re
 import string
 import subprocess
 import sys
+import platform as PLATFORM
 
 def fetch_git_revision ():
     cmd = "git describe HEAD"
@@ -50,15 +51,17 @@ top = '.'
 out = 'build'
 
 children = [
-        'libs/pbd',
-        'libs/midi++2',
-        'libs/evoral',
+        # optionally external libraries
         'libs/vamp-sdk',
         'libs/qm-dsp',
         'libs/vamp-plugins',
         'libs/taglib',
         'libs/libltc',
         'libs/rubberband',
+        # core ardour libraries
+        'libs/pbd',
+        'libs/midi++2',
+        'libs/evoral',
         'libs/surfaces',
         'libs/panners',
         'libs/backends',
@@ -72,7 +75,7 @@ children = [
         'export',
         'midi_maps',
         'mcp',
-        'patchfiles'
+        'patchfiles',
 ]
 
 i18n_children = [
@@ -84,7 +87,7 @@ i18n_children = [
 # Version stuff
 
 def fetch_gcc_version (CC):
-    cmd = "LANG= %s --version" % CC
+    cmd = "%s --version" % CC
     output = subprocess.Popen(cmd, shell=True, stderr=subprocess.STDOUT, stdout=subprocess.PIPE).communicate()[0].splitlines()
     o = output[0].decode('utf-8')
     version = o.split(' ')[2].split('.')
@@ -136,7 +139,7 @@ def set_compiler_flags (conf,opt):
     # Debugging flags
     debug_flags = []
 
-    u = os.uname ()
+    u = PLATFORM.uname ()
     cpu = u[4]
     platform = u[0].lower()
     version = u[2]
@@ -804,7 +807,7 @@ const char* const ardour_config_info = "\\n\\
 
     write_config_text('C compiler flags',      conf.env['CFLAGS'])
     write_config_text('C++ compiler flags',    conf.env['CXXFLAGS'])
-    write_config_text('Linker flags',           conf.env['LINKFLAGS'])
+    write_config_text('Linker flags',          conf.env['LINKFLAGS'])
 
     config_text.write ('";\n}\n')
     config_text.close ()
@@ -815,18 +818,16 @@ def build(bld):
 
     # add directories that contain only headers, to workaround an issue with waf
 
-    bld.path.find_dir ('libs/evoral/evoral')
     if not bld.is_defined('USE_EXTERNAL_LIBS'):
         bld.path.find_dir ('libs/vamp-sdk/vamp-sdk')
-    bld.path.find_dir ('libs/surfaces/control_protocol/control_protocol')
-    bld.path.find_dir ('libs/timecode/timecode')
-    if not bld.is_defined('USE_EXTERNAL_LIBS'):
         bld.path.find_dir ('libs/libltc/ltc')
         bld.path.find_dir ('libs/rubberband/rubberband')
+        bld.path.find_dir ('libs/taglib/taglib')
+    bld.path.find_dir ('libs/evoral/evoral')
+    bld.path.find_dir ('libs/surfaces/control_protocol/control_protocol')
+    bld.path.find_dir ('libs/timecode/timecode')
     bld.path.find_dir ('libs/gtkmm2ext/gtkmm2ext')
     bld.path.find_dir ('libs/ardour/ardour')
-    if not bld.is_defined('USE_EXTERNAL_LIBS'):
-        bld.path.find_dir ('libs/taglib/taglib')
     bld.path.find_dir ('libs/pbd/pbd')
 
     autowaf.set_recursive()