This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import UIKit | |
| public struct Pixel { | |
| public var value: UInt32 | |
| public var red: UInt8 { | |
| get { | |
| return UInt8(value & 0xFF) | |
| } | |
| set { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| How to build HDF5 for Android | |
| References: | |
| ----------- | |
| [1] http://developer.android.com/tools/sdk/ndk/index.html | |
| [2] http://developer.android.com/sdk/index.html |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| STANDLONE_PREFIX=/Users/palmerc/Development/android-ndk/standalone-r13b | |
| HDF5_PARENT_DIR=${HOME}/Development/HDF5-compile | |
| HDF5_INSTALL_DIR=${HDF5_PARENT_DIR}/HDF5 | |
| EMULATOR_NAME_ARM="nexus19-arm" | |
| EMULATOR_NAME_X86="nexus19-x86" | |
| function find_device { | |
| local UUID=$1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| contains() { | |
| local match="$1" | |
| shift | |
| local list=( "${@}" ) | |
| for item in "${list[@]}"; do | |
| if [[ "${item}" == "${match}" ]]; then | |
| echo true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| include( ExternalProject ) | |
| set( NCPU 8 ) | |
| set( MIN_IOS_VERSION 8.0 ) | |
| set( BOOST_VERSION 1.63.0 ) | |
| set( BOOST_SHA_CHECKSUM 9f1dd4fa364a3e3156a77dc17aa562ef06404ff6 ) | |
| set( BOOST_COMPILE_LIBRARIES filesystem system date_time ) | |
| set( COMPILE_ARCHITECTURES armv6 armv7 armv7s arm64 ) | |
| set( ENABLE_BITCODE true ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| ARCHS=( "arm" ) | |
| OPENSSL_OPTIONS=( "no-deprecated" "no-dtls1" "no-experimental" "no-hw" "no-ssl2" "no-ssl3" "no-camellia" "no-cast" "no-comp" "no-dso" "no-engine" "no-idea" "no-jpake" "no-krb5" "no-md2" "no-md4" "no-mdc2" "no-rc2" "no-rc5" "no-ripemd" "no-seed" "no-srp" "no-store" "no-whirlpool" ) | |
| MIN_IOS_VERSION=8.0 | |
| for ARCH in "${ARCHS[@]}"; do | |
| SDK="" | |
| CONFIGURE_SWITCH="" | |
| if [ "${ARCH}" == "arm" ]; then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //: A UIKit based Playground for presenting user interface | |
| import UIKit | |
| import PlaygroundSupport | |
| class MyViewController : UIViewController { | |
| var innerViewLeadingConstraint: NSLayoutConstraint? | |
| var innerViewCenterXConstraint: NSLayoutConstraint? | |
| var innerView: UIView? | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| This app collects no data whatsoever. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd";> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>Label</key> | |
| <string>com.cameronpalmer.wireguard</string> | |
| <key>ProgramArguments</key> | |
| <array> | |
| <string>/usr/local/bin/wg-quick</string> | |
| <string>up</string> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| set -e | |
| declare -x USERNAME="$1" | |
| declare -x USERPIC="$2" | |
| declare -r DSIMPORT_CMD="/usr/bin/dsimport" | |
| declare -r ID_CMD="/usr/bin/id" |