예제 #1
0
파일: GENER.c 프로젝트: doniexun/OrangeC
void ml(void) {
    int i;

    if ( asm_file_cnt() > 0 ) {
        for( i = 0; i < asm_file_cnt(); i++ ) {
            fn_split( asm_file(i) );
            sprintf( args, "/nologo /c /Cp %s /Fo%s /Fl%s %s",
                get_option(OPT_DEBUG) ? "/Zi /Zd" : "",
                fn_temp( ".obj" ),
                get_option(OPT_LSTFILE) ? fn_temp(".lst") : "NUL",
                asm_file(i)
            );
            exec( "ML", args );
        }
    }
}
예제 #2
0
파일: GENER.c 프로젝트: doniexun/OrangeC
void masm(void) {
    int i;

    if ( asm_file_cnt() > 0 ) {
        for( i = 0; i < asm_file_cnt(); i++ ) {
            fn_split( asm_file(i) );
            sprintf( args, "/t /Ml %s %s,%s,%s,NUL",
                get_option(OPT_DEBUG) ? "/Zi" : "",
                asm_file(i),
                fn_temp( ".obj" ),
                get_option(OPT_LSTFILE) ? fn_temp(".lst") : "NUL"
            );
            exec( "MASM", args );
        }
    }
}
예제 #3
0
파일: GENER.c 프로젝트: doniexun/OrangeC
void lasmz(char *lasm_name) {
    int i;

    if ( asm_file_cnt() > 0 ) {
        for( i = 0; i < asm_file_cnt(); i++ ) {
            fn_split( asm_file(i) );
            sprintf( args, "/G1 /O /S /U /Y %s /FO%s /L%s %s",
                get_option(OPT_DEBUG) ? "/ZH" : "",
                fn_temp( ".obj" ),
                get_option(OPT_LSTFILE) ? fn_temp(".lst") : "NUL",
                asm_file(i)
            );
            exec( lasm_name, args );
        }
    }
}
예제 #4
0
파일: GENER.c 프로젝트: doniexun/OrangeC
void wasm(void) {
    int i;

    if ( asm_file_cnt() > 0 ) {
        for( i = 0; i < asm_file_cnt(); i++ ) {
            fn_split( asm_file(i) );
            sprintf( args, "-4ps -fpi87 -q -mf %s -fo=%s -fe=%s %s",
                get_option(OPT_DEBUG) ? "/d1" : "",
                fn_temp( ".obj" ),
                get_option(OPT_LSTFILE) ? fn_temp(".lst") : "NUL",
                asm_file(i)
            );
            exec( "WASM", args );
        }
    }
}
예제 #5
0
파일: file_open.c 프로젝트: mrraj/DATAS
void main(void)
{
  int i = 0;
  FILE *file_read = fopen("file_open.c", "r+");
  FILE *file_write = fopen("file_write.c", "r+");
  printf("File Pointer is : %p \n", file_read);
  printf("File Pointer is : %p \n", file_write);
    printf("%c", *file_read);
  asm_file(file_read, file_write);
}
예제 #6
0
파일: GENER.c 프로젝트: doniexun/OrangeC
void tasmz( char *tasm_name ) {
    FILE *fp;
    int i;

    if (  asm_file_cnt() > 0 ) {
        fp = response( RESPONSE );
        for( i = 0; i < asm_file_cnt(); i++ ) {
            fprintf( fp, "/t /ml /m /z%c",
                get_option(OPT_DEBUG) ? 'i' : 'n' );
            fn_split( asm_file(i) );
            fprintf( fp, " %s,%s,%s,NUL;\n",
                asm_file(i),
                fn_temp( ".obj"),
                get_option(OPT_LSTFILE) ? fn_temp( ".lst") : "NUL"
            );
        }
        fclose(fp);
        exec( tasm_name, "@" RESPONSE );
        if (! get_option(OPT_KEEPRSP) )
            unlink( RESPONSE );
    }
}
예제 #7
0
파일: GENER.c 프로젝트: doniexun/OrangeC
void nasm(void) {
    int i;

    if (  asm_file_cnt() > 0 ) {
        for( i = 0; i < asm_file_cnt(); i++ ) {
            if ( get_option( OPT_LSTFILE) ) {
                strcat( args, "-l ");
            }
            strcat( args, asm_file(i) );
            exec( "OASM", args );
        }
    }
}
예제 #8
0
void ComplxFrame::OnActivate(wxActivateEvent& event)
{
    bool reload_asm = false;
    bool reload_tests = false;
    /*if (!reload_options.tests.empty())
    {
        wxFileName tests_file(reload_options.tests);
        if (tests_file.GetModificationTime().IsLaterThan(reload_options.tests_modification_time))
        {
            // To prevent multiple occurrences
            reload_options.tests_modification_time = tests_file.GetModificationTime();
            int answer = wxMessageBox(wxString::Format("%s has been modified.\n"
                                                       "Do you wish to reload it?\n"
                                                       "(Note simulation will be reset and breakpoints "
                                                       "not present in code will not be reloaded.)", tests_file.GetFullName()),
                                      "Reload test xml file?", wxOK | wxOK_DEFAULT | wxCANCEL);
            reload_tests = answer == wxID_OK;
        }
    }*/
    if (!reload_options.file.empty())
    {
        wxFileName asm_file(reload_options.file);
        if (asm_file.GetModificationTime().IsLaterThan(reload_options.file_modification_time))
        {
            // To prevent multiple occurrences
            reload_options.file_modification_time = asm_file.GetModificationTime();
            if (!reload_tests)
            {
                int answer = wxMessageBox(wxString::Format("%s has been modified.\n"
                                                           "Do you wish to reload it?\n"
                                                           "(Note simulation will be reset and breakpoints "
                                                           "not present in code will not be reloaded.)", asm_file.GetFullName()),
                                          "Reload asm file?", wxOK | wxOK_DEFAULT | wxCANCEL);
                reload_asm = answer == wxOK;
            }
        }
    }

    if (reload_asm)
        DoLoadFile(reload_options);
}