├── macos.icns ├── version.bmx ├── resources ├── android │ ├── android-project │ │ ├── jni │ │ │ ├── Android.mk │ │ │ ├── Application.mk │ │ │ └── src │ │ │ │ ├── Android_static.mk │ │ │ │ └── Android.mk │ │ ├── res │ │ │ ├── drawable-hdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-mdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-xhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── values │ │ │ │ └── strings.xml │ │ │ └── layout │ │ │ │ └── main.xml │ │ ├── BlitzMaxApp.java │ │ ├── default.properties │ │ ├── xlocal.properties │ │ ├── project.properties │ │ ├── ant.properties │ │ ├── build.properties │ │ ├── proguard-project.txt │ │ ├── AndroidManifest.xml │ │ └── build.xml │ └── apache-ant │ │ ├── KEYS │ │ ├── LICENSE │ │ ├── lib │ │ ├── ant.jar │ │ ├── ant-antlr.jar │ │ ├── ant-jai.jar │ │ ├── ant-jmf.jar │ │ ├── ant-jsch.jar │ │ ├── ant-junit.jar │ │ ├── ant-swing.jar │ │ ├── ant-jdepend.jar │ │ ├── ant-junit4.jar │ │ ├── ant-netrexx.jar │ │ ├── ant-apache-bsf.jar │ │ ├── ant-apache-oro.jar │ │ ├── ant-javamail.jar │ │ ├── ant-launcher.jar │ │ ├── ant-testutil.jar │ │ ├── ant-apache-bcel.jar │ │ ├── ant-apache-log4j.jar │ │ ├── ant-commons-net.jar │ │ ├── ant-apache-regexp.jar │ │ ├── ant-apache-resolver.jar │ │ ├── ant-apache-xalan2.jar │ │ ├── ant-commons-logging.jar │ │ ├── README │ │ ├── ant-launcher.pom │ │ ├── libraries.properties │ │ ├── ant-swing.pom │ │ ├── ant-jmf.pom │ │ ├── ant-apache-log4j.pom │ │ ├── ant-apache-regexp.pom │ │ ├── ant-apache-resolver.pom │ │ ├── ant-apache-bcel.pom │ │ ├── ant-commons-logging.pom │ │ ├── ant-jdepend.pom │ │ ├── ant-jsch.pom │ │ ├── ant-apache-oro.pom │ │ ├── ant-testutil.pom │ │ ├── ant-apache-bsf.pom │ │ ├── ant-antlr.pom │ │ ├── ant-commons-net.pom │ │ ├── ant-javamail.pom │ │ ├── ant-junit4.pom │ │ ├── ant-jai.pom │ │ ├── ant-apache-xalan2.pom │ │ ├── ant-netrexx.pom │ │ ├── ant-junit.pom │ │ └── ant-parent.pom │ │ ├── etc │ │ ├── ant-bootstrap.jar │ │ ├── checkstyle │ │ │ ├── checkstyle-text.xsl │ │ │ └── checkstyle-xdoc.xsl │ │ ├── changelog.xsl │ │ ├── tagdiff.xsl │ │ └── log.xsl │ │ ├── INSTALL │ │ ├── NOTICE │ │ ├── bin │ │ ├── antRun │ │ ├── lcp.bat │ │ ├── antRun.bat │ │ ├── runrc.cmd │ │ ├── antRun.pl │ │ ├── ant.cmd │ │ ├── antenv.cmd │ │ ├── runant.py │ │ ├── complete-ant-cmd.pl │ │ ├── envset.cmd │ │ └── runant.pl │ │ ├── README │ │ └── get-m2.xml └── ios │ └── template │ ├── Icon.png │ ├── Default.png │ ├── Default-568h@2x.png │ └── Info.plist ├── .gitignore ├── bmk_proc_man.bmx ├── bmk_cores_haiku.c ├── bmk_cores_win32.c ├── macos ├── macos.m ├── PECocoaBackportsGlobal.h ├── NSProcessInfo_PECocoaBackports.h └── NSProcessInfo_PECocoaBackports.m ├── bmk_cores_linux.bmx ├── bmk_cores_haiku.bmx ├── file_util.c ├── bmk_cores_win32.bmx ├── bmk_cores_linux.c ├── waitpid.c ├── core.bmk ├── bmk_cores_macos.bmx ├── hash.c ├── COPYING.md ├── custom.bmk ├── bootstrap.cfg ├── bmk_pm_ng.bmx ├── config.bmk ├── bmk_bank.bmx ├── bmk_modinfo.bmx ├── README.md ├── bmk_zap.bmx ├── stringbuffer_common.bmx ├── bmk_pm_legacy.bmx └── bmk_ng_utils.bmx /macos.icns: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/macos.icns -------------------------------------------------------------------------------- /version.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Const BMK_VERSION:String = "3.58" 4 | -------------------------------------------------------------------------------- /resources/android/android-project/jni/Android.mk: -------------------------------------------------------------------------------- 1 | include $(call all-subdir-makefiles) 2 | -------------------------------------------------------------------------------- /resources/ios/template/Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/ios/template/Icon.png -------------------------------------------------------------------------------- /resources/android/apache-ant/KEYS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/KEYS -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.bak 2 | .bmx 3 | .bmx/ 4 | /bmk 5 | /bmk.debug 6 | /bmk.exe 7 | /bmk.debug.exe 8 | /bmk.app 9 | .DS_Store -------------------------------------------------------------------------------- /resources/android/apache-ant/LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/LICENSE -------------------------------------------------------------------------------- /resources/ios/template/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/ios/template/Default.png -------------------------------------------------------------------------------- /bmk_proc_man.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | ?not bmxng 4 | Import "bmk_pm_legacy.bmx" 5 | ?bmxng 6 | Import "bmk_pm_ng.bmx" 7 | ? 8 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant.jar -------------------------------------------------------------------------------- /resources/ios/template/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/ios/template/Default-568h@2x.png -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-antlr.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-antlr.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jai.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-jai.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jmf.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-jmf.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jsch.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-jsch.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-junit.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-junit.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-swing.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-swing.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jdepend.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-jdepend.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-junit4.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-junit4.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-netrexx.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-netrexx.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/etc/ant-bootstrap.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/etc/ant-bootstrap.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-bsf.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-bsf.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-oro.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-oro.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-javamail.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-javamail.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-launcher.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-launcher.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-testutil.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-testutil.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-bcel.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-bcel.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-log4j.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-log4j.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-commons-net.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-commons-net.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-regexp.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-regexp.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-resolver.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-resolver.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-xalan2.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-apache-xalan2.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-commons-logging.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/apache-ant/lib/ant-commons-logging.jar -------------------------------------------------------------------------------- /resources/android/apache-ant/INSTALL: -------------------------------------------------------------------------------- 1 | For installation instructions see the manual in the docs subdirectory 2 | or online at . 3 | -------------------------------------------------------------------------------- /bmk_cores_haiku.c: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | int bmx_get_system_info_cpu_count() { 4 | system_info info; 5 | get_system_info(&info); 6 | return info.cpu_count; 7 | } 8 | -------------------------------------------------------------------------------- /resources/android/android-project/res/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/android-project/res/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /resources/android/android-project/res/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/android-project/res/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /resources/android/android-project/res/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/android-project/res/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /resources/android/android-project/res/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bmx-ng/bmk/HEAD/resources/android/android-project/res/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /resources/android/android-project/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | ${app.name} 4 | 5 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/README: -------------------------------------------------------------------------------- 1 | Please refer to the Ant manual under Installing Ant / Library 2 | Dependencies for a list of the jar requirements for various optional 3 | tasks and features. 4 | -------------------------------------------------------------------------------- /bmk_cores_win32.c: -------------------------------------------------------------------------------- 1 | #include "windows.h" 2 | 3 | 4 | int bmx_GetSystemInfo_dwNumberOfProcessors() { 5 | SYSTEM_INFO info; 6 | GetSystemInfo(&info); 7 | return info.dwNumberOfProcessors; 8 | } 9 | -------------------------------------------------------------------------------- /resources/android/android-project/jni/Application.mk: -------------------------------------------------------------------------------- 1 | 2 | # Uncomment this if you're using STL in your project 3 | # See CPLUSPLUS-SUPPORT.html in the NDK documentation for more information 4 | # APP_STL := stlport_static 5 | 6 | APP_ABI := armeabi armeabi-v7a x86 7 | -------------------------------------------------------------------------------- /macos/macos.m: -------------------------------------------------------------------------------- 1 | 2 | void NSOSVersion(int * major, int * minor, int * patch) { 3 | NSOperatingSystemVersion version = [[NSProcessInfo processInfo] operatingSystemVersion]; 4 | *major = version.majorVersion; 5 | *minor = version.minorVersion; 6 | *patch = version.patchVersion; 7 | } 8 | -------------------------------------------------------------------------------- /bmk_cores_linux.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Import "bmk_cores_linux.c" 4 | 5 | Extern 6 | Function bmx_get_core_count:Int() 7 | End Extern 8 | 9 | Function GetCoreCount:Int() 10 | Global count:Int 11 | 12 | If Not count Then 13 | count = bmx_get_core_count() 14 | End If 15 | 16 | Return count 17 | End Function 18 | -------------------------------------------------------------------------------- /resources/android/android-project/jni/src/Android_static.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | 3 | include $(CLEAR_VARS) 4 | 5 | LOCAL_MODULE := main 6 | 7 | LOCAL_SRC_FILES := YourSourceHere.c 8 | 9 | LOCAL_STATIC_LIBRARIES := SDL2_static 10 | 11 | include $(BUILD_SHARED_LIBRARY) 12 | $(call import-module,SDL)LOCAL_PATH := $(call my-dir) 13 | -------------------------------------------------------------------------------- /bmk_cores_haiku.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Import "bmk_cores_haiku.c" 4 | 5 | Extern 6 | Function bmx_get_system_info_cpu_count:Int() 7 | End Extern 8 | 9 | Function GetCoreCount:Int() 10 | Global count:Int 11 | 12 | If Not count Then 13 | count = bmx_get_system_info_cpu_count() 14 | End If 15 | 16 | Return count 17 | End Function 18 | 19 | -------------------------------------------------------------------------------- /file_util.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include "brl.mod/blitz.mod/blitz.h" 4 | 5 | void bmx_setfiletimenow(BBString * path) { 6 | char * p = bbStringToUTF8String(path); 7 | struct utimbuf times; 8 | 9 | times.actime = time(NULL); 10 | times.modtime = time(NULL); 11 | 12 | utime(p, ×); 13 | 14 | bbMemFree(p); 15 | } -------------------------------------------------------------------------------- /resources/android/apache-ant/NOTICE: -------------------------------------------------------------------------------- 1 | Apache Ant 2 | Copyright 1999-2014 The Apache Software Foundation 3 | 4 | This product includes software developed at 5 | The Apache Software Foundation (http://www.apache.org/). 6 | 7 | The task is based on code Copyright (c) 2002, Landmark 8 | Graphics Corp that has been kindly donated to the Apache Software 9 | Foundation. 10 | -------------------------------------------------------------------------------- /bmk_cores_win32.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Import "bmk_cores_win32.c" 4 | 5 | Extern 6 | Function bmx_GetSystemInfo_dwNumberOfProcessors:Int() 7 | End Extern 8 | 9 | Function GetCoreCount:Int() 10 | Global count:Int 11 | 12 | If Not count Then 13 | count = bmx_GetSystemInfo_dwNumberOfProcessors() 14 | End If 15 | 16 | Return count 17 | End Function 18 | 19 | -------------------------------------------------------------------------------- /resources/android/android-project/BlitzMaxApp.java: -------------------------------------------------------------------------------- 1 | 2 | //${start.app.package} 3 | package com.blitzmax.android; 4 | //${end.app.package} 5 | import org.libsdl.app.SDLActivity; 6 | 7 | public class BlitzMaxApp extends SDLActivity { 8 | 9 | static { 10 | //${start.lib.imports} 11 | //${end.lib.imports} 12 | System.loadLibrary( "${app.id}"); 13 | } 14 | 15 | } 16 | 17 | 18 | -------------------------------------------------------------------------------- /resources/android/android-project/default.properties: -------------------------------------------------------------------------------- 1 | # This file is automatically generated by Android Tools. 2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED! 3 | # 4 | # This file must be checked in Version Control Systems. 5 | # 6 | # To customize properties used by the Ant build system use, 7 | # "build.properties", and override values to adapt the script to your 8 | # project structure. 9 | 10 | # Project target. 11 | target=android-19 12 | -------------------------------------------------------------------------------- /resources/android/android-project/res/layout/main.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /bmk_cores_linux.c: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | int bmx_get_core_count() { 4 | int cores = 0; 5 | char buffer[1024]; 6 | 7 | FILE * fp = popen("cat /proc/cpuinfo |grep -c '^processor'", "r"); 8 | 9 | if (fp == NULL) { 10 | printf("Failed to run command\n" ); 11 | return 1; 12 | } 13 | 14 | while (fgets(buffer, sizeof(buffer), fp) != NULL) { 15 | cores = atoi(buffer); 16 | } 17 | 18 | pclose(fp); 19 | 20 | return cores; 21 | } 22 | -------------------------------------------------------------------------------- /resources/android/android-project/jni/src/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | 3 | include $(CLEAR_VARS) 4 | 5 | LOCAL_MODULE := main 6 | 7 | SDL_PATH := ../SDL 8 | 9 | LOCAL_C_INCLUDES := $(LOCAL_PATH)/$(SDL_PATH)/include 10 | 11 | # Add your application source files here... 12 | LOCAL_SRC_FILES := $(SDL_PATH)/src/main/android/SDL_android_main.c \ 13 | YourSourceHere.c 14 | 15 | LOCAL_SHARED_LIBRARIES := SDL2 16 | 17 | LOCAL_LDLIBS := -lGLESv1_CM -lGLESv2 -llog 18 | 19 | include $(BUILD_SHARED_LIBRARY) 20 | -------------------------------------------------------------------------------- /waitpid.c: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #ifndef __WIN32 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | #endif 10 | 11 | int bmx_system(const char * c) { 12 | #ifdef __WIN32 13 | return system(c); 14 | #else 15 | int status; 16 | pid_t pid = fork(); 17 | if (pid == 0) { 18 | execl("/bin/sh", "/bin/sh", "-c", c, NULL); 19 | _exit(-1); 20 | } else if (pid < 0) { 21 | status = -1; 22 | } else { 23 | if (waitpid(pid, &status, 0) != pid) { 24 | status = -1; 25 | } 26 | } 27 | return status; 28 | #endif 29 | } 30 | -------------------------------------------------------------------------------- /resources/android/android-project/xlocal.properties: -------------------------------------------------------------------------------- 1 | # This file is automatically generated by Android Tools. 2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED! 3 | # 4 | # This file must *NOT* be checked in Version Control Systems, 5 | # as it contains information specific to your local configuration. 6 | 7 | # location of the SDK. This is only used by Ant 8 | # For customization when using a Version Control System, please read the 9 | # header note. 10 | 11 | #ANDROID_SDK_DIR is same as ANDROID_PATH except with '\' changed to '\\' - ant or android or someone seems to require this. 12 | sdk.dir=${ANDROID_SDK_DIR} 13 | -------------------------------------------------------------------------------- /core.bmk: -------------------------------------------------------------------------------- 1 | #!BMK 2 | 3 | @define echo 4 | print(arg0) 5 | @end 6 | 7 | @define include 8 | bmk.LoadBMK(arg1) 9 | @end 10 | 11 | @define push 12 | globals.Push(arg1) 13 | @end 14 | 15 | @define pop 16 | globals.Pop(arg1) 17 | @end 18 | 19 | @define pushall 20 | globals.PushAll() 21 | @end 22 | 23 | @define popall 24 | globals.PopAll() 25 | @end 26 | 27 | @define notify 28 | sys.Notify(arg0) 29 | @end 30 | 31 | @define openurl 32 | sys.OpenURL(arg1) 33 | @end 34 | 35 | @define addarg 36 | local option = nvl(arg1, "") 37 | local extra = nvl(arg2, "") 38 | if option ~= "" then 39 | bmk.AddArg(option, extra) 40 | end 41 | @end 42 | -------------------------------------------------------------------------------- /resources/android/android-project/project.properties: -------------------------------------------------------------------------------- 1 | # This file is automatically generated by Android Tools. 2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED! 3 | # 4 | # This file must be checked in Version Control Systems. 5 | # 6 | # To customize properties used by the Ant build system edit 7 | # "ant.properties", and override values to adapt the script to your 8 | # project structure. 9 | # 10 | # To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): 11 | #proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt 12 | 13 | # Project target. 14 | #${start.sdk.target} 15 | target=android-19 16 | #${end.sdk.target} 17 | -------------------------------------------------------------------------------- /bmk_cores_macos.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | ?Not bmxng 4 | Import "macos/*.h" 5 | Import "macos/macos.m" 6 | Import "macos/NSProcessInfo_PECocoaBackports.m" 7 | ? 8 | 9 | Extern 10 | ?bmxng 11 | Function sysctlbyname:Int(name:Byte Ptr, count:Int Ptr, size:Size_T Ptr, a:Byte Ptr, b:Size_T) 12 | ?Not bmxng 13 | Function sysctlbyname:Int(name:Byte Ptr, count:Int Ptr, size:Int Ptr, a:Byte Ptr, b:Int) 14 | ? 15 | End Extern 16 | 17 | Function GetCoreCount:Int() 18 | Global count:Int 19 | 20 | If Not count Then 21 | ?bmxng 22 | Local l:Size_T = 4 23 | ?Not bmxng 24 | Local l:Int = 4 25 | ? 26 | sysctlbyname("hw.ncpu", Varptr count, Varptr l,Null,0) 27 | End If 28 | 29 | Return count 30 | End Function 31 | 32 | -------------------------------------------------------------------------------- /resources/android/android-project/ant.properties: -------------------------------------------------------------------------------- 1 | # This file is used to override default values used by the Ant build system. 2 | # 3 | # This file must be checked into Version Control Systems, as it is 4 | # integral to the build system of your project. 5 | 6 | # This file is only used by the Ant script. 7 | 8 | # You can use this to override default values such as 9 | # 'source.dir' for the location of your java source folder and 10 | # 'out.dir' for the location of your output folder. 11 | 12 | # You can also use it define how the release builds are signed by declaring 13 | # the following properties: 14 | # 'key.store' for the location of your keystore and 15 | # 'key.alias' for the name of the key to use. 16 | # The password will be asked during the build when you use the 'release' target. 17 | 18 | -------------------------------------------------------------------------------- /resources/android/android-project/build.properties: -------------------------------------------------------------------------------- 1 | # This file is used to override default values used by the Ant build system. 2 | # 3 | # This file must be checked in Version Control Systems, as it is 4 | # integral to the build system of your project. 5 | 6 | # This file is only used by the Ant script. 7 | 8 | # You can use this to override default values such as 9 | # 'source.dir' for the location of your java source folder and 10 | # 'out.dir' for the location of your output folder. 11 | 12 | # You can also use it define how the release builds are signed by declaring 13 | # the following properties: 14 | # 'key.store' for the location of your keystore and 15 | # 'key.alias' for the name of the key to use. 16 | # The password will be asked during the build when you use the 'release' target. 17 | 18 | -------------------------------------------------------------------------------- /resources/android/android-project/proguard-project.txt: -------------------------------------------------------------------------------- 1 | # To enable ProGuard in your project, edit project.properties 2 | # to define the proguard.config property as described in that file. 3 | # 4 | # Add project specific ProGuard rules here. 5 | # By default, the flags in this file are appended to flags specified 6 | # in ${sdk.dir}/tools/proguard/proguard-android.txt 7 | # You can edit the include path and order by changing the ProGuard 8 | # include property in project.properties. 9 | # 10 | # For more details, see 11 | # http://developer.android.com/guide/developing/tools/proguard.html 12 | 13 | # Add any project specific keep options here: 14 | 15 | # If your project uses WebView with JS, uncomment the following 16 | # and specify the fully qualified class name to the JavaScript interface 17 | # class: 18 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 19 | # public *; 20 | #} 21 | -------------------------------------------------------------------------------- /resources/ios/template/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIconFile 12 | Icon 13 | CFBundleIdentifier 14 | ${PRODUCT_BUNDLE_IDENTIFIER} 15 | CFBundleInfoDictionaryVersion 16 | 6.0 17 | CFBundleName 18 | ${PRODUCT_NAME} 19 | CFBundlePackageType 20 | APPL 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /hash.c: -------------------------------------------------------------------------------- 1 | 2 | #include "brl.mod/blitz.mod/blitz.h" 3 | 4 | #ifndef XXHASH_H_5627135585666179 5 | #define XXH_STATIC_LINKING_ONLY 6 | #define XXH_IMPLEMENTATION 7 | 8 | #include "xxhash.h" 9 | #endif 10 | 11 | BBString * bmx_gen_hash(BBString * txt) { 12 | char buf[64]; 13 | snprintf(buf, 64, "0x%llx", XXH3_64bits(txt->buf, txt->length * sizeof(BBChar))); 14 | return bbStringFromCString(buf); 15 | } 16 | 17 | XXH3_state_t * bmx_hash_createState() { 18 | return XXH3_createState(); 19 | } 20 | 21 | void bmx_hash_reset(XXH3_state_t * state) { 22 | XXH3_64bits_reset(state); 23 | } 24 | 25 | void bmx_hash_update(XXH3_state_t * state, void * data, int length) { 26 | XXH3_64bits_update(state, data, length); 27 | } 28 | 29 | BBString * bmx_hash_digest(XXH3_state_t * state) { 30 | char buf[64]; 31 | snprintf(buf, 64, "%llx", XXH3_64bits_digest(state)); 32 | return bbStringFromCString(buf); 33 | } 34 | 35 | void bmx_hash_free(XXH3_state_t * state) { 36 | XXH3_freeState(state); 37 | } 38 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/antRun: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | 3 | # Licensed to the Apache Software Foundation (ASF) under one or more 4 | # contributor license agreements. See the NOTICE file distributed with 5 | # this work for additional information regarding copyright ownership. 6 | # The ASF licenses this file to You under the Apache License, Version 2.0 7 | # (the "License"); you may not use this file except in compliance with 8 | # the License. You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | 18 | # Args: DIR command 19 | cd "$1" 20 | CMD="$2" 21 | shift 22 | shift 23 | 24 | exec "$CMD" "$@" 25 | -------------------------------------------------------------------------------- /COPYING.md: -------------------------------------------------------------------------------- 1 | Copyright (c) 2005-2013 Mark Sibly 2 | Copyright (c) 2007-2019 Bruce A Henderson 3 | 4 | This software is provided 'as-is', without any express or implied 5 | warranty. In no event will the authors be held liable for any damages 6 | arising from the use of this software. 7 | 8 | Permission is granted to anyone to use this software for any purpose, 9 | including commercial applications, and to alter it and redistribute it 10 | freely, subject to the following restrictions: 11 | 12 | 1. The origin of this software must not be misrepresented; you must not 13 | claim that you wrote the original software. If you use this software 14 | in a product, an acknowledgment in the product documentation would be 15 | appreciated but is not required. 16 | 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 20 | 3. This notice may not be removed or altered from any source 21 | distribution. 22 | -------------------------------------------------------------------------------- /custom.bmk: -------------------------------------------------------------------------------- 1 | # Example options 2 | 3 | # ** compiler optimisation ** 4 | #setccopt optimization -O3 5 | 6 | # ** specific architecture ** 7 | #setwin32ccopt arch -march=pentium3 8 | 9 | #setmacx86ccopt arch -march=nocona 10 | #setmacx86ccopt math -msse3 11 | 12 | 13 | 14 | # ** android configuration ** 15 | # ** architecture is determined by build settings ** 16 | # ** NOTE : android build requires bmk resources folder at BlitzMax/resources ** 17 | 18 | #addoption android.home "/PATH/TO/SDK/android-sdk-macosx" 19 | #addoption android.sdk "/PATH/TO/SDK/android-sdk-macosx" 20 | #addoption android.ndk "/PATH/TO/NDK/android-ndk-r10c" 21 | #addoption android.toolchain.version "4.9" 22 | #addoption android.platform "12" 23 | 24 | # ** Optional SDK target ** 25 | # Will try to determine valid target to update project.properties, if not set. 26 | #addoption android.sdk.target "23" 27 | 28 | # ** optional ant location ** 29 | # ** defaults to resources/apache-ant ** 30 | 31 | #addoption ant.home "/PATH/TO/ANT/HOME" 32 | -------------------------------------------------------------------------------- /bootstrap.cfg: -------------------------------------------------------------------------------- 1 | # 2 | # types : 3 | # t - bootstrap platform/arch 4 | # m - module 5 | # a - app 6 | # 7 | #t win32 x86 8 | #t win32 x64 9 | #t linux x86 10 | #t linux x64 11 | #t macos x64 12 | #t raspberrypi arm 13 | #t raspberrypi arm64 14 | 15 | # core modules 16 | m brl.blitz *.c *.h bdwgc tree hash 17 | m pub.stdc *.c 18 | m pub.lua lua-5.1.4 19 | m pub.win32 *.cpp 20 | m pub.zlib *.c *.h 21 | m pub.freeprocess *.c 22 | m pub.macos *.m *.h 23 | m pub.physfs physfs 24 | 25 | m brl.appstub *.c *.m 26 | m brl.event *.h 27 | m brl.keycodes *.h 28 | m brl.map *.c 29 | m brl.maxlua *.c 30 | m brl.reflection *.c 31 | m brl.stringbuilder *.c *.h 32 | m brl.systemdefault *.c *.h 33 | m brl.threads *.m *.c 34 | m brl.math *.c *.h 35 | m brl.io *.c 36 | 37 | # bah modules - for bootstrap, etc 38 | #m bah.libarchive *.c bzip2 libarchive zlib 39 | #m bah.libcurl *.cpp src 40 | #m bah.format *.c 41 | #m bah.regex pcre 42 | #m bah.xz *.cpp src 43 | #m bah.mbedtls *.c mbedtls 44 | #m bah.libxml *.cpp src 45 | #m bah.libiconv *.cpp 46 | #m bah.libssh2 *.cpp src include_all include_unix include_win32 47 | 48 | 49 | # apps 50 | a bcc *.c *.h 51 | a bmk *.c *.bmk *.icns 52 | #a bootstrap *.txt 53 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/lcp.bat: -------------------------------------------------------------------------------- 1 | REM 2 | REM Licensed to the Apache Software Foundation (ASF) under one or more 3 | REM contributor license agreements. See the NOTICE file distributed with 4 | REM this work for additional information regarding copyright ownership. 5 | REM The ASF licenses this file to You under the Apache License, Version 2.0 6 | REM (the "License"); you may not use this file except in compliance with 7 | REM the License. You may obtain a copy of the License at 8 | REM 9 | REM http://www.apache.org/licenses/LICENSE-2.0 10 | REM 11 | REM Unless required by applicable law or agreed to in writing, software 12 | REM distributed under the License is distributed on an "AS IS" BASIS, 13 | REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | REM See the License for the specific language governing permissions and 15 | REM limitations under the License. 16 | REM 17 | REM 18 | 19 | set _CLASSPATHCOMPONENT=%1 20 | if ""%1""=="""" goto gotAllArgs 21 | shift 22 | 23 | :argCheck 24 | if ""%1""=="""" goto gotAllArgs 25 | set _CLASSPATHCOMPONENT=%_CLASSPATHCOMPONENT% %1 26 | shift 27 | goto argCheck 28 | 29 | :gotAllArgs 30 | set LOCALCLASSPATH=%LOCALCLASSPATH%;%_CLASSPATHCOMPONENT% 31 | 32 | -------------------------------------------------------------------------------- /bmk_pm_ng.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Import BRL.ThreadPool 4 | Import "bmk_ng_utils.bmx" 5 | 6 | Type TProcessManager 7 | 8 | Field pool:TThreadPoolExecutor 9 | 10 | Field cpuCount:Int 11 | 12 | Field threads:TList = New TList 13 | 14 | Method New() 15 | cpuCount = GetCoreCount() 16 | 17 | pool = TThreadPoolExecutor.newFixedThreadPool(Max(1, cpuCount - 1)) 18 | 19 | End Method 20 | 21 | Method CheckTasks() 22 | While pool.getActiveCount() = pool.maxThreads 23 | Delay 5 24 | Wend 25 | End Method 26 | 27 | Method WaitForTasks() 28 | While pool.getActiveCount() Or Not pool.IsQueueEmpty() 29 | Delay 5 30 | Wend 31 | End Method 32 | 33 | Method DoSystem(cmd:String, src:String, obj:String, supp:String) 34 | CheckTasks() 35 | 36 | pool.execute(new TThreadPoolTask.Create(TProcessTask._DoTasks, CreateProcessTask(cmd, src, obj, supp))) 37 | 38 | End Method 39 | 40 | Method AddTask:Int(func:Object(data:Object), data:Object) 41 | CheckTasks() 42 | 43 | pool.execute(new TThreadPoolTask.Create(func, data)) 44 | End Method 45 | 46 | End Type 47 | 48 | Type TThreadPoolTask Extends TRunnable 49 | 50 | Field func:Object(data:Object) 51 | Field data:Object 52 | 53 | Method Create:TThreadPoolTask(func:Object(data:Object), data:Object) 54 | Self.func = func 55 | Self.data = data 56 | Return self 57 | End Method 58 | 59 | Method run() 60 | func(data) 61 | End Method 62 | 63 | End Type 64 | 65 | -------------------------------------------------------------------------------- /resources/android/apache-ant/etc/checkstyle/checkstyle-text.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | : 27 | 28 | : 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /config.bmk: -------------------------------------------------------------------------------- 1 | # 2 | # BMK Cross-compiler configuration 3 | # 4 | # These paths determine where various MingW and Wine paths and files are on your 5 | # system. 6 | # The names of the binaries can change between distributions. 7 | # 8 | # ---------------------- 9 | # 10 | # Please edit the following paths and filenames 11 | # 12 | 13 | # The full path to the location of mingw 14 | # 15 | # for MacPorts, this is usually /opt/local 16 | # 17 | path_to_mingw=/usr/local/i386-mingw32-3.4.5 18 | 19 | # The names of the compiler utils (ar, ld, gcc, g++) 20 | # (you can find these in the bin folder) 21 | # 22 | name_of_ar=i386-mingw32-ar 23 | name_of_ld=i386-mingw32-ld 24 | name_of_gcc=i386-mingw32-gcc 25 | name_of_gpp=i386-mingw32-g++ 26 | 27 | 28 | # The path in which crt2.o resides. 29 | # 30 | path_to_mingw_lib=%path_to_mingw%/i386-mingw32/lib 31 | 32 | # The path where crtbegin.o and crtend.o reside 33 | # 34 | path_to_mingw_lib2=%path_to_mingw%/lib/gcc/i386-mingw32/3.4.5 35 | 36 | 37 | # The path to Wine executable 38 | # 39 | # typical on Linux 40 | #path_to_wine=/usr/bin/wine 41 | # typical on Mac 42 | path_to_wine=/Applications/Darwine/Wine.bundle/Contents/bin/wine 43 | 44 | # ---------------------- 45 | # 46 | # No need to edit these. They are configured by the above settings. 47 | # 48 | # 49 | path_to_mingw_include=%path_to_mingw%/include 50 | path_to_mingw_lib3=%path_to_mingw%/i386-mingw32/lib 51 | 52 | path_to_ar=%path_to_mingw%/bin/%name_of_ar% 53 | path_to_ld=%path_to_mingw%/bin/%name_of_ld% 54 | path_to_gcc=%path_to_mingw%/bin/%name_of_gcc% 55 | path_to_gpp=%path_to_mingw%/bin/%name_of_gpp% 56 | 57 | 58 | -------------------------------------------------------------------------------- /bmk_bank.bmx: -------------------------------------------------------------------------------- 1 | 2 | Strict 3 | 4 | Import "bmk_config.bmx" 5 | 6 | Import Pub.ZLib 7 | Import BRL.SocketStream 8 | 9 | Function CompressBank:TBank( bank:TBank ) 10 | 11 | ?bmxng 12 | Local size:ULongInt=bank.Size() 13 | Local out_size:ULongInt=size+size/10+32 14 | Local out:TBank=TBank.Create( Size_T(out_size) ) 15 | ?Not bmxng 16 | Local size=bank.Size() 17 | Local out_size=size+size/10+32 18 | Local out:TBank=TBank.Create( out_size ) 19 | ? 20 | compress out.Buf()+4,out_size,bank.Buf(),size 21 | 22 | out.PokeByte 0,Int(size) 23 | out.PokeByte 1,Int(size Shr 8) 24 | out.PokeByte 2,Int(size Shr 16) 25 | out.PokeByte 3,Int(size Shr 24) 26 | ?bmxng 27 | out.Resize Size_T(out_size+4) 28 | ?Not bmxng 29 | out.Resize out_size+4 30 | ? 31 | Return out 32 | 33 | End Function 34 | 35 | Function UncompressBank:TBank( bank:TBank ) 36 | 37 | ?bmxng 38 | Local out_size:ULongInt 39 | ?Not bmxng 40 | Local out_size 41 | ? 42 | out_size:|bank.PeekByte(0) 43 | out_size:|bank.PeekByte(1) Shl 8 44 | out_size:|bank.PeekByte(2) Shl 16 45 | out_size:|bank.PeekByte(3) Shl 24 46 | ?bmxng 47 | Local out:TBank=TBank.Create( Size_T(out_size) ) 48 | uncompress out.Buf(),out_size,bank.Buf()+4,ULongInt(bank.Size()-4) 49 | ?Not bmxng 50 | Local out:TBank=TBank.Create( out_size ) 51 | uncompress out.Buf(),out_size,bank.Buf()+4,bank.Size()-4 52 | ? 53 | Return out 54 | 55 | End Function 56 | 57 | Function SplitUrl( url$,server$ Var,file$ Var ) 58 | Local i=url.Find( "/",0 ) 59 | If i<>-1 60 | server=url[..i] 61 | file=url[i..] 62 | Else 63 | server=url 64 | file="/" 65 | EndIf 66 | End Function 67 | 68 | -------------------------------------------------------------------------------- /bmk_modinfo.bmx: -------------------------------------------------------------------------------- 1 | 2 | Strict 3 | 4 | Import "bmk_modutil.bmx" 5 | Import "bmk_util.bmx" 6 | 7 | Type TInfo 8 | Field info:TList=New TList 9 | 10 | Method Find$( key$ ) 11 | key=key.ToLower()+":" 12 | For Local t$=EachIn info 13 | If t.ToLower()[..Len(key)]=key Return t[Len(key)..].Trim() 14 | Next 15 | End Method 16 | 17 | Method ReadFromStream:TModInfo( stream:TStream ) 18 | While Not stream.Eof() 19 | Local t$=stream.ReadLine() 20 | If Not t Return 21 | info.AddLast t 22 | Wend 23 | End Method 24 | End Type 25 | 26 | Type TModInfo Extends TInfo 27 | 28 | Field name$ 29 | Field version# 30 | Field modprivs$ 31 | Field modserver$ 32 | Field serverinfo:Object 33 | 34 | Function CreateFromModule:TModInfo( name$ ) 35 | Local path$=ModuleInterface( name,"release."+processor.Platform()+"."+processor.CPU() ) 36 | If FileType(path)<>FILETYPE_FILE Return 37 | Local src:TSourceFile=ParseSourceFile( path ) 38 | If Not src Return 39 | Local modinfo:TModInfo=New TModInfo 40 | modinfo.name=name 41 | modinfo.info=src.info 42 | modinfo.info.AddFirst "Module: "+name 43 | modinfo.version=Float( modinfo.Find( "Version" ) ) 44 | modinfo.modserver=modinfo.Find( "ModServer" ) 45 | Return modinfo 46 | End Function 47 | 48 | Function CreateFromStream:TModInfo( stream:TStream ) 49 | Local modinfo:TModInfo=New TModInfo 50 | modinfo.ReadFromStream stream 51 | modinfo.name=modinfo.Find( "Module" ) 52 | If Not modinfo.name Return 53 | modinfo.version=Float( modinfo.Find( "Version" ) ) 54 | modinfo.modprivs=modinfo.Find( "ModPrivs" ) 55 | modinfo.modserver=modinfo.Find( "ModServer" ) 56 | Return modinfo 57 | End Function 58 | 59 | End Type 60 | 61 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/antRun.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | 3 | REM Licensed to the Apache Software Foundation (ASF) under one or more 4 | REM contributor license agreements. See the NOTICE file distributed with 5 | REM this work for additional information regarding copyright ownership. 6 | REM The ASF licenses this file to You under the Apache License, Version 2.0 7 | REM (the "License"); you may not use this file except in compliance with 8 | REM the License. You may obtain a copy of the License at 9 | REM 10 | REM http://www.apache.org/licenses/LICENSE-2.0 11 | REM 12 | REM Unless required by applicable law or agreed to in writing, software 13 | REM distributed under the License is distributed on an "AS IS" BASIS, 14 | REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | REM See the License for the specific language governing permissions and 16 | REM limitations under the License. 17 | 18 | if "%OS%"=="Windows_NT" @setlocal 19 | if "%OS%"=="WINNT" @setlocal 20 | 21 | if ""%1""=="""" goto runCommand 22 | 23 | rem Change drive and directory to %1 24 | if "%OS%"=="Windows_NT" goto nt_cd 25 | if "%OS%"=="WINNT" goto nt_cd 26 | cd ""%1"" 27 | goto end_cd 28 | :nt_cd 29 | cd /d ""%1"" 30 | :end_cd 31 | shift 32 | 33 | rem Slurp the command line arguments. This loop allows for an unlimited number 34 | rem of arguments (up to the command line limit, anyway). 35 | set ANT_RUN_CMD=%1 36 | if ""%1""=="""" goto runCommand 37 | shift 38 | :loop 39 | if ""%1""=="""" goto runCommand 40 | set ANT_RUN_CMD=%ANT_RUN_CMD% %1 41 | shift 42 | goto loop 43 | 44 | :runCommand 45 | rem echo %ANT_RUN_CMD% 46 | %ANT_RUN_CMD% 47 | 48 | if "%OS%"=="Windows_NT" @endlocal 49 | if "%OS%"=="WINNT" @endlocal 50 | 51 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/runrc.cmd: -------------------------------------------------------------------------------- 1 | /* 2 | Licensed to the Apache Software Foundation (ASF) under one or more 3 | contributor license agreements. See the NOTICE file distributed with 4 | this work for additional information regarding copyright ownership. 5 | The ASF licenses this file to You under the Apache License, Version 2.0 6 | (the "License"); you may not use this file except in compliance with 7 | the License. You may obtain a copy of the License at 8 | 9 | http://www.apache.org/licenses/LICENSE-2.0 10 | 11 | Unless required by applicable law or agreed to in writing, software 12 | distributed under the License is distributed on an "AS IS" BASIS, 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | See the License for the specific language governing permissions and 15 | limitations under the License. 16 | 17 | Run RC file, name is in the first arg, second arg is either PATH 18 | ENV or -r or nothing 19 | */ 20 | 21 | parse arg name path rest 22 | 23 | if name = '' then do 24 | say 'RC file name is missing' 25 | exit 1 26 | end 27 | 28 | if rest \= '' then do 29 | say 'Too many parameters' 30 | exit 1 31 | end 32 | 33 | call runit name path 34 | exit 0 35 | 36 | runit: procedure 37 | parse arg name path dir 38 | 39 | if path \= '' & path \= '-r' then do 40 | dir = value(translate(path),,'OS2ENVIRONMENT') 41 | if dir = '' then return 42 | dir = translate(dir, '\', '/') /* change UNIX-like path to OS/2 */ 43 | end 44 | 45 | if dir = '' then dir = directory() 46 | 47 | if path = '-r' then do /* recursive call */ 48 | subdir = filespec('path', dir) 49 | if subdir \= '\' then do 50 | subdir = left(subdir, length(subdir)-1) 51 | call runit name path filespec('drive', dir) || subdir 52 | end 53 | end 54 | 55 | /* Look for the file and run it */ 56 | if right(dir, 1) \= '\' then dir = dir || '\' 57 | rcfile = stream(dir || name, 'c', 'query exists') 58 | if rcfile \= '' then interpret 'call "' || rcfile || '"' 59 | 60 | return 61 | -------------------------------------------------------------------------------- /resources/android/android-project/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 10 | 11 | 20 | 25 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/antRun.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | # 3 | # Licensed to the Apache Software Foundation (ASF) under one or more 4 | # contributor license agreements. See the NOTICE file distributed with 5 | # this work for additional information regarding copyright ownership. 6 | # The ASF licenses this file to You under the Apache License, Version 2.0 7 | # (the "License"); you may not use this file except in compliance with 8 | # the License. You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | # 18 | ####################################################################### 19 | # 20 | # antRun.pl 21 | # 22 | # wrapper script for invoking commands on a platform with Perl installed 23 | # this is akin to antRun.bat, and antRun the SH script 24 | # 25 | # created: 2001-10-18 26 | # author: Jeff Tulley jtulley@novell.com 27 | ####################################################################### 28 | #be fussy about variables 29 | use strict; 30 | 31 | #turn warnings on during dev; generates a few spurious uninitialised var access warnings 32 | #use warnings; 33 | 34 | #and set $debug to 1 to turn on trace info (currently unused) 35 | my $debug=1; 36 | 37 | ####################################################################### 38 | # change drive and directory to "%1" 39 | my $ANT_RUN_CMD = @ARGV[0]; 40 | 41 | # assign current run command to "%2" 42 | chdir (@ARGV[0]) || die "Can't cd to $ARGV[0]: $!\n"; 43 | if ($^O eq "NetWare") { 44 | # There is a bug in Perl 5 on NetWare, where chdir does not 45 | # do anything. On NetWare, the following path-prefixed form should 46 | # always work. (afaict) 47 | $ANT_RUN_CMD .= "/".@ARGV[1]; 48 | } 49 | else { 50 | $ANT_RUN_CMD = @ARGV[1]; 51 | } 52 | 53 | # dispose of the first two arguments, leaving only the command's args. 54 | shift; 55 | shift; 56 | 57 | # run the command 58 | my $returnValue = system $ANT_RUN_CMD, @ARGV; 59 | if ($returnValue eq 0) { 60 | exit 0; 61 | } 62 | else { 63 | # only 0 and 1 are widely recognized as exit values 64 | # so change the exit value to 1 65 | exit 1; 66 | } 67 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-launcher.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-launcher 36 | 1.9.4 37 | Apache Ant Launcher 38 | 39 | 40 | 41 | org.apache.maven.plugins 42 | maven-compiler-plugin 43 | 44 | 45 | org/apache/tools/ant/launch/*.java 46 | 47 | 48 | 49 | 50 | 51 | ../../../../src/main 52 | ../../../../src/testcases 53 | ../../../../target/ant-launcher/classes 54 | ../../../../target/ant-launcher/testcases 55 | ../../../../target/ant-launcher 56 | 57 | 58 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/libraries.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | #this file declares the libraries for use in 17 | #a given release of the components 18 | 19 | #if you change this, change the checksum to match 20 | m2.version=2.0.4 21 | m2.url=http\://repo1.maven.org/maven2 22 | m2.artifact-name=maven-artifact-ant 23 | m2.jar.name=${m2.artifact-name}-${m2.version}-dep.jar 24 | #this is the URL of the antlib library, that is pulled down for everything else. 25 | m2.antlib.url=${m2.url}/org/apache/maven/${m2.artifact-name}/${m2.version}/${m2.jar.name} 26 | #this is the sha1 checksum of the artifact 27 | m2.sha1.checksum=4e7ddfdb91600e9b59bb965ff8eef2f06015df50 28 | 29 | # Repository to use by default for fetching dependencies. 30 | m2.repo=http://repo1.maven.org/maven2/ 31 | 32 | #versions of different libraries. Please keep in alphabetical order, except 33 | #when a specific dependency forces them to be out-of-order 34 | antlr.version=2.7.7 35 | bcel.version=5.1 36 | bsf.version=2.4.0 37 | bsh.version=2.0b4 38 | bsh-core.version=${bsh.version} 39 | commons-net.version=1.4.1 40 | commons-logging.version=1.1 41 | commons-logging-api.version=${commons-logging.version} 42 | jai-core.version=1.1.3 43 | jai-codec.version=1.1.3 44 | jasper-compiler.version=4.1.36 45 | jasper-runtime.version=${jasper-compiler.version} 46 | jdepend.version=2.9.1 47 | jruby.version=0.9.8 48 | junit.version=4.11 49 | jsch.version=0.1.50 50 | jython.version=2.1 51 | #log4j 1.2.15 requires JMS and a few other Sun jars that are not in the m2 repo 52 | log4j.version=1.2.14 53 | #js is the javascript implementation of the rhino project 54 | #17R1 is compiled with Java5 so we can't use the jar when building with JDK 1.4 55 | js.version=1.6R7 56 | oro.version=2.0.8 57 | regexp.version=1.3 58 | servlet-api.version=2.3 59 | which.version=1.0 60 | xalan.version=2.7.1 61 | xml-resolver.version=1.2 62 | mail.version=1.4 63 | #paired 64 | jacl.version=1.2.6 65 | tcljava.version=${jacl.version} 66 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-swing.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-swing 36 | 1.9.4 37 | Apache Ant + Swing 38 | a listener and a splash task based on Swing 39 | 40 | 41 | org.apache.ant 42 | ant 43 | 1.9.4 44 | compile 45 | 46 | 47 | 48 | 49 | 50 | org.apache.maven.plugins 51 | maven-compiler-plugin 52 | 53 | 54 | org/apache/tools/ant/taskdefs/optional/splash/* 55 | 56 | 57 | 58 | 59 | ../../../../src/main 60 | ../../../../src/testcases 61 | ../../../../target/${project.artifactId}/classes 62 | ../../../../target/${project.artifactId}/testcases 63 | ../../../../target/${project.artifactId} 64 | 65 | 66 | 67 | -------------------------------------------------------------------------------- /macos/PECocoaBackportsGlobal.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2014 Petroules Corporation. All rights reserved. 3 | * 4 | * Redistribution and use in source and binary forms, with or without 5 | * modification, are permitted provided that the following conditions are met: 6 | * 7 | * 1. Redistributions of source code must retain the above copyright notice, this 8 | * list of conditions and the following disclaimer. 9 | * 2. Redistributions in binary form must reproduce the above copyright notice, 10 | * this list of conditions and the following disclaimer in the documentation 11 | * and/or other materials provided with the distribution. 12 | * 13 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 14 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 15 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 16 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 17 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 18 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 19 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 20 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 22 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 | */ 24 | 25 | #ifndef __PECocoaBackportsGlobal__ 26 | #define __PECocoaBackportsGlobal__ 27 | 28 | #import 29 | 30 | CF_INLINE void class_addInstanceMethodIfNecessary(Class clazz, SEL realSelector, SEL fakeSelector) { 31 | if (!class_getInstanceMethod(clazz, realSelector)) { 32 | Method method = class_getInstanceMethod(clazz, fakeSelector); 33 | if (!class_addMethod(clazz, realSelector, method_getImplementation(method), 34 | method_getTypeEncoding(method))) { 35 | #if defined(DEBUG) && DEBUG 36 | NSLog(@"PECocoaBackports: error adding -[%@ %@] (-[%@ %@])", 37 | NSStringFromClass(clazz), NSStringFromSelector(fakeSelector), 38 | NSStringFromClass(clazz), NSStringFromSelector(realSelector)); 39 | #endif 40 | } else { 41 | #if defined(DEBUG) && DEBUG 42 | NSLog(@"PECocoaBackports: added -[%@ %@] (-[%@ %@])", 43 | NSStringFromClass(clazz), NSStringFromSelector(fakeSelector), 44 | NSStringFromClass(clazz), NSStringFromSelector(realSelector)); 45 | #endif 46 | } 47 | } else { 48 | #if defined(DEBUG) && DEBUG 49 | NSLog(@"PECocoaBackports: skipped adding -[%@ %@] (-[%@ %@]); already exists", 50 | NSStringFromClass(clazz), NSStringFromSelector(fakeSelector), 51 | NSStringFromClass(clazz), NSStringFromSelector(realSelector)); 52 | #endif 53 | } 54 | } 55 | 56 | #endif // __PECocoaBackportsGlobal__ -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jmf.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-jmf 35 | 1.9.4 36 | Apache Ant + JMF 37 | contains the sound task and a soundplayer listener 38 | download the dependency from http://java.sun.com/products/java-media/jmf/ 39 | 40 | 41 | org.apache.ant 42 | ant 43 | 1.9.4 44 | compile 45 | 46 | 47 | 48 | 49 | 50 | org.apache.maven.plugins 51 | maven-compiler-plugin 52 | 53 | 54 | org/apache/tools/ant/taskdefs/optional/sound/* 55 | 56 | 57 | 58 | 59 | ../../../../src/main 60 | ../../../../src/testcases 61 | ../../../../target/${project.artifactId}/classes 62 | ../../../../target/${project.artifactId}/testcases 63 | ../../../../target/${project.artifactId} 64 | 65 | 66 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-log4j.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-apache-log4j 35 | 1.9.4 36 | Apache Ant + Log4J 37 | 38 | 39 | org.apache.ant 40 | ant 41 | 1.9.4 42 | compile 43 | 44 | 45 | log4j 46 | log4j 47 | 1.2.13 48 | compile 49 | 50 | 51 | 52 | 53 | 54 | org.apache.maven.plugins 55 | maven-compiler-plugin 56 | 57 | 58 | org/apache/tools/ant/listener/Log4jListener* 59 | 60 | 61 | 62 | 63 | ../../../../src/main 64 | ../../../../src/testcases 65 | ../../../../target/${project.artifactId}/classes 66 | ../../../../target/${project.artifactId}/testcases 67 | ../../../../target/${project.artifactId} 68 | 69 | 70 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-regexp.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-apache-regexp 35 | 1.9.4 36 | Apache Ant + Apache Regexp 37 | 38 | 39 | org.apache.ant 40 | ant 41 | 1.9.4 42 | compile 43 | 44 | 45 | regexp 46 | regexp 47 | 1.3 48 | compile 49 | 50 | 51 | 52 | 53 | 54 | org.apache.maven.plugins 55 | maven-compiler-plugin 56 | 57 | 58 | org/apache/tools/ant/util/regexp/JakartaRegexp* 59 | 60 | 61 | 62 | 63 | ../../../../src/main 64 | ../../../../src/testcases 65 | ../../../../target/${project.artifactId}/classes 66 | ../../../../target/${project.artifactId}/testcases 67 | ../../../../target/${project.artifactId} 68 | 69 | 70 | 71 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-resolver.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-apache-resolver 35 | 1.9.4 36 | Apache Ant + Apache Resolver 37 | 38 | 39 | org.apache.ant 40 | ant 41 | 1.9.4 42 | compile 43 | 44 | 45 | xml-resolver 46 | xml-resolver 47 | 1.1 48 | compile 49 | 50 | 51 | 52 | 53 | 54 | org.apache.maven.plugins 55 | maven-compiler-plugin 56 | 57 | 58 | org/apache/tools/ant/types/resolver/** 59 | 60 | 61 | 62 | 63 | ../../../../src/main 64 | ../../../../src/testcases 65 | ../../../../target/${project.artifactId}/classes 66 | ../../../../target/${project.artifactId}/testcases 67 | ../../../../target/${project.artifactId} 68 | 69 | 70 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-bcel.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-apache-bcel 36 | 1.9.4 37 | Apache Ant + BCEL 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | bcel 47 | bcel 48 | 5.1 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | org.apache.maven.plugins 56 | maven-compiler-plugin 57 | 58 | 59 | org/apache/tools/ant/filters/util/JavaClassHelper* 60 | org/apache/tools/ant/util/depend/bcel/* 61 | 62 | 63 | 64 | 65 | ../../../../src/main 66 | ../../../../src/testcases 67 | ../../../../target/${project.artifactId}/classes 68 | ../../../../target/${project.artifactId}/testcases 69 | ../../../../target/${project.artifactId} 70 | 71 | 72 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-commons-logging.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-commons-logging 35 | 1.9.4 36 | Apache Ant + Commons Logging 37 | Ant Listener based on commons-logging 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | commons-logging 47 | commons-logging-api 48 | 1.0.4 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | org.apache.maven.plugins 56 | maven-compiler-plugin 57 | 58 | 59 | org/apache/tools/ant/listener/CommonsLoggingListener* 60 | 61 | 62 | 63 | 64 | ../../../../src/main 65 | ../../../../src/testcases 66 | ../../../../target/${project.artifactId}/classes 67 | ../../../../target/${project.artifactId}/testcases 68 | ../../../../target/${project.artifactId} 69 | 70 | 71 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jdepend.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-jdepend 36 | 1.9.4 37 | Apache Ant + JDepend 38 | task jdepend invoking the jdepend parser. There is also a version 2.9.1 of the 39 | jdepend parser available on the maven repository 40 | 41 | 42 | org.apache.ant 43 | ant 44 | 1.9.4 45 | compile 46 | 47 | 48 | jdepend 49 | jdepend 50 | 2.7 51 | compile 52 | 53 | 54 | 55 | 56 | 57 | org.apache.maven.plugins 58 | maven-compiler-plugin 59 | 60 | 61 | org/apache/tools/ant/taskdefs/optional/jdepend/* 62 | 63 | 64 | 65 | 66 | ../../../../src/main 67 | ../../../../src/testcases 68 | ../../../../target/${project.artifactId}/classes 69 | ../../../../target/${project.artifactId}/testcases 70 | ../../../../target/${project.artifactId} 71 | 72 | 73 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jsch.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-jsch 35 | 1.9.4 36 | Apache Ant + JSch 37 | contains the sshexec and scp tasks 38 | 39 | 40 | 41 | org.apache.ant 42 | ant 43 | 1.9.4 44 | compile 45 | 46 | 47 | com.jcraft 48 | jsch 49 | 0.1.50 50 | compile 51 | 52 | 53 | 54 | 55 | 56 | org.apache.maven.plugins 57 | maven-compiler-plugin 58 | 59 | 60 | org/apache/tools/ant/taskdefs/optional/ssh/* 61 | 62 | 63 | org/apache/tools/ant/taskdefs/optional/ssh/* 64 | 65 | 66 | 67 | 68 | ../../../../src/main 69 | ../../../../src/testcases 70 | ../../../../target/${project.artifactId}/classes 71 | ../../../../target/${project.artifactId}/testcases 72 | ../../../../target/${project.artifactId} 73 | 74 | 75 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/ant.cmd: -------------------------------------------------------------------------------- 1 | /* 2 | Licensed to the Apache Software Foundation (ASF) under one or more 3 | contributor license agreements. See the NOTICE file distributed with 4 | this work for additional information regarding copyright ownership. 5 | The ASF licenses this file to You under the Apache License, Version 2.0 6 | (the "License"); you may not use this file except in compliance with 7 | the License. You may obtain a copy of the License at 8 | 9 | http://www.apache.org/licenses/LICENSE-2.0 10 | 11 | Unless required by applicable law or agreed to in writing, software 12 | distributed under the License is distributed on an "AS IS" BASIS, 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | See the License for the specific language governing permissions and 15 | limitations under the License. 16 | 17 | Run ant 18 | */ 19 | 20 | '@echo off' 21 | parse arg mode envarg '::' antarg 22 | 23 | if mode\='.' & mode\='..' & mode\='/' then do 24 | envarg = mode envarg 25 | mode = '' 26 | end 27 | 28 | if antarg = '' then do 29 | antarg = envarg 30 | envarg = '' 31 | end 32 | 33 | x = setlocal() 34 | 35 | env="OS2ENVIRONMENT" 36 | antenv = _getenv_('antenv') 37 | if _testenv_() = 0 then interpret 'call "' || antenv || '"' '"' || envarg || '"' 38 | 39 | if mode = '' then mode = _getenv_('ANT_MODE' '..') 40 | if mode \= '/' then do 41 | runrc = _getenv_('runrc') 42 | antrc = _getenv_('antrc' 'antrc.cmd') 43 | if mode = '..' then mode = '-r' 44 | else mode = '' 45 | interpret 'call "' || runrc || '"' antrc '"' || mode || '"' 46 | end 47 | 48 | if _testenv_() = 0 then do 49 | say 'Ant environment is not set properly' 50 | x = endlocal() 51 | exit 16 52 | end 53 | 54 | settings = '-Dant.home=' || ANT_HOME '-Djava.home=' || JAVA_HOME 55 | 56 | java = _getenv_('javacmd' 'java') 57 | opts = value('ANT_OPTS',,env) 58 | args = value('ANT_ARGS',,env) 59 | lcp = value('LOCALCLASSPATH',,env) 60 | cp = value('CLASSPATH',,env) 61 | if value('ANT_USE_CP',,env) \= '' then do 62 | if lcp \= '' & right(lcp, 1) \= ';' then lcp = lcp || ';' 63 | lcp = lcp || cp 64 | 'SET CLASSPATH=' 65 | end 66 | if lcp\='' then lcp = '-classpath' lcp 67 | 68 | cmd = java opts lcp '-jar' ANT_HOME ||'\lib\ant-launcher.jar' settings args antarg 69 | launcher = stream(ANT_HOME ||'\lib\ant-launcher.jar', 'C', 'query exists') 70 | if launcher = '' then entry = 'org.apache.tools.ant.Main' 71 | else entry = 'org.apache.tools.ant.launch.Launcher' 72 | java opts lcp entry settings args antarg 73 | 74 | x = endlocal() 75 | 76 | return rc 77 | 78 | _testenv_: procedure expose env ANT_HOME JAVA_HOME 79 | ANT_HOME = value('ANT_HOME',,env) 80 | if ANT_HOME = '' then return 0 81 | JAVA_HOME = value('JAVA_HOME',,env) 82 | if JAVA_HOME = '' then return 0 83 | cp = translate(value('CLASSPATH',,env)) 84 | if pos(translate(ANT_HOME), cp) = 0 then return 0 85 | if pos(translate(JAVA_HOME), cp) = 0 then return 0 86 | return 1 87 | 88 | _getenv_: procedure expose env 89 | parse arg envar default 90 | if default = '' then default = envar 91 | var = value(translate(envar),,env) 92 | if var = '' then var = default 93 | return var 94 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-oro.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-apache-oro 36 | 1.9.4 37 | Apache Ant + Apache Oro 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | oro 47 | oro 48 | 2.0.8 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | org.apache.maven.plugins 56 | maven-compiler-plugin 57 | 58 | 59 | org/apache/tools/ant/util/regexp/JakartaOro* 60 | 61 | 62 | org/apache/tools/ant/util/regexp/JakartaOro* 63 | org/apache/tools/ant/util/regexp/Regexp* 64 | 65 | 66 | 67 | 68 | ../../../../src/main 69 | ../../../../src/tests/junit 70 | ../../../../target/${project.artifactId}/classes 71 | ../../../../target/${project.artifactId}/testcases 72 | ../../../../target/${project.artifactId} 73 | 74 | 75 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-testutil.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-testutil 36 | 1.9.4 37 | Apache Ant Test Utilities 38 | test utility classes 39 | 40 | 41 | org.apache.ant 42 | ant 43 | 1.9.4 44 | compile 45 | 46 | 47 | junit 48 | junit 49 | 4.11 50 | compile 51 | 52 | 53 | 54 | 55 | 56 | org.apache.maven.plugins 57 | maven-compiler-plugin 58 | 59 | 60 | org/apache/tools/ant/BuildFileTest* 61 | org/apache/tools/ant/util/regexp/RegexpMatcherTest* 62 | org/apache/tools/ant/util/regexp/RegexpTest* 63 | org/apache/tools/ant/taskdefs/optional/AbstractXSLTLiaisonTest* 64 | org/apache/tools/ant/types/AbstractFileSetTest* 65 | 66 | 67 | 68 | 69 | ../../../../src/tests/junit 70 | ../../../../target/${project.artifactId}/classes 71 | ../../../../target/${project.artifactId} 72 | 73 | 74 | 75 | -------------------------------------------------------------------------------- /macos/NSProcessInfo_PECocoaBackports.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2014 Petroules Corporation. All rights reserved. 3 | * 4 | * Redistribution and use in source and binary forms, with or without 5 | * modification, are permitted provided that the following conditions are met: 6 | * 7 | * 1. Redistributions of source code must retain the above copyright notice, this 8 | * list of conditions and the following disclaimer. 9 | * 2. Redistributions in binary form must reproduce the above copyright notice, 10 | * this list of conditions and the following disclaimer in the documentation 11 | * and/or other materials provided with the distribution. 12 | * 13 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 14 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 15 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 16 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 17 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 18 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 19 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 20 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 22 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 | */ 24 | 25 | #import 26 | #import 27 | #import 28 | 29 | #if (defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE) || \ 30 | (defined(MAC_OS_X_VERSION_MAX_ALLOWED) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1060) 31 | #import 32 | #endif 33 | 34 | #import "PECocoaBackportsGlobal.h" 35 | 36 | #if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE 37 | #if __IPHONE_OS_VERSION_MAX_ALLOWED < 80000 38 | #ifndef DECLARE_OPERATING_SYSTEM_VERSION 39 | #define DECLARE_OPERATING_SYSTEM_VERSION 1 40 | #endif 41 | #endif 42 | #if __IPHONE_OS_VERSION_MIN_REQUIRED < 80000 43 | #ifndef LOAD_OPERATING_SYSTEM_VERSION 44 | #define LOAD_OPERATING_SYSTEM_VERSION 1 45 | #endif 46 | #endif 47 | #elif defined(TARGET_OS_MAC) && TARGET_OS_MAC 48 | #if __MAC_OS_X_VERSION_MAX_ALLOWED < 101000 49 | #ifndef DECLARE_OPERATING_SYSTEM_VERSION 50 | #define DECLARE_OPERATING_SYSTEM_VERSION 1 51 | #endif 52 | #endif 53 | #if __MAC_OS_X_VERSION_MIN_REQUIRED < 101000 54 | #ifndef LOAD_OPERATING_SYSTEM_VERSION 55 | #define LOAD_OPERATING_SYSTEM_VERSION 1 56 | #endif 57 | #endif 58 | #endif 59 | 60 | #ifndef DECLARE_OPERATING_SYSTEM_VERSION 61 | #define DECLARE_OPERATING_SYSTEM_VERSION 0 62 | #endif 63 | 64 | #ifndef LOAD_OPERATING_SYSTEM_VERSION 65 | #define LOAD_OPERATING_SYSTEM_VERSION 0 66 | #endif 67 | 68 | #if DECLARE_OPERATING_SYSTEM_VERSION 69 | typedef struct { 70 | NSInteger majorVersion; 71 | NSInteger minorVersion; 72 | NSInteger patchVersion; 73 | } NSOperatingSystemVersion; 74 | #endif 75 | 76 | @interface NSProcessInfo (PECocoaBackports) 77 | 78 | #if DECLARE_OPERATING_SYSTEM_VERSION 79 | - (NSOperatingSystemVersion)operatingSystemVersion NS_AVAILABLE(10_5, 2_0); 80 | - (BOOL)isOperatingSystemAtLeastVersion:(NSOperatingSystemVersion)version NS_AVAILABLE(10_5, 2_0); 81 | #endif 82 | 83 | @end 84 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-bsf.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-apache-bsf 36 | 1.9.4 37 | Apache Ant + BSF 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | bsf 47 | bsf 48 | 2.4.0 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | org.apache.maven.plugins 56 | maven-compiler-plugin 57 | 58 | 59 | org/apache/tools/ant/taskdefs/optional/Script* 60 | org/apache/tools/ant/taskdefs/optional/script/** 61 | org/apache/tools/ant/types/optional/*Script* 62 | org/apache/tools/ant/util/Script* 63 | org/apache/tools/ant/util/optional/Script* 64 | 65 | 66 | 67 | 68 | ../../../../src/main 69 | ../../../../src/testcases 70 | ../../../../target/${project.artifactId}/classes 71 | ../../../../target/${project.artifactId}/testcases 72 | ../../../../target/${project.artifactId} 73 | 74 | 75 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-antlr.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-antlr 36 | 1.9.4 37 | Apache Ant + ANTLR 38 | antlr specific task. 39 | The implementation forks a java process, therefore the antlr jar file is only needed at runtime 40 | 41 | 42 | org.apache.ant 43 | ant 44 | 1.9.4 45 | true 46 | compile 47 | 48 | 49 | 50 | antlr 51 | antlr 52 | 2.7.2 53 | true 54 | runtime 55 | 56 | 57 | 58 | 59 | 60 | org.apache.maven.plugins 61 | maven-compiler-plugin 62 | 63 | 64 | org/apache/tools/ant/taskdefs/optional/ANTLR* 65 | 66 | 67 | 68 | 69 | ../../../../src/main 70 | ../../../../src/testcases 71 | ../../../../target/${project.artifactId}/classes 72 | ../../../../target/${project.artifactId}/testcases 73 | ../../../../target/${project.artifactId} 74 | 75 | 76 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-commons-net.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-commons-net 35 | 1.9.4 36 | Apache Ant + Commons Net 37 | ftp, rexec and telnet tasks 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | commons-net 47 | commons-net 48 | 1.4.0 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | org.apache.maven.plugins 56 | maven-compiler-plugin 57 | 58 | 59 | org/apache/tools/ant/taskdefs/optional/net/FTP* 60 | org/apache/tools/ant/taskdefs/optional/net/RExec* 61 | org/apache/tools/ant/taskdefs/optional/net/TelnetTask* 62 | 63 | 64 | org/apache/tools/ant/taskdefs/optional/net/FTP* 65 | 66 | 67 | 68 | 69 | ../../../../src/main 70 | ../../../../src/testcases 71 | ../../../../target/${project.artifactId}/classes 72 | ../../../../target/${project.artifactId}/testcases 73 | ../../../../target/${project.artifactId} 74 | 75 | 76 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | BMK (NG) INSTRUCTIONS 2 | ===================== 3 | 4 | Always backup before deploying a new BMK. (Better safe than sorry!) 5 | 6 | 7 | Compiling BMK 8 | ------------- 9 | 10 | bmk.bmx is the main source-file. 11 | 12 | BMK should be compiled in Non-GUI and Release mode. 13 | 14 | Compilation with an older version of BMK: 15 | 16 | $ mkdir -p build/ 17 | $ path/to/bmk makeapp -a -r -h -o ./build/bmk ./bmk.bmx 18 | 19 | You can optionally specify platform and CPU during compilation, e.g. 20 | 21 | PLATFORM="macos" 22 | CPU="x64" 23 | path/to/bmk makeapp -a -r -h -l $PLATFORM -g $CPU -o ./build/bmk ./bmk.bmx 24 | 25 | You can also compile BMK in either Threaded or Non-threaded modes. 26 | 27 | When compiled with Threading enabled, BMK will parallel compile C/C++ files 28 | when it can, scaling to the number of available cores on your system. 29 | Note : The compiled executable filename will include ".mt", which you will need 30 | to remove when deploying it in BlitzMax/bin. 31 | 32 | When compiled without Threading, BMK will compile all files, one at a time. 33 | 34 | 35 | Deploying BMK 36 | ------------- 37 | 38 | The bmk executable, core.bmk and make.bmk, should be deployed in the BlitzMax/bin 39 | folder. 40 | 41 | 42 | You can also create a custom.bmk file in BlitzMax/bin which is used to override built-in 43 | compiler options, such as optimisations. (see "Using custom.bmk" below) 44 | 45 | 46 | On Linux and MacOS systems, you may also optionally deploy config.bmk. This provides 47 | settings for Cross-Compiling modules and applications for Win32 targets. If you intend 48 | to use this, please check the file for any system-specific configuration options you 49 | need to supply. 50 | 51 | 52 | 53 | Using custom.bmk 54 | ---------------- 55 | 56 | This file allows you to override the default compiler options BMK uses. 57 | 58 | The format is : 59 | 60 | 61 | 62 | 63 | The normal command is "addccopt", but all valid commands are listed here : 64 | 65 | addccopt - for all platforms and processors 66 | addlinuxccopt - Linux specific option 67 | addwin32ccopt - Win32 specific option 68 | addmacccopt - MacOS specific option 69 | addmacx86ccopt - MacOS x86 specific option 70 | addmacppcccopt - MacOS ppc specific option 71 | 72 | The following option names will override the default settings appropriately 73 | 74 | optimization - Optimize level. The default is -Os (optimize for size) 75 | arch - The processor architecture. The default -march=pentium 76 | math - The floating point unit. 77 | 78 | 79 | If you want a value to contain spaces, wrap it in double-quotes (") 80 | 81 | See the gcc manual for more options. (hint: google for "man gcc", is useful). 82 | 83 | 84 | 85 | Cross-Compiling 86 | --------------- 87 | 88 | BMK supports compiling of Win32 binaries and modules on MacOS and Linux systems. 89 | 90 | You can download all the necessary packages from the following location : 91 | 92 | http://brucey.net/programming/blitz/mingw/ 93 | 94 | 95 | 96 | Running BMK 97 | ----------- 98 | 99 | You can obtain the current version of BMK with : 100 | 101 | bmk -v 102 | 103 | 104 | Running BMK with no options will produce a basic Usage guide. 105 | 106 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-javamail.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-javamail 35 | 1.9.4 36 | Apache Ant + JavaMail 37 | implementation of the mail task based on javamail. 38 | Required to send emails to SMTP servers using user/password combinations 39 | or to send mail over SSL 40 | 41 | 42 | org.apache.ant 43 | ant 44 | 1.9.4 45 | compile 46 | 47 | 48 | javax.mail 49 | mail 50 | 1.4 51 | compile 52 | 53 | 54 | javax.activation 55 | activation 56 | 1.1 57 | compile 58 | 59 | 60 | 61 | 62 | 63 | org.apache.maven.plugins 64 | maven-compiler-plugin 65 | 66 | 67 | org/apache/tools/ant/taskdefs/email/MimeMailer* 68 | 69 | 70 | 71 | 72 | ../../../../src/main 73 | ../../../../src/testcases 74 | ../../../../target/${project.artifactId}/classes 75 | ../../../../target/${project.artifactId}/testcases 76 | ../../../../target/${project.artifactId} 77 | 78 | 79 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-junit4.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-junit4 35 | 1.9.4 36 | Apache Ant + JUnit 4 37 | contains JUnit 4.x support 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | junit 47 | junit 48 | 4.11 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | org.apache.maven.plugins 56 | maven-compiler-plugin 57 | 58 | 59 | org/apache/tools/ant/taskdefs/optional/junit/JUnit4TestMethodAdapter* 60 | org/apache/tools/ant/taskdefs/optional/junit/CustomJUnit4TestAdapterCache* 61 | 62 | 63 | 64 | 65 | ../../../../src/main 66 | ../../../../src/testcases 67 | ../../../../target/${project.artifactId}/classes 68 | ../../../../target/${project.artifactId}/testcases 69 | ../../../../target/${project.artifactId} 70 | 71 | 72 | -------------------------------------------------------------------------------- /bmk_zap.bmx: -------------------------------------------------------------------------------- 1 | 2 | Strict 3 | 4 | Import "bmk_modutil.bmx" 5 | Import "bmk_bank.bmx" 6 | Import "bmk_modinfo.bmx" 7 | 8 | Function Zap( path$,stream:TStream ) 9 | 10 | If Not path Return False 11 | 12 | Local name$=StripDir( path ) 13 | 14 | Local skip=False 15 | 16 | If name[..1]="." 17 | skip=True 18 | Else If name.ToLower().EndsWith( ".bak" ) 19 | skip=True 20 | EndIf 21 | 22 | If skip 23 | stream.WriteLine "" 24 | Return True 25 | EndIf 26 | 27 | Local Mode=FileMode( path ) 28 | 29 | Select FileType(path) 30 | Case FILETYPE_NONE 31 | Print "Error zapping file "+path 32 | Return 33 | Case FILETYPE_FILE 34 | Local size=FileSize(path) 35 | stream.WriteLine name 36 | stream.WriteLine Mode 37 | stream.WriteLine size 38 | Local from_stream:TStream=ReadStream(path) 39 | CopyBytes from_stream,stream,size 40 | from_stream.Close 41 | Case FILETYPE_DIR 42 | Local dir$[]=LoadDir( path ) 43 | Local size=Len( dir ) 44 | stream.WriteLine name 45 | stream.WriteLine -Mode 46 | stream.WriteLine size 47 | For Local t$=EachIn dir 48 | If Not Zap( path+"/"+t,stream ) Return 49 | Next 50 | End Select 51 | 52 | Return True 53 | 54 | End Function 55 | 56 | Function Unzap( dir$,stream:TStream ) 57 | 58 | Local name$=stream.ReadLine() 59 | If Not name Return True 60 | 61 | Local Mode=Int( stream.ReadLine() ) 62 | Local size=Int( stream.ReadLine() ) 63 | 64 | Local path$=dir+"/"+name 65 | 66 | If Mode<0 67 | Mode=-Mode 68 | CreateDir path 69 | For Local k=0 Until size 70 | If Not Unzap( path,stream ) Return 71 | Next 72 | Else 73 | DeleteFile path 74 | Local to_stream:TStream=WriteStream(path) 75 | CopyBytes stream,to_stream,size 76 | to_stream.Close 77 | EndIf 78 | 79 | SetFileMode path,Mode 80 | Return True 81 | 82 | End Function 83 | 84 | Function ZapMod( name$,stream:TStream ) 85 | 86 | Local path$=ModuleInterface( name,"release."+opt_target_platform+"."+opt_arch ) 87 | 88 | If FileType(path)<>FILETYPE_FILE 89 | Print "Failed to find module" 90 | Return 91 | EndIf 92 | 93 | Local src:TSourceFile=ParseSourceFile( path ) 94 | stream.WriteLine "Module: "+name 95 | For Local t$=EachIn src.info 96 | stream.WriteLine t 97 | Next 98 | stream.WriteLine "" 99 | 100 | Local bank:TBank=TBank.Create(0) 101 | Local bank_stream:TStream=TBankStream.Create( bank ) 102 | If Not Zap( ModulePath(name),bank_stream ) Throw "Failed to publish module" 103 | bank_stream.Close 104 | 105 | bank=CompressBank( bank ) 106 | bank_stream=TBankStream.Create( bank ) 107 | CopyStream bank_stream,stream 108 | bank_stream.Close 109 | 110 | End Function 111 | 112 | Function UnzapMod( stream:TStream ) 113 | 114 | Local modinfo:TModInfo=TModInfo.CreateFromStream( stream ) 115 | 116 | Local path$=ModulePath( modinfo.name ) 117 | If Not CreateDir( path,True ) Throw "Unable to create module directory" 118 | DeleteDir path,True 119 | 120 | Local bank:TBank=TBank.Create(0) 121 | Local bank_stream:TStream=TBankStream.Create( bank ) 122 | CopyStream stream,bank_stream 123 | bank_stream.Close 124 | 125 | bank=UncompressBank( bank ) 126 | bank_stream=TBankStream.Create( bank ) 127 | If Not Unzap( ExtractDir(path),bank_stream ) 128 | Print "Failed to Unzap module" 129 | Return 130 | EndIf 131 | bank_stream.Close 132 | 133 | ?MacOS 134 | Ranlib path 135 | ? 136 | Return True 137 | 138 | End Function 139 | -------------------------------------------------------------------------------- /stringbuffer_common.bmx: -------------------------------------------------------------------------------- 1 | ' Copyright (c) 2016-2017 Bruce A Henderson 2 | ' 3 | ' Permission is hereby granted, free of charge, to any person obtaining a copy 4 | ' of this software and associated documentation files (the "Software"), to deal 5 | ' in the Software without restriction, including without limitation the rights 6 | ' to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | ' copies of the Software, and to permit persons to whom the Software is 8 | ' furnished to do so, subject to the following conditions: 9 | ' 10 | ' The above copyright notice and this permission notice shall be included in 11 | ' all copies or substantial portions of the Software. 12 | ' 13 | ' THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | ' IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | ' FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | ' AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | ' LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | ' OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | ' THE SOFTWARE. 20 | ' 21 | SuperStrict 22 | 23 | Import "stringbuffer_glue.c" 24 | ?Not bmxng 25 | Import "stringbuffer_uni_conv.c" 26 | ? 27 | 28 | Extern 29 | Function bmx_stringbuffer_new:Byte Ptr(initial:Int) 30 | Function bmx_stringbuffer_free(buffer:Byte Ptr) 31 | 32 | Function bmx_stringbuffer_count:Int(buffer:Byte Ptr) 33 | Function bmx_stringbuffer_capacity:Int(buffer:Byte Ptr) 34 | Function bmx_stringbuffer_setlength(buffer:Byte Ptr, length:Int) 35 | Function bmx_stringbuffer_tostring:String(buffer:Byte Ptr) 36 | Function bmx_stringbuffer_append_string(buffer:Byte Ptr, value:String) 37 | Function bmx_stringbuffer_remove(buffer:Byte Ptr, startIndex:Int, endIndex:Int) 38 | Function bmx_stringbuffer_insert(buffer:Byte Ptr, offset:Int, value:String) 39 | Function bmx_stringbuffer_reverse(buffer:Byte Ptr) 40 | Function bmx_stringbuffer_substring:String(buffer:Byte Ptr, beginIndex:Int, endIndex:Int) 41 | Function bmx_stringbuffer_append_stringbuffer(buffer:Byte Ptr, buffer2:Byte Ptr) 42 | Function bmx_stringbuffer_startswith:Int(buffer:Byte Ptr, subString:String) 43 | Function bmx_stringbuffer_endswith:Int(buffer:Byte Ptr, subString:String) 44 | Function bmx_stringbuffer_find:Int(buffer:Byte Ptr, subString:String, startIndex:Int) 45 | Function bmx_stringbuffer_findlast:Int(buffer:Byte Ptr, subString:String, startIndex:Int) 46 | Function bmx_stringbuffer_tolower(buffer:Byte Ptr) 47 | Function bmx_stringbuffer_toupper(buffer:Byte Ptr) 48 | Function bmx_stringbuffer_trim(buffer:Byte Ptr) 49 | Function bmx_stringbuffer_replace(buffer:Byte Ptr, subString:String, withString:String) 50 | Function bmx_stringbuffer_join(buffer:Byte Ptr, bits:String[], newBuffer:Byte Ptr) 51 | Function bmx_stringbuffer_split:Byte Ptr(buffer:Byte Ptr, separator:String) 52 | Function bmx_stringbuffer_setcharat(buffer:Byte Ptr, index:Int, char:Int) 53 | Function bmx_stringbuffer_charat:Int(buffer:Byte Ptr, index:Int) 54 | Function bmx_stringbuffer_removecharat(buffer:Byte Ptr, index:Int) 55 | Function bmx_stringbuffer_append_cstring(buffer:Byte Ptr, chars:Byte Ptr) 56 | Function bmx_stringbuffer_append_utf8string(buffer:Byte Ptr, chars:Byte Ptr) 57 | 58 | Function bmx_stringbuffer_splitbuffer_length:Int(splitPtr:Byte Ptr) 59 | Function bmx_stringbuffer_splitbuffer_text:String(splitPtr:Byte Ptr, index:Int) 60 | Function bmx_stringbuffer_splitbuffer_free(splitPtr:Byte Ptr) 61 | Function bmx_stringbuffer_splitbuffer_toarray:String[](splitPtr:Byte Ptr) 62 | 63 | End Extern 64 | 65 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-jai.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 26 | 27 | org.apache.ant 28 | ant-parent 29 | ../pom.xml 30 | 1.9.4 31 | 32 | 4.0.0 33 | http://ant.apache.org/ 34 | org.apache.ant 35 | ant-jai 36 | 1.9.4 37 | Apache Ant + JAI 38 | image task and corresponding types. 39 | 40 | 41 | 42 | org.apache.ant 43 | ant 44 | 1.9.4 45 | compile 46 | 47 | 48 | javax.media 49 | jai-core 50 | 1.1.3 51 | 52 | 53 | com.sun.media 54 | jai-codec 55 | 1.1.3 56 | 57 | 58 | 59 | 60 | 61 | jboss 62 | JBoss 63 | https://repository.jboss.org/nexus/content/groups/public/ 64 | 65 | 66 | 67 | 68 | 69 | org.apache.maven.plugins 70 | maven-compiler-plugin 71 | 72 | 73 | org/apache/tools/ant/taskdefs/optional/image/* 74 | org/apache/tools/ant/types/optional/image/* 75 | 76 | 77 | 78 | 79 | ../../../../src/main 80 | ../../../../src/testcases 81 | ../../../../target/${project.artifactId}/classes 82 | ../../../../target/${project.artifactId}/testcases 83 | ../../../../target/${project.artifactId} 84 | 85 | 86 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/antenv.cmd: -------------------------------------------------------------------------------- 1 | /* 2 | Licensed to the Apache Software Foundation (ASF) under one or more 3 | contributor license agreements. See the NOTICE file distributed with 4 | this work for additional information regarding copyright ownership. 5 | The ASF licenses this file to You under the Apache License, Version 2.0 6 | (the "License"); you may not use this file except in compliance with 7 | the License. You may obtain a copy of the License at 8 | 9 | http://www.apache.org/licenses/LICENSE-2.0 10 | 11 | Unless required by applicable law or agreed to in writing, software 12 | distributed under the License is distributed on an "AS IS" BASIS, 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | See the License for the specific language governing permissions and 15 | limitations under the License. 16 | */ 17 | 18 | '@echo off' 19 | call RxFuncAdd "SysLoadFuncs", "RexxUtil", "SysLoadFuncs" 20 | call SysLoadFuncs 21 | 22 | /* Prepare the parameters for later use */ 23 | parse arg argv 24 | mode = '' 25 | args = '' 26 | opts = '' 27 | cp = '' 28 | lcp = '' 29 | 30 | do i = 1 to words(argv) 31 | param = word(argv, i) 32 | select 33 | when param='-lcp' then mode = 'l' 34 | when param='-cp' | param='-classpath' then mode = 'c' 35 | when abbrev('-opts', param, 4) then mode = 'o' 36 | when abbrev('-args', param, 4) then mode = 'a' 37 | otherwise 38 | select 39 | when mode = 'a' then args = space(args param, 1) 40 | when mode = 'c' then cp = space(cp param, 1) 41 | when mode = 'l' then lcp = space(lcp param, 1) 42 | when mode = 'o' then opts = space(opts param, 1) 43 | otherwise 44 | say 'Option' param 'ignored' 45 | end 46 | end 47 | end 48 | 49 | env="OS2ENVIRONMENT" 50 | antconf = _getenv_('antconf' 'antconf.cmd') 51 | runrc = _getenv_('runrc') 52 | interpret 'call "' || runrc || '"' '"' || antconf || '"' 'ETC' 53 | ANT_HOME = value('ANT_HOME',,env) 54 | JAVA_HOME = value('JAVA_HOME',,env) 55 | classpath = value('CLASSPATH',,env) 56 | classes = stream(JAVA_HOME || "\lib\classes.zip", "C", "QUERY EXISTS") 57 | if classes \= '' then classpath = prepend(classpath classes) 58 | classes = stream(JAVA_HOME || "\lib\tools.jar", "C", "QUERY EXISTS") 59 | if classes \= '' then classpath = prepend(classpath classes) 60 | 61 | classpath = prepend(classpath ANT_HOME || '\lib\ant-launcher.jar') 62 | 'SET CLASSPATH=' || classpath 63 | 64 | /* Setting classpathes, options and arguments */ 65 | envset = _getenv_('envset') 66 | if cp\='' then interpret 'call "' || envset || '"' '"; CLASSPATH"' '"' || cp || '"' 67 | if lcp\='' then interpret 'call "' || envset || '"' '"; LOCALCLASSPATH"' '"' || lcp || '"' 68 | if opts\='' then interpret 'call "' || envset || '"' '"-D ANT_OPTS"' '"' || opts || '"' 69 | if args\='' then interpret 'call "' || envset || '"' '"ANT_ARGS"' '"' || args || '"' 70 | 71 | exit 0 72 | 73 | addpath: procedure 74 | parse arg path elem 75 | if elem = '' then do 76 | if path\='' & right(path, 1)\=';' then path = path || ';' 77 | return path 78 | end 79 | if substr(path, length(path)) = ';' then glue = '' 80 | else glue = ';' 81 | if pos(translate(elem), translate(path)) = 0 then path = path || glue || elem || ';' 82 | return path 83 | 84 | prepend: procedure 85 | parse arg path elem 86 | if elem = '' then do 87 | if path\='' & right(path, 1)\=';' then path = path || ';' 88 | return path 89 | end 90 | if pos(translate(elem), translate(path)) = 0 then path = elem || ';' || path 91 | return path 92 | 93 | _getenv_: procedure expose env 94 | parse arg envar default 95 | if default = '' then default = envar 96 | var = value(translate(envar),,env) 97 | if var = '' then var = default 98 | return var 99 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/runant.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # Licensed to the Apache Software Foundation (ASF) under one or more 3 | # contributor license agreements. See the NOTICE file distributed with 4 | # this work for additional information regarding copyright ownership. 5 | # The ASF licenses this file to You under the Apache License, Version 2.0 6 | # (the "License"); you may not use this file except in compliance with 7 | # the License. You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, software 12 | # distributed under the License is distributed on an "AS IS" BASIS, 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | # See the License for the specific language governing permissions and 15 | # limitations under the License. 16 | # 17 | 18 | """ 19 | 20 | runant.py 21 | 22 | This script is a translation of the runant.pl written by Steve Loughran. 23 | It runs ant with/out arguments, it should be quite portable (thanks to 24 | the python os library) 25 | This script has been tested with Python2.0/Win2K 26 | 27 | created: 2001-04-11 28 | author: Pierre Dittgen pierre.dittgen@criltelecom.com 29 | 30 | Assumptions: 31 | 32 | - the "java" executable/script is on the command path 33 | """ 34 | import os, os.path, string, sys 35 | 36 | # Change it to 1 to get extra debug information 37 | debug = 0 38 | 39 | ####################################################################### 40 | 41 | # If ANT_HOME is not set default to script's parent directory 42 | if os.environ.has_key('ANT_HOME'): 43 | ANT_HOME = os.environ['ANT_HOME'] 44 | else: 45 | ANT_HOME = os.path.dirname(os.path.dirname(os.path.abspath(sys.argv[0]))) 46 | 47 | # set ANT_LIB location 48 | ANT_LIB = os.path.join(ANT_HOME, 'lib') 49 | 50 | # set JAVACMD (check variables JAVACMD and JAVA_HOME) 51 | JAVACMD = None 52 | if not os.environ.has_key('JAVACMD'): 53 | if os.environ.has_key('JAVA_HOME'): 54 | if not os.path.exists(os.environ['JAVA_HOME']): 55 | print "Warning: JAVA_HOME is not defined correctly." 56 | else: 57 | JAVACMD = os.path.join(os.environ['JAVA_HOME'], 'bin', 'java') 58 | else: 59 | print "Warning: JAVA_HOME not set." 60 | else: 61 | JAVACMD = os.environ['JAVACMD'] 62 | if not JAVACMD: 63 | JAVACMD = 'java' 64 | 65 | launcher_jar = os.path.join(ANT_LIB, 'ant-launcher.jar') 66 | if not os.path.exists(launcher_jar): 67 | print 'Warning: Unable to locate ant-launcher.jar. Expected to find it in %s' % \ 68 | ANT_LIB 69 | 70 | # Build up standard classpath (LOCALCLASSPATH) 71 | LOCALCLASSPATH = launcher_jar 72 | if os.environ.has_key('LOCALCLASSPATH'): 73 | LOCALCLASSPATH += os.pathsep + os.environ['LOCALCLASSPATH'] 74 | 75 | ANT_OPTS = "" 76 | if os.environ.has_key('ANT_OPTS'): 77 | ANT_OPTS = os.environ['ANT_OPTS'] 78 | 79 | OPTS = "" 80 | if os.environ.has_key('JIKESPATH'): 81 | OPTS = '-Djikes.class.path=\"%s\"' % os.environ['JIKESPATH'] 82 | 83 | ANT_ARGS = "" 84 | if os.environ.has_key('ANT_ARGS'): 85 | ANT_ARGS = os.environ['ANT_ARGS'] 86 | 87 | CLASSPATH = "" 88 | if os.environ.has_key('CLASSPATH'): 89 | CLASSPATH = "-lib " + os.environ['CLASSPATH'] 90 | 91 | # Builds the commandline 92 | cmdline = ('%s %s -classpath %s -Dant.home=%s %s ' + \ 93 | 'org.apache.tools.ant.launch.Launcher %s %s %s') \ 94 | % (JAVACMD, ANT_OPTS, LOCALCLASSPATH, ANT_HOME, OPTS, ANT_ARGS, \ 95 | CLASSPATH, string.join(sys.argv[1:], ' ')) 96 | 97 | if debug: 98 | print '\n%s\n\n' % (cmdline) 99 | sys.stdout.flush() 100 | 101 | # Run the biniou! 102 | os.system(cmdline) 103 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/complete-ant-cmd.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | # 3 | # Licensed to the Apache Software Foundation (ASF) under one or more 4 | # contributor license agreements. See the NOTICE file distributed with 5 | # this work for additional information regarding copyright ownership. 6 | # The ASF licenses this file to You under the Apache License, Version 2.0 7 | # (the "License"); you may not use this file except in compliance with 8 | # the License. You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | # 18 | # A script to allow Bash or Z-Shell to complete an Ant command-line. 19 | # 20 | # To install for Bash 2.0 or better, add the following to ~/.bashrc: 21 | # 22 | # complete -C complete-ant-cmd.pl ant build.sh 23 | # 24 | # To install for Z-Shell 2.5 or better, add the following to ~/.zshrc: 25 | # 26 | # function ant_complete () { 27 | # local args_line args 28 | # read -l args_line 29 | # set -A args $args_line 30 | # set -A reply $(COMP_LINE=$args_line complete-ant-cmd.pl ${args[1]} $1) 31 | # } 32 | # compctl -K ant_complete ant build.sh 33 | # 34 | # @author Mike Williams 35 | 36 | my $cmdLine = $ENV{'COMP_LINE'}; 37 | my $antCmd = $ARGV[0]; 38 | my $word = $ARGV[1]; 39 | 40 | my @completions; 41 | if ($word =~ /^-/) { 42 | list( restrict( $word, getArguments() )); 43 | } elsif ($cmdLine =~ /-(f|buildfile)\s+\S*$/) { 44 | list( getBuildFiles($word) ); 45 | } else { 46 | list( restrict( $word, getTargets() )); 47 | } 48 | 49 | exit(0); 50 | 51 | sub list { 52 | for (@_) { 53 | print "$_\n"; 54 | } 55 | } 56 | 57 | sub restrict { 58 | my ($word, @completions) = @_; 59 | grep( /^\Q$word\E/, @completions ); 60 | } 61 | 62 | sub getArguments { 63 | qw(-buildfile -debug -emacs -f -find -help -listener -logfile 64 | -logger -projecthelp -quiet -verbose -version); 65 | } 66 | 67 | 68 | sub getBuildFiles { 69 | my ($word) = @_; 70 | grep( /\.xml$/, glob( "$word*" )); 71 | } 72 | 73 | sub getTargets { 74 | 75 | # Look for build-file 76 | my $buildFile = 'build.xml'; 77 | if ($cmdLine =~ /-(f|buildfile)\s+(\S+)/) { 78 | $buildFile = $2; 79 | } 80 | return () unless (-f $buildFile); 81 | 82 | # Run "ant -projecthelp" to list targets. Keep a cache of results in a 83 | # cache-file. 84 | my $cacheFile = $buildFile; 85 | $cacheFile =~ s|(.*/)?(.*)|${1}.ant-targets-${2}|; 86 | if ((!-e $cacheFile) || (-z $cacheFile) || (-M $buildFile) < (-M $cacheFile)) { 87 | open( CACHE, '>'.$cacheFile ) || die "can\'t write $cacheFile: $!\n"; 88 | open( HELP, "$antCmd -projecthelp -f '$buildFile'|" ) || return(); 89 | my %targets; 90 | while( ) { 91 | if (/^\s+(\S+)/) { 92 | $targets{$1}++; 93 | } 94 | } 95 | my @targets = sort keys %targets; 96 | for (@targets) { print CACHE "$_\n"; } 97 | return @targets; 98 | } 99 | 100 | # Read the target-cache 101 | open( CACHE, $cacheFile ) || die "can\'t read $cacheFile: $!\n"; 102 | my @targets; 103 | while () { 104 | chop; 105 | s/\r$//; # for Cygwin 106 | push( @targets, $_ ); 107 | } 108 | close( CACHE ); 109 | @targets; 110 | 111 | } 112 | 113 | 114 | 115 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-apache-xalan2.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-apache-xalan2 35 | 1.9.4 36 | Apache Ant + Xalan 2 37 | contains Xalan2-specific features 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | xalan 47 | xalan 48 | 2.7.1 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | maven-antrun-plugin 56 | 57 | 58 | create-timestamp-file 59 | generate-resources 60 | 61 | run 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | org.apache.maven.plugins 80 | maven-compiler-plugin 81 | 82 | 83 | org/apache/tools/ant/taskdefs/optional/Xalan2TraceSupport* 84 | 85 | 86 | 87 | 88 | ../../../../src/main 89 | ../../../../src/testcases 90 | ../../../../target/${project.artifactId}/classes 91 | ../../../../target/${project.artifactId}/testcases 92 | ../../../../target/${project.artifactId} 93 | 94 | 95 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-netrexx.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-netrexx 35 | 1.9.4 36 | Apache Ant + NetRexx 37 | NetRexxC task 38 | dependency can be downloaded from http://www.ibm.com/software/awdtools/netrexx/download.html 39 | 40 | 41 | org.apache.ant 42 | ant 43 | 1.9.4 44 | compile 45 | 46 | 55 | 56 | 57 | 58 | 59 | org.apache.maven.plugins 60 | maven-compiler-plugin 61 | 62 | 63 | org/apache/tools/ant/taskdefs/optional/NetRexxC* 64 | 65 | 66 | 67 | ${basedir}/../../../../lib/optional 68 | 69 | 70 | 71 | 72 | org.apache.maven.plugins 73 | maven-antrun-plugin 74 | 1.4 75 | 76 | 77 | validate 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | run 87 | 88 | 89 | 90 | 91 | 92 | ../../../../src/main 93 | ../../../../src/testcases 94 | ../../../../target/${project.artifactId}/classes 95 | ../../../../target/${project.artifactId}/testcases 96 | ../../../../target/${project.artifactId} 97 | 98 | 99 | -------------------------------------------------------------------------------- /resources/android/android-project/build.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 8 | 9 | 10 | 30 | 31 | 32 | 36 | 37 | 38 | 39 | 40 | 41 | 50 | 51 | 52 | 53 | 57 | 58 | 70 | 71 | 72 | 90 | 91 | 92 | 93 | 94 | -------------------------------------------------------------------------------- /resources/android/apache-ant/README: -------------------------------------------------------------------------------- 1 | 2 | A N T 3 | 4 | 5 | What is it? 6 | ----------- 7 | 8 | Ant is a Java based build tool. In theory it is kind of like "make" 9 | without makes wrinkles and with the full portability of pure java code. 10 | 11 | 12 | Why? 13 | ---- 14 | 15 | Why another build tool when there is already make, gnumake, nmake, jam, 16 | and others? Because all of those tools have limitations that its original 17 | author couldn't live with when developing software across multiple platforms. 18 | 19 | Make-like tools are inherently shell based. They evaluate a set of 20 | dependencies and then execute commands not unlike what you would issue on a 21 | shell. This means that you can easily extend these tools by using or writing 22 | any program for the OS that you are working on. However, this also means that 23 | you limit yourself to the OS, or at least the OS type such as Unix, that you 24 | are working on. 25 | 26 | Makefiles are inherently evil as well. Anybody who has worked on them for any 27 | time has run into the dreaded tab problem. "Is my command not executing 28 | because I have a space in front of my tab!!!" said the original author of Ant 29 | way too many times. Tools like Jam took care of this to a great degree, but 30 | still use yet another format to use and remember. 31 | 32 | Ant is different. Instead a model where it is extended with shell based 33 | commands, it is extended using Java classes. Instead of writing shell 34 | commands, the configuration files are XML based calling out a target tree 35 | where various tasks get executed. Each task is run by an object which 36 | implements a particular Task interface. 37 | 38 | Granted, this removes some of the expressive power that is inherent by being 39 | able to construct a shell command such as `find . -name foo -exec rm {}` but 40 | it gives you the ability to be cross platform. To work anywhere and 41 | everywhere. And hey, if you really need to execute a shell command, Ant has 42 | an exec rule that allows different commands to be executed based on the OS 43 | that it is executing on. 44 | 45 | The Latest Version 46 | ------------------ 47 | 48 | Details of the latest version can be found on the Apache Ant 49 | Project web site . 50 | 51 | 52 | Documentation 53 | ------------- 54 | 55 | Documentation is available in HTML format, in the docs/ directory. 56 | For information about building and installing Ant, see 57 | docs/manual/index.html 58 | 59 | 60 | Licensing 61 | --------- 62 | 63 | This software is licensed under the terms you may find in the file 64 | named "LICENSE" in this directory. 65 | 66 | This distribution includes cryptographic software. The country in 67 | which you currently reside may have restrictions on the import, 68 | possession, use, and/or re-export to another country, of 69 | encryption software. BEFORE using any encryption software, please 70 | check your country's laws, regulations and policies concerning the 71 | import, possession, or use, and re-export of encryption software, to 72 | see if this is permitted. See for more 73 | information. 74 | 75 | The U.S. Government Department of Commerce, Bureau of Industry and 76 | Security (BIS), has classified this software as Export Commodity 77 | Control Number (ECCN) 5D002.C.1, which includes information security 78 | software using or performing cryptographic functions with asymmetric 79 | algorithms. The form and manner of this Apache Software Foundation 80 | distribution makes it eligible for export under the License Exception 81 | ENC Technology Software Unrestricted (TSU) exception (see the BIS 82 | Export Administration Regulations, Section 740.13) for both object 83 | code and source code. 84 | 85 | The following provides more details on the included cryptographic 86 | software: 87 | 88 | For the SSH family of tasks ( and ) Ant requires the 89 | JSch library as well as the 90 | Java Cryptography extensions 91 | . Ant does not 92 | include these libraries itself, but is designed to use them. 93 | 94 | Thanks for using Ant. 95 | 96 | The Apache Ant Project 97 | 98 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-junit.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 26 | org.apache.ant 27 | ant-parent 28 | ../pom.xml 29 | 1.9.4 30 | 31 | 4.0.0 32 | http://ant.apache.org/ 33 | org.apache.ant 34 | ant-junit 35 | 1.9.4 36 | Apache Ant + JUnit 37 | contains the junit and junirreport tasks 38 | 39 | 40 | org.apache.ant 41 | ant 42 | 1.9.4 43 | compile 44 | 45 | 46 | junit 47 | junit 48 | 4.11 49 | compile 50 | 51 | 52 | 53 | 54 | 55 | maven-antrun-plugin 56 | 57 | 58 | create-timestamp-file 59 | generate-resources 60 | 61 | run 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | org.apache.maven.plugins 80 | maven-compiler-plugin 81 | 82 | 83 | org/apache/tools/ant/taskdefs/optional/junit/* 84 | 85 | 86 | org/apache/tools/ant/taskdefs/optional/junit/JUnit4TestMethodAdapter* 87 | org/apache/tools/ant/taskdefs/optional/junit/CustomJUnit4TestAdapterCache* 88 | 89 | 90 | org/apache/tools/ant/taskdefs/optional/junit/ 91 | 92 | 93 | 94 | 95 | ../../../../src/main 96 | ../../../../src/testcases 97 | ../../../../target/${project.artifactId}/classes 98 | ../../../../target/${project.artifactId}/testcases 99 | ../../../../target/${project.artifactId} 100 | 101 | 102 | -------------------------------------------------------------------------------- /macos/NSProcessInfo_PECocoaBackports.m: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2014 Petroules Corporation. All rights reserved. 3 | * 4 | * Redistribution and use in source and binary forms, with or without 5 | * modification, are permitted provided that the following conditions are met: 6 | * 7 | * 1. Redistributions of source code must retain the above copyright notice, this 8 | * list of conditions and the following disclaimer. 9 | * 2. Redistributions in binary form must reproduce the above copyright notice, 10 | * this list of conditions and the following disclaimer in the documentation 11 | * and/or other materials provided with the distribution. 12 | * 13 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 14 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 15 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 16 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 17 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 18 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 19 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 20 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 22 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 | */ 24 | 25 | #import "NSProcessInfo+PECocoaBackports.h" 26 | 27 | #if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE 28 | #import 29 | #elif defined(TARGET_OS_MAC) && TARGET_OS_MAC 30 | #import 31 | #endif 32 | 33 | @interface NSProcessInfo (PECocoaBackportsPrivate) 34 | 35 | #if LOAD_OPERATING_SYSTEM_VERSION 36 | - (NSOperatingSystemVersion)PECocoaBackports_operatingSystemVersion; 37 | - (BOOL)PECocoaBackports_isOperatingSystemAtLeastVersion:(NSOperatingSystemVersion)version; 38 | #endif 39 | 40 | @end 41 | 42 | @implementation NSProcessInfo (PECocoaBackportsPrivate) 43 | 44 | + (void)load 45 | { 46 | #if LOAD_OPERATING_SYSTEM_VERSION 47 | // Public API since OS X 10.10 (present since 10.9) and iOS 8.0 48 | class_addInstanceMethodIfNecessary([self class], 49 | NSSelectorFromString(@"operatingSystemVersion"), 50 | @selector(PECocoaBackports_operatingSystemVersion)); 51 | 52 | // Public API since OS X 10.10 (present since 10.9) and iOS 8.0 53 | class_addInstanceMethodIfNecessary([self class], 54 | NSSelectorFromString(@"isOperatingSystemAtLeastVersion:"), 55 | @selector(PECocoaBackports_isOperatingSystemAtLeastVersion:)); 56 | #endif 57 | } 58 | 59 | #if LOAD_OPERATING_SYSTEM_VERSION 60 | - (NSOperatingSystemVersion)PECocoaBackports_operatingSystemVersion 61 | { 62 | NSOperatingSystemVersion v = {0, 0, 0}; 63 | SInt32 major = 0, minor = 0, patch = 0; 64 | #if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE 65 | #if !defined(__has_feature) || !__has_feature(objc_arc) 66 | NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; 67 | #endif 68 | NSArray *parts = [[[UIDevice currentDevice] systemVersion] componentsSeparatedByString:@"."]; 69 | major = parts.count > 0 ? [[parts objectAtIndex:0] intValue] : 0; 70 | minor = parts.count > 1 ? [[parts objectAtIndex:1] intValue] : 0; 71 | patch = parts.count > 2 ? [[parts objectAtIndex:2] intValue] : 0; 72 | #if !defined(__has_feature) || !__has_feature(objc_arc) 73 | [pool release]; 74 | #endif 75 | #elif defined(TARGET_OS_MAC) && TARGET_OS_MAC 76 | #pragma clang diagnostic push 77 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 78 | if (Gestalt(gestaltSystemVersionMajor, &major) != noErr) return v; 79 | if (Gestalt(gestaltSystemVersionMinor, &minor) != noErr) return v; 80 | if (Gestalt(gestaltSystemVersionBugFix, &patch) != noErr) return v; 81 | #pragma clang diagnostic pop 82 | #endif 83 | v.majorVersion = major; 84 | v.minorVersion = minor; 85 | v.patchVersion = patch; 86 | return v; 87 | } 88 | 89 | - (BOOL)PECocoaBackports_isOperatingSystemAtLeastVersion:(NSOperatingSystemVersion)version 90 | { 91 | const NSOperatingSystemVersion systemVersion = [self operatingSystemVersion]; 92 | if (systemVersion.majorVersion == version.majorVersion) { 93 | if (systemVersion.minorVersion == version.minorVersion) { 94 | return systemVersion.patchVersion >= version.patchVersion; 95 | } 96 | return systemVersion.minorVersion >= version.minorVersion; 97 | } 98 | return systemVersion.majorVersion >= version.majorVersion; 99 | } 100 | #endif 101 | 102 | @end -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/envset.cmd: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Licensed to the Apache Software Foundation (ASF) under one or more 4 | contributor license agreements. See the NOTICE file distributed with 5 | this work for additional information regarding copyright ownership. 6 | The ASF licenses this file to You under the Apache License, Version 2.0 7 | (the "License"); you may not use this file except in compliance with 8 | the License. You may obtain a copy of the License at 9 | 10 | http://www.apache.org/licenses/LICENSE-2.0 11 | 12 | Unless required by applicable law or agreed to in writing, software 13 | distributed under the License is distributed on an "AS IS" BASIS, 14 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | See the License for the specific language governing permissions and 16 | limitations under the License. 17 | 18 | SET environment variables 19 | First optional parameter: 20 | ; parameters are considered parts of a path variable, semicolons are 21 | appended to each element if not already present 22 | -D parameters are properties for Java or Makefile etc., -D will be 23 | prepended and the parameters will be separated by a space 24 | =D the same as above but equal sign is not required 25 | , parameters should be comma separated in the environment variable 26 | - parameters should be separated by the next parameter 27 | Other values mean that the first parameter is missing and the environment 28 | variable will be set to the space separated parameters 29 | 30 | Second parameter: name of the environment variable 31 | 32 | Next parameters: values 33 | ; implies that the equal sign is considered a part of the parameter and is 34 | not interpreted 35 | 36 | -D requires parameters in the form name=value. If the equal sign is not found, 37 | the parameters are changed to name=expanded_name 38 | 39 | Other options have optional equal sign. If it is found, only the part after 40 | the equal sign will be oprionally expanded. 41 | 42 | If the parameter is the minus sign, the next parameter will not be expanded. 43 | If the parameter is a single dot, it will be replaced with the value of the 44 | environment variable as it existed before envset was invoked. 45 | 46 | For other parameters the batch looks for the environment variable with the 47 | same name (in uppercase). If it is found, it forms the expanded_name. If 48 | the environment variable with such a name does not exist, the expanded_name 49 | will hold the parameter name without case conversion. 50 | */ 51 | 52 | parse arg mode envar args 53 | 54 | equal = 0 55 | sep = ' ' 56 | 57 | /* Parse command line parameters */ 58 | select 59 | when mode='-' then do 60 | sep = envar 61 | parse var args envar args 62 | end 63 | when mode=';' then do 64 | sep = '' 65 | equal = -1 66 | end 67 | when mode='-D' then equal = 1 68 | when mode='=D' then mode = '-D' 69 | when mode=',' then sep = ',' 70 | otherwise 71 | args = envar args 72 | envar = mode 73 | mode = '' 74 | end 75 | 76 | env = 'OS2ENVIRONMENT' 77 | envar = translate(envar) 78 | orig = value(envar,,env) 79 | newval = '' 80 | expand = 1 81 | 82 | /* for each parameter... */ 83 | do i = 1 to words(args) 84 | if expand > 0 & word(args, i) = '-' then expand = 0 85 | else call addval word(args, i) 86 | end 87 | 88 | /* Optionally enclose path variable by quotes */ 89 | if mode = ';' & pos(' ', newval) > 0 then newval = '"' || newval || '"' 90 | 91 | /* Set the new value, 'SET' cannot be used since it does not allow '=' */ 92 | x = value(envar, newval, env) 93 | exit 0 94 | 95 | addval: procedure expose sep equal orig expand newval mode env 96 | parse arg var 97 | 98 | if var = '.' then expvar = orig 99 | else do 100 | if equal >= 0 then do 101 | parse var var name '=' val 102 | if val = '' then var = name 103 | else var = val 104 | end 105 | if expand = 0 then expvar = var 106 | else expvar = value(translate(var),,env) 107 | if expvar = '' then expvar = var 108 | if equal >= 0 then do 109 | if val = '' then do 110 | parse var expvar key '=' val 111 | if val <> '' then name = key 112 | else do 113 | if equal > 0 then val = key 114 | else name = key 115 | end 116 | end 117 | else val = expvar 118 | if pos(' ', val) > 0 | pos('=', val) > 0 then val = '"' || val || '"' 119 | if val = '' then expvar = name 120 | else expvar = name || '=' || val 121 | end 122 | if mode = '-D' then expvar = '-D' || expvar 123 | if mode = ';' then do 124 | if right(expvar, 1) <> ';' then expvar = expvar || ';' 125 | end 126 | end 127 | 128 | if newval = '' then newval = expvar 129 | else newval = newval || sep || expvar 130 | expand = 1 131 | return 132 | -------------------------------------------------------------------------------- /resources/android/apache-ant/get-m2.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 19 | 24 | 25 | 26 | 27 | This build file downloads the Maven2 Ant tasks, 28 | and installs them in the location specified by the m2.dest.dir property. 29 | 30 | You may need to set proxy settings. On Java1.5, Ant tries to get 31 | this from the OS, unless you use the -noproxy option. 32 | 33 | Proxies can be configured manually setting the JVM proxy values in the 34 | ANT_OPTS environment variable. 35 | 36 | For example, to set the proxy up in the tcsh shell, the command would be 37 | something like: 38 | 39 | For csh/tcsh: 40 | setenv ANT_OPTS "-Dhttp.proxyHost=proxy -Dhttp.proxyPort=8080" 41 | For bash: 42 | export ANT_OPTS="-Dhttp.proxyHost=proxy -Dhttp.proxyPort=8080" 43 | For Windows, set the environment variable in the appropriate dialog box 44 | and open a new console. or, by hand 45 | set ANT_OPTS = -Dhttp.proxyHost=proxy -Dhttp.proxyPort=8080 46 | 47 | 48 | 49 | 50 | 52 | 53 | 55 | 56 | 57 | 58 | 59 | $${@{property}} not specified 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | Downloading to ${m2.dest.dir} 79 | 80 | 81 | 82 | 86 | 87 | 88 | 90 | 91 | 92 | 93 | 96 | 100 | 101 | 102 | 104 | 105 | 106 | Failed to verify the downloaded file ${m2.antlib.url}" against the checksum 107 | coded into libraries.properties. 108 | The local copy has been deleted, for security reasons 109 | 110 | 111 | 112 | 114 | 116 | 117 | 118 | 120 | 121 | 122 | -------------------------------------------------------------------------------- /resources/android/apache-ant/bin/runant.pl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | # 3 | # Licensed to the Apache Software Foundation (ASF) under one or more 4 | # contributor license agreements. See the NOTICE file distributed with 5 | # this work for additional information regarding copyright ownership. 6 | # The ASF licenses this file to You under the Apache License, Version 2.0 7 | # (the "License"); you may not use this file except in compliance with 8 | # the License. You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | # 18 | ####################################################################### 19 | # 20 | # runant.pl 21 | # 22 | # wrapper script for invoking ant in a platform with Perl installed 23 | # this may include cgi-bin invocation, which is considered somewhat daft. 24 | # (slo: that should be a separate file which can be derived from this 25 | # and returns the XML formatted output) 26 | # 27 | # the code is not totally portable due to classpath and directory splitting 28 | # issues. oops. (NB, use File::Spec::Functions will help and the code is 29 | # structured for the catfile() call, but because of perl version funnies 30 | # the code is not included. 31 | # 32 | # created: 2000-8-24 33 | # author: Steve Loughran steve_l@sourceforge.net 34 | ####################################################################### 35 | # 36 | # Assumptions: 37 | # 38 | # - the "java" executable/script is on the command path 39 | # - ANT_HOME has been set 40 | # - target platform uses ":" as classpath separator or perl indicates it is dos/win32 41 | # - target platform uses "/" as directory separator. 42 | 43 | #be fussy about variables 44 | use strict; 45 | 46 | #platform specifics (disabled) 47 | #use File::Spec::Functions; 48 | 49 | #turn warnings on during dev; generates a few spurious uninitialised var access warnings 50 | #use warnings; 51 | 52 | #and set $debug to 1 to turn on trace info 53 | my $debug=1; 54 | 55 | ####################################################################### 56 | # 57 | # check to make sure environment is setup 58 | # 59 | 60 | my $HOME = $ENV{ANT_HOME}; 61 | if ($HOME eq "") 62 | { 63 | die "\n\nANT_HOME *MUST* be set!\n\n"; 64 | } 65 | 66 | my $JAVACMD = $ENV{JAVACMD}; 67 | $JAVACMD = "java" if $JAVACMD eq ""; 68 | 69 | my $onnetware = 0; 70 | if ($^O eq "NetWare") 71 | { 72 | $onnetware = 1; 73 | } 74 | 75 | my $oncygwin = ($^O eq "cygwin"); 76 | 77 | #ISSUE: what java wants to split up classpath varies from platform to platform 78 | #and perl is not too hot at hinting which box it is on. 79 | #here I assume ":" 'cept on win32, dos, and netware. Add extra tests here as needed. 80 | my $s=":"; 81 | if(($^O eq "MSWin32") || ($^O eq "dos") || ($^O eq "cygwin") || 82 | ($onnetware == 1)) 83 | { 84 | $s=";"; 85 | } 86 | 87 | #build up standard classpath 88 | my $localpath = "$HOME/lib/ant-launcher.jar"; 89 | #set JVM options and Ant arguments, if any 90 | my @ANT_OPTS=split(" ", $ENV{ANT_OPTS}); 91 | my @ANT_ARGS=split(" ", $ENV{ANT_ARGS}); 92 | 93 | #jikes 94 | if($ENV{JIKESPATH} ne "") 95 | { 96 | push @ANT_OPTS, "-Djikes.class.path=$ENV{JIKESPATH}"; 97 | } 98 | 99 | #construct arguments to java 100 | my @ARGS; 101 | push @ARGS, @ANT_OPTS; 102 | 103 | my $CYGHOME = ""; 104 | 105 | my $classpath=$ENV{CLASSPATH}; 106 | if ($oncygwin == 1) { 107 | $localpath = `cygpath --path --windows $localpath`; 108 | chomp ($localpath); 109 | if (! $classpath eq "") 110 | { 111 | $classpath = `cygpath --path --windows "$classpath"`; 112 | chomp ($classpath); 113 | } 114 | $HOME = `cygpath --path --windows $HOME`; 115 | chomp ($HOME); 116 | $CYGHOME = `cygpath --path --windows $ENV{HOME}`; 117 | chomp ($CYGHOME); 118 | } 119 | push @ARGS, "-classpath", "$localpath"; 120 | push @ARGS, "-Dant.home=$HOME"; 121 | if ( ! $CYGHOME eq "" ) 122 | { 123 | push @ARGS, "-Dcygwin.user.home=\"$CYGHOME\"" 124 | } 125 | push @ARGS, "org.apache.tools.ant.launch.Launcher", @ANT_ARGS; 126 | push @ARGS, @ARGV; 127 | if (! $classpath eq "") 128 | { 129 | if ($onnetware == 1) 130 | { 131 | # make classpath literally $CLASSPATH 132 | # this is to avoid pushing us over the 512 character limit 133 | # even skip the ; - that is already in $localpath 134 | push @ARGS, "-lib", "\$CLASSPATH"; 135 | } 136 | else 137 | { 138 | push @ARGS, "-lib", "$classpath"; 139 | } 140 | } 141 | print "\n $JAVACMD @ARGS\n\n" if ($debug); 142 | 143 | my $returnValue = system $JAVACMD, @ARGS; 144 | if ($returnValue eq 0) 145 | { 146 | exit 0; 147 | } 148 | else 149 | { 150 | # only 0 and 1 are widely recognized as exit values 151 | # so change the exit value to 1 152 | exit 1; 153 | } 154 | -------------------------------------------------------------------------------- /bmk_pm_legacy.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Import "bmk_ng_utils.bmx" 4 | 5 | Type TProcessManager 6 | 7 | Field pool:TThreadPool 8 | 9 | Field cpuCount:Int 10 | 11 | Field threads:TList = New TList 12 | 13 | Method New() 14 | cpuCount = GetCoreCount() 15 | 16 | pool = TThreadPool.Create(Max(1, cpuCount - 1), cpuCount * 6) 17 | 18 | End Method 19 | 20 | Method CheckTasks() 21 | While pool.count() = pool.Size() 22 | Delay 5 23 | Wend 24 | End Method 25 | 26 | Method WaitForTasks() 27 | While pool.Count() Or pool.Running() 28 | Delay 5 29 | Wend 30 | End Method 31 | 32 | Method DoSystem(cmd:String, src:String, obj:String, supp:String) 33 | CheckTasks() 34 | 35 | pool.AddTask(TProcessTask._DoTasks, CreateProcessTask(cmd, src, obj, supp)) 36 | 37 | End Method 38 | 39 | Method AddTask:Int(func:Object(data:Object), data:Object) 40 | CheckTasks() 41 | 42 | pool.AddTask(func, data) 43 | End Method 44 | 45 | End Type 46 | 47 | Rem 48 | bbdoc: A thread pool. 49 | End Rem 50 | Type TThreadPool 51 | 52 | Field _threads:TThread[] 53 | Field _queue:TThreadPoolTask[] 54 | 55 | Field _lock:TMutex 56 | Field _waitVar:TCondVar 57 | 58 | Field _count:Int 59 | Field _head:Int 60 | Field _tail:Int 61 | Field _running:Int 62 | 63 | Field _shutdown:Int 64 | 65 | Rem 66 | bbdoc: Creates a new thread pool of @threadCount threads and a queue size of @queueSize. 67 | End Rem 68 | Function Create:TThreadPool(threadCount:Int, queueSize:Int) 69 | Local pool:TThreadPool = New TThreadPool 70 | pool._threads = New TThread[threadCount] 71 | pool._queue = New TThreadPoolTask[queueSize] 72 | 73 | pool._lock = TMutex.Create() 74 | pool._waitVar = TCondVar.Create() 75 | 76 | For Local i:Int = 0 Until threadCount 77 | pool._threads[i] = TThread.Create(_ThreadPoolThread, pool) 78 | Next 79 | 80 | ' cache tasks 81 | For Local i:Int = 0 Until queueSize 82 | pool._queue[i] = New TThreadPoolTask 83 | Next 84 | 85 | Return pool 86 | End Function 87 | 88 | Rem 89 | bbdoc: Returns the number of tasks in the queue. 90 | End Rem 91 | Method Count:Int() 92 | Return _count 93 | End Method 94 | 95 | Rem 96 | bbdoc: Returns the size of the queue. 97 | End Rem 98 | Method Size:Int() 99 | Return _queue.length 100 | End Method 101 | 102 | Rem 103 | bbdoc: Returns the number of busy/running threads. 104 | End Rem 105 | Method Running:Int() 106 | Return _running 107 | End Method 108 | 109 | Rem 110 | bbdoc: Adds a task to the queue. 111 | End Rem 112 | Method AddTask:Int(func:Object(data:Object), data:Object) 113 | 114 | Local result:Int = True 115 | 116 | _lock.Lock() 117 | 118 | Local slot:Int = _tail + 1 119 | If slot = _queue.length Then 120 | slot = 0 121 | End If 122 | 123 | While True 124 | 125 | If _count = _queue.length Then 126 | result = False 127 | Exit 128 | End If 129 | 130 | If _shutdown Then 131 | result = False 132 | Exit 133 | End If 134 | 135 | _queue[_tail].func = func 136 | _queue[_tail].data = data 137 | _tail = slot 138 | _count :+ 1 139 | 140 | _waitVar.Broadcast() 141 | 142 | Exit 143 | Wend 144 | 145 | _lock.Unlock() 146 | 147 | Return result 148 | End Method 149 | 150 | Rem 151 | bbdoc: Shutdown the pool. 152 | about: If @immediately is False, the queue will be processed to the end. 153 | End Rem 154 | Method Shutdown(immediately:Int = False) 155 | _lock.Lock() 156 | 157 | While True 158 | 159 | If _shutdown Then 160 | Return 161 | End If 162 | 163 | If immediately Then 164 | _shutdown = 2 165 | Else 166 | _shutdown = 1 167 | End If 168 | 169 | _waitVar.Broadcast() 170 | _lock.Unlock() 171 | 172 | For Local i:Int = 0 Until _threads.length 173 | _threads[i].Wait() 174 | Next 175 | 176 | Exit 177 | Wend 178 | 179 | _lock.Lock() 180 | _lock.Close() 181 | _waitVar.Close() 182 | 183 | End Method 184 | 185 | Function _ThreadPoolThread:Object(data:Object) 186 | Local pool:TThreadPool = TThreadPool(data) 187 | 188 | While True 189 | 190 | pool._lock.Lock() 191 | 192 | While pool._count = 0 And Not pool._shutdown 193 | pool._waitVar.Wait(pool._lock) 194 | Delay 5 195 | Wend 196 | 197 | If pool._shutdown And pool._count = 0 Then 198 | ' time to finish 199 | Exit 200 | End If 201 | 202 | Local task:TThreadPoolTask = pool._queue[pool._head] 203 | 204 | Local func:Object(data:Object) = task.func 205 | Local data:Object = task.data 206 | 207 | pool._head :+ 1 208 | 209 | If pool._head = pool._queue.length Then 210 | pool._head = 0 211 | End If 212 | 213 | ' less queue 214 | pool._count :- 1 215 | ' more running threads 216 | pool._running :+ 1 217 | 218 | pool._lock.Unlock() 219 | 220 | ' perform a task 221 | func(data) 222 | 223 | pool._lock.Lock() 224 | pool._running :- 1 225 | pool._lock.Unlock() 226 | Wend 227 | 228 | pool._lock.Unlock() 229 | 230 | End Function 231 | 232 | Method Delete() 233 | Shutdown() 234 | End Method 235 | 236 | End Type 237 | 238 | Type TThreadPoolTask 239 | 240 | Field func:Object(data:Object) 241 | Field data:Object 242 | 243 | End Type 244 | 245 | -------------------------------------------------------------------------------- /resources/android/apache-ant/etc/checkstyle/checkstyle-xdoc.xsl: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | Checkstyle Audit 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 |
NameErrors
56 |
57 |
58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | files.html 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | Checkstyle Audit 79 | 80 | 81 | 82 |
83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 |
Error DescriptionLine
96 |
97 | 98 |
99 |
100 |
101 | 102 | 103 |
104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 |
FilesFiles With ErrorsErrors
120 |
121 |
122 | 123 | 124 | 125 | oddrow 126 | evenrow 127 | 128 | 129 |
130 | 131 | -------------------------------------------------------------------------------- /resources/android/apache-ant/etc/changelog.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | <xsl:value-of select="$title"/> 46 | 74 | 75 | 76 |

