のねのBlog

パソコンの問題や、ソフトウェアの開発で起きた問題など書いていきます。よろしくお願いします^^。

コントロール 'Progress' がアクセスされました。

System.InvalidOperationException が発生しました
  HResult=0x80131509
  Message=有効ではないスレッド間の操作: コントロールが作成されたスレッド以外のスレッドからコントロール 'Progress' がアクセスされました。
  Source=<例外のソースを評価できません>
  スタック トレース:
   場所 System.Windows.Forms.Control.get_Handle()
   場所 System.Windows.Forms.Control.GetSafeHandle(IWin32Window window)
   場所 System.Windows.Forms.MessageBox.ShowCore(IWin32Window owner, String text, String caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options, Boolean showHelp)
   場所 System.Windows.Forms.MessageBox.Show(IWin32Window owner, String text, String caption, MessageBoxButtons buttons, MessageBoxIcon icon)
   場所 FontVal.Progress.OnException(Exception e) (C:\Users\m_fujii\Documents\GitHub\Font-Validator\FontVal\Progress.cs):行 391
   場所 OTFontFileVal.Driver.RunValidation(Validator v, String[] fontList) (C:\Users\m_fujii\Documents\GitHub\Font-Validator\OTFontFileVal\ValDriver.cs):行 487
   場所 FontVal.Progress.Worker() (C:\Users\m_fujii\Documents\GitHub\Font-Validator\FontVal\Progress.cs):行 158
   場所 System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   場所 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   場所 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   場所 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   場所 System.Threading.ThreadHelper.ThreadStart()
        // method that will be called when the worker thread is started
        public void Worker()
        {
            m_bValidationInProgress = true;

            OTFontFileVal.Driver driver = new OTFontFileVal.Driver( this );
            driver.RunValidation( m_Validator, m_sFiles );
            m_bValidationInProgress = false;

            // after all work is done, enable the UI and close this dialog
            m_formParent.EnableUI(true);
            //JJF Close();
            CloseOurForm();
        }
        //Validates a list of font files...meant to be used by the Font Validator UI and the command line
        public int RunValidation( Validator v, string [] fontList )
        {
            int i;
            int ret = 0;
            // setup notification for validation events
            v.SetOnValidateEvent(new
                                 Validator.OnValidateEvent(OnValidateEvent));
            // enable us to receive validation info messages
            DIAction vid = new DIAction(ValidatorCallback);
            v.SetValInfoDelegate(vid);

            try
            {
                for (i = 0; i < fontList.Length; i++)
                {
                    // check to see if the user canceled validation
                    if (v.CancelFlag)
                    {
                        m_callbacks.OnCancel();
                        return ret;
                    }

                    ret |= ValidateFont(v, fontList[i], null, i, fontList.Length);
                }
                m_callbacks.OnReportsReady();
            }
            catch (Exception e)
            {
                m_callbacks.OnException(e);
                return 1;
            }

            return ret;

        }
        public void OnException( Exception e )
        {
            MessageBox.Show( this, e.Message, "Error", 
                             System.Windows.Forms.MessageBoxButtons.OK, 
                             System.Windows.Forms.MessageBoxIcon.Error);
            DeleteTemporaryFiles( m_reportFiles );
        }

Intersecting coordinates

Coming Soon Regular.ttf