77 | 78 |

79 |

Designed for use with Apache Ant.

80 |
81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 |
89 | 90 | 91 | 92 |
93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 |
103 | 
104 |
    105 | 106 |
107 | 108 | 109 |
110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | mailto: 123 | 124 | 125 | 126 | 127 | 128 |
  • 129 | 130 | 131 | 132 | /?rev=&content-type=text/x-cvsweb-markup 133 | 134 | 135 | /?r1=&r2= 136 | 137 | 138 | () 139 |
  • 140 |
    141 | 142 | 144 | 145 | 146 | 147 | 148 |
    149 | -------------------------------------------------------------------------------- /bmk_ng_utils.bmx: -------------------------------------------------------------------------------- 1 | SuperStrict 2 | 3 | Import BRL.MaxUtil 4 | Import BRL.FileSystem 5 | ?Not linux 6 | Import BRL.System 7 | ? 8 | Import BRL.MaxLua 9 | Import BRL.TextStream 10 | 11 | ?linux 12 | Import "bmk_cores_linux.bmx" 13 | ?macos 14 | Import "bmk_cores_macos.bmx" 15 | ?win32 16 | Import "bmk_cores_win32.bmx" 17 | ?haiku 18 | Import "bmk_cores_haiku.bmx" 19 | ? 20 | 21 | Global utils:TMaxUtils = New TMaxUtils 22 | Global fsys:TSystem = New TSystem 23 | Global futils:TFileUtils = New TFileUtils 24 | 25 | ' Access to BRL.MaxUtil 26 | Type TMaxUtils 27 | 28 | Method New() 29 | LuaRegisterObject Self,"utils" 30 | End Method 31 | 32 | Method BlitzMaxPath:String() 33 | Return BRL.MaxUtil.BlitzMaxPath() 34 | End Method 35 | 36 | Method ModulePath:String( modid$ ) 37 | Return BRL.MaxUtil.ModulePath(modid) 38 | End Method 39 | 40 | Method ModuleIdent:String( modid$ ) 41 | Return BRL.MaxUtil.ModuleIdent(modid) 42 | End Method 43 | 44 | Method ModuleSource:String( modid$ ) 45 | Return BRL.MaxUtil.ModuleSource(modid) 46 | End Method 47 | 48 | Method ModuleArchive:String( modid$,mung$="" ) 49 | Return BRL.MaxUtil.ModuleArchive(modid, mung) 50 | End Method 51 | 52 | Method ModuleInterface:String( modid$,mung$="" ) 53 | Return BRL.MaxUtil.ModuleInterface(modid, mung) 54 | End Method 55 | 56 | End Type 57 | 58 | ' Access to BRL.FileSystem and BRL.System 59 | Type TSystem 60 | 61 | Method New() 62 | LuaRegisterObject Self,"sys" 63 | End Method 64 | 65 | Method FixPath:String(path:String, dirPath:Int = False) 66 | Local p:String = path 67 | BRL.FileSystem.FixPath(p, dirPath) 68 | Return p 69 | End Method 70 | 71 | Method StripDir$( path$ ) 72 | Return BRL.FileSystem.StripDir(path) 73 | End Method 74 | 75 | Method StripExt$( path$ ) 76 | Return BRL.FileSystem.StripExt(path) 77 | End Method 78 | 79 | Method StripAll$( path$ ) 80 | Return BRL.FileSystem.StripAll(path) 81 | End Method 82 | 83 | Method StripSlash$( path$ ) 84 | Return BRL.FileSystem.StripSlash(path) 85 | End Method 86 | 87 | Method ExtractDir$( path$ ) 88 | Return BRL.FileSystem.ExtractDir(path) 89 | End Method 90 | 91 | Method ExtractExt$( path$ ) 92 | Return BRL.FileSystem.ExtractExt(path) 93 | End Method 94 | 95 | Method CurrentDir$() 96 | Return BRL.FileSystem.CurrentDir() 97 | End Method 98 | 99 | Method RealPath$( path$ ) 100 | Return BRL.FileSystem.RealPath(path) 101 | End Method 102 | 103 | Method FileType:Int( path$ ) 104 | Return BRL.FileSystem.FileType(path) 105 | End Method 106 | 107 | Method CreateFile:Int( path$ ) 108 | Return BRL.FileSystem.CreateFile(path) 109 | End Method 110 | 111 | Method CreateDir:Int( path$,recurse:Int=False ) 112 | Return BRL.FileSystem.CreateDir(path, recurse) 113 | End Method 114 | 115 | Method DeleteFile:Int( path$ ) 116 | Return BRL.FileSystem.DeleteFile(path) 117 | End Method 118 | 119 | Method RenameFile:Int( oldpath$,newpath$ ) 120 | Return BRL.FileSystem.RenameFile(oldpath, newpath) 121 | End Method 122 | 123 | Method CopyFile:Int( src$,dst$ ) 124 | Return BRL.FileSystem.CopyFile(src, dst) 125 | End Method 126 | 127 | Method CopyDir:Int( src$,dst$ ) 128 | Return BRL.FileSystem.CopyDir(src, dst) 129 | End Method 130 | 131 | Method DeleteDir:Int( path$,recurse:Int=False ) 132 | Return BRL.FileSystem.DeleteDir(path, recurse) 133 | End Method 134 | 135 | Method ChangeDir:Int( path$ ) 136 | Return BRL.FileSystem.ChangeDir(path) 137 | End Method 138 | 139 | ?Not linux 140 | ' System 141 | Method CurrentDate:String() 142 | Return BRL.System.CurrentDate() 143 | End Method 144 | 145 | Method CurrentTime:String() 146 | Return BRL.System.CurrentTime() 147 | End Method 148 | 149 | Method Notify(text:String, serious:Int = False) 150 | BRL.System.Notify(text, serious) 151 | End Method 152 | 153 | Method OpenURL(url:String) 154 | BRL.System.OpenURL(url) 155 | End Method 156 | ?linux 157 | Method CurrentDate:String(_format$="%d %b %Y") 158 | Local time:Byte[256],buff:Byte[256] 159 | time_(time) 160 | strftime_(buff,256,_format,localtime_( time )) 161 | Return String.FromCString(buff) 162 | End Method 163 | 164 | Method CurrentTime:String() 165 | Local time:Byte[256],buff:Byte[256] 166 | time_(time) 167 | strftime_( buff,256,"%H:%M:%S",localtime_( time ) ); 168 | Return String.FromCString(buff) 169 | End Method 170 | 171 | Method Notify(text:String, serious:Int = False) 172 | WriteStdout text+"~r~n" 173 | End Method 174 | ? 175 | End Type 176 | 177 | ' Access to BRL.MaxUtil 178 | Type TFileUtils 179 | 180 | Method New() 181 | LuaRegisterObject Self,"futils" 182 | End Method 183 | 184 | Method SaveText:Int(filename:String, text:String) 185 | Try 186 | Return BRL.TextStream.SaveText(text, filename) 187 | Catch e:TStreamWriteException 188 | Return False 189 | End Try 190 | End Method 191 | 192 | End Type 193 | 194 | Private 195 | 196 | Global factories:TProcessTaskFactory 197 | 198 | Public 199 | 200 | Type TProcessTask 201 | 202 | Function _DoTasks:Object(data:Object) 203 | Return TProcessTask(data).DoTasks() 204 | End Function 205 | 206 | Method DoTasks:Object() abstract 207 | End Type 208 | 209 | Type TProcessTaskFactory 210 | 211 | Field _succ:TProcessTaskFactory 212 | 213 | Method New() 214 | _succ=factories 215 | factories=Self 216 | End Method 217 | 218 | Method Create:TProcessTask( cmd:String, src:String, obj:String, supp:String ) Abstract 219 | 220 | End Type 221 | 222 | Function CreateProcessTask:TProcessTask(cmd:String, src:String, obj:String, supp:String) 223 | Local factory:TProcessTaskFactory=factories 224 | Return factory.Create(cmd, src, obj, supp) 225 | End Function 226 | -------------------------------------------------------------------------------- /resources/android/apache-ant/lib/ant-parent.pom: -------------------------------------------------------------------------------- 1 | 2 | 18 | 23 | 25 | 4.0.0 26 | org.apache.ant 27 | ant-parent 28 | 1.9.4 29 | pom 30 | master POM 31 | 32 | 33 | The Apache Software License, Version 2.0 34 | http://www.apache.org/licenses/LICENSE-2.0.txt 35 | repo 36 | 37 | 38 | Apache Ant 39 | http://ant.apache.org/ 40 | 2000 41 | 42 | The Apache Software Foundation 43 | http://www.apache.org/ 44 | 45 | 46 | 47 | 48 | dummy 49 | Dummy to avoid accidental deploys 50 | http://nowhere.net/ 51 | 52 | 53 | 54 | scm:svn:http://svn.apache.org/repos/asf/ant/core/trunk 55 | scm:svn:https://svn.apache.org/repos/asf/ant/core/trunk 56 | http://svn.apache.org/repos/asf/ant/core/trunk 57 | 58 | 59 | hudson 60 | https://builds.apache.org/job/Ant_BuildFromPOMs/ 61 | 62 | 63 | 64 | Ant Developers List 65 | dev-subscribe@ant.apache.org 66 | dev-unsubscribe@ant.apache.org 67 | dev@ant.apache.org 68 | http://mail-archives.apache.org/mod_mbox/ant-dev 69 | 70 | 71 | Ant Users List 72 | user-subscribe@ant.apache.org 73 | user-unsubscribe@ant.apache.org 74 | user@ant.apache.org 75 | http://mail-archives.apache.org/mod_mbox/ant-user 76 | 77 | 78 | 79 | bugzilla 80 | http://issues.apache.org/bugzilla/ 81 | 82 | 83 | ant 84 | ant-antlr 85 | ant-apache-bcel 86 | ant-apache-bsf 87 | ant-apache-log4j 88 | ant-apache-oro 89 | ant-apache-regexp 90 | ant-apache-resolver 91 | ant-apache-xalan2 92 | ant-commons-logging 93 | ant-commons-net 94 | ant-jai 95 | ant-javamail 96 | ant-jdepend 97 | ant-jmf 98 | ant-jsch 99 | ant-junit 100 | ant-junit4 101 | ant-launcher 102 | ant-netrexx 103 | ant-swing 104 | ant-testutil 105 | 106 | 107 | 108 | junit 109 | junit 110 | 3.8.2 111 | test 112 | 113 | 114 | 115 | ../../../src/main 116 | ../../../src/testcases 117 | ../../../target/classes 118 | ../../../target/testcases 119 | 120 | 121 | 122 | org.apache.maven.plugins 123 | maven-compiler-plugin 124 | 2.3.2 125 | 126 | 1.5 127 | 1.5 128 | 129 | 130 | 131 | org.apache.maven.plugins 132 | maven-jar-plugin 133 | 2.4 134 | 135 | 136 | org.apache.maven.plugins 137 | maven-surefire-plugin 138 | 2.12 139 | 140 | 141 | org.apache.maven.plugins 142 | maven-surefire-report-plugin 143 | 2.12 144 | 145 | 146 | 147 | 148 | 149 | UTF-8 150 | 151 | 152 | -------------------------------------------------------------------------------- /resources/android/apache-ant/etc/tagdiff.xsl: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | <xsl:value-of select="$title"/> 42 | 61 | 62 | 63 |

    64 | 65 |

    66 | Tagdiff between and 67 | 68 |

    Designed for use with Ant.

    69 |
    70 | 71 | 72 | 73 | 78 | 79 |
    74 | New Files | 75 | Modified Files | 76 | Removed Files 77 |
    80 | 81 | 82 | New Files 83 | New 84 | 85 | 86 | 87 | 88 | Modified Files 89 | Modified 90 | 91 | 92 | 93 | 94 | 95 | Removed Files 96 | Removed 97 | 98 | 99 |
    100 | 101 | 102 | 103 |
    104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | - entries 114 | 115 | (back to top) 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 |
      124 | 125 |
    126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | mailto: 146 | 147 | 148 | 149 | 150 | 151 | 152 |
  • 153 | 154 | / 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | /?rev=&content-type=text/x-cvsweb-markup 163 | 164 | 165 | /?r1=&r2=&diff_format=h 166 | 167 | ( --> ) 168 | 169 | 170 |
  • 171 |
    172 | 173 | 175 | 176 | 177 | 178 | 179 |
    180 | -------------------------------------------------------------------------------- /resources/android/apache-ant/etc/log.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 | 22 | 30 | 31 | 32 | 33 | 34 | 35 | 106 | 107 | 108 | 109 | 110 | 111 | 116 | 119 | 120 |
    112 | 113 | http://jakarta.apache.org 114 | 115 | 117 | Apache Ant 118 |
    121 | 122 | 123 | 124 |

    125 | 126 | 127 | 128 | 129 | 130 |
    131 | 132 | 133 | 134 | 135 | 136 | failed 137 | complete 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 155 | 156 |
    Build FailedBuild CompleteTotal Time:
    150 | 151 |
    152 | See the stacktrace. 153 |
    154 |
    157 | 158 | 159 | 160 | 161 | 162 |
    ant.file
    ant.version
    java.version
    os.name
    163 | 164 |

    Build events

    165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 |
    targettaskmessage
    173 |

    174 | 175 | 176 | 177 |

    Error details

    178 | 179 | 182 |
    180 |
    181 |
    183 | 184 |

    185 |
    186 | 187 | 188 | 189 | 190 | 191 | 192 | a 193 | b 194 | 195 | 196 | [ ] 197 | 198 | 199 | 200 | 201 | 202 | 203 |
    204 | --------------------------------------------------------------------------------