Simple glyph index 80
  Intersecting coordinates
    (95.0, 755.0)
    <TTGlyph name="bracketleft"
      xMin="41" yMin="-33" xMax="313" yMax="773">
      <contour>
        <pt x="285" y="40" on="1"/>
        <pt x="296" y="40" on="0"/>
        <pt x="312" y="24" on="0"/>
        <pt x="313" y="12" on="1"/>
        <pt x="313" y="1" on="0"/>
        <pt x="297" y="-15" on="0"/>
        <pt x="286" y="-16" on="1"/>
        <pt x="258" y="-18" on="0"/>
        <pt x="205" y="-23" on="0"/>
        <pt x="162" y="-29" on="0"/>
        <pt x="133" y="-33" on="0"/>
        <pt x="130" y="-33" on="1"/>
        <pt x="119" y="-33" on="0"/>
        <pt x="103" y="-17" on="0"/>
        <pt x="102" y="0" on="1"/>
        <pt x="101" y="3" on="0"/>
        <pt x="96" y="51" on="0"/>
        <pt x="89" y="122" on="0"/>
        <pt x="81" y="208" on="0"/>
        <pt x="74" y="291" on="0"/>
        <pt x="69" y="361" on="0"/>
        <pt x="69" y="381" on="1"/>
        <pt x="69" y="412" on="0"/>
        <pt x="64" y="506" on="0"/>
        <pt x="56" y="605" on="0"/>
        <pt x="46" y="695" on="0"/>
        <pt x="41" y="722" on="1"/>
        <pt x="41" y="732" on="0"/>
        <pt x="55" y="748" on="0"/>
        <pt x="69" y="750" on="1"/>
        <pt x="74" y="750" on="0"/>
        <pt x="80" y="748" on="1"/>
        <pt x="88" y="754" on="0"/>
        <pt x="95" y="755" on="1"/> <=====
        <pt x="99" y="728" on="1"/>
        <pt x="95" y="755" on="1"/> <=====
        <pt x="98" y="756" on="0"/>
        <pt x="127" y="760" on="0"/>
        <pt x="171" y="766" on="0"/>
        <pt x="226" y="771" on="0"/>
        <pt x="255" y="773" on="1"/>
        <pt x="266" y="773" on="0"/>
        <pt x="282" y="757" on="0"/>
        <pt x="282" y="745" on="1"/>
        <pt x="282" y="734" on="0"/>
        <pt x="267" y="718" on="0"/>
        <pt x="256" y="717" on="1"/>
        <pt x="228" y="715" on="0"/>
        <pt x="175" y="710" on="0"/>
        <pt x="131" y="704" on="0"/>
        <pt x="103" y="700" on="0"/>
        <pt x="101" y="700" on="1"/>
        <pt x="106" y="667" on="0"/>
        <pt x="115" y="579" on="0"/>
        <pt x="121" y="489" on="0"/>
        <pt x="125" y="407" on="0"/>
        <pt x="125" y="381" on="1"/>
        <pt x="125" y="365" on="0"/>
        <pt x="128" y="309" on="0"/>
        <pt x="134" y="242" on="0"/>
        <pt x="141" y="168" on="0"/>
        <pt x="147" y="101" on="0"/>
        <pt x="153" y="44" on="0"/>
        <pt x="155" y="27" on="1"/>
        <pt x="178" y="30" on="0"/>
        <pt x="246" y="38" on="0"/>
        <pt x="283" y="40" on="1"/>
      </contour>
    </TTGlyph>

f:id:none53:20171016070012p:plain

./BuildAllLinux.sh

~/bin/afdko-package/FDK/Tools/Programs$ ./BuildAllLinux.sh
***Running autohint/build/linux/gcc/BuildAll.sh
cc -m32 
 -I../../../../../public/lib/api
 -I../../../../../public/lib/resource
 -I../../../../autohintlib/source/public/ac
 -I../../../../autohintlib/source/public/extras
 -I../../../../autohintlib/source/ac
 -I../../../../autohintlib/source/bf
 -DEXECUTABLE=1 -g 
 -c ../../../../source/main.c -o main.o

In file included from /usr/include/stdlib.h:24:0,
                 from ../../../../source/main.c:5:
/usr/include/features.h:367:25: 
  fatal error: sys/cdefs.h: No such file or directory
compilation terminated.
Makefile:41: recipe for target 'main.o' failed
make: *** [main.o] Error 1
sudo apt-get install g++-multilib

askubuntu.com

windows ubuntu bash afdko 64bit build

For building the 64 bit Linux Python,
 use a 64 bit Linux VM system. 
Use the same steps as above, 
but the path to the 
AFDKOPythonBuild must be an absolute path.

Also, you must first get the build-essentials and readline packages,
 with the 
commands: 

sudo apt-get install build-essential
sudo apt-get install zlib1g-dev # gets you the zlib.h file and zlib library.
sudo apt-get install libreadline-dev

You must also edit the Modules/Setup.dist file, 
BEFORE running ./configure,
 to enable the readlines library by removing the comment at the start of the line:

readline readline.c -lreadline -ltermcap # line 166 at the moment.

After building the Python interpreter, 
copy the file '/lib/i386-linux-gnu/libz.so.1.2.3.4'  
to Python/lib/python2.7/lib-dynload/.

Then cd there, and make a symbolic link named 'libz.so.1' to the libz.so.1.2.3. file.

https://raw.githubusercontent.com/adobe-type-tools/afdko/master/FDK/FDK%20Build%20Notes.txt

afdko ubuntu cannot execute binary file: Exec format error

$ ./type1 ComingSoon-Regular.ttf
-bash: ./type1: cannot execute binary file: Exec format error

64bit版なのかな

$ uname -a
Linux BOOTCAMP 4.4.0-43-Microsoft #1-Microsoft Wed Dec 31 14:42:53 PST 2014 x86_64 x86_64 x86_64 GNU/Linux

qiita.com

32bit版だから、動かないのか。

$ file ./type1
./type1: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.2, for GNU/Linux 2.6.24, BuildID[sha1]=e81a6999a8fb539de39a71850547d78609e7cffc, not stripped
~/bin/FDK/Tools/linux$

qiita.com