Skip to content

Instantly share code, notes, and snippets.

Avatar
🌴
I am out of office

Axel Huebl ax3l

🌴
I am out of office
View GitHub Profile
@ax3l
ax3l / bashrc
Last active Jun 30, 2020
multiple_pkg_managers
View bashrc
# snippet for file: $HOME/.bashrc
#
# License: CC0
#
# register a bash function that calls the script above
activate-env () {
. $HOME/bin/impl-activate-env $@
}
@ax3l
ax3l / CMakeLists.txt
Created Dec 13, 2019
openPMD-api usage example: CMake
View CMakeLists.txt
cmake_minimum_required(VERSION 3.11)
project(openPMD_test)
add_executable(mytest main.cpp)
target_compile_features(mytest PRIVATE cxx_std_11)
find_package(openPMD REQUIRED CONFIG)
target_link_libraries(mytest PRIVATE openPMD::openPMD)
@ax3l
ax3l / cuda.h
Created Apr 26, 2018 — forked from eliben/cuda.h
Minimal CUDA support header for parsing with Clang
View cuda.h
/* Minimal declarations for CUDA support. Testing purposes only. */
#define __constant__ __attribute__((constant))
#define __device__ __attribute__((device))
#define __global__ extern "C" __attribute__((global))
#define __host__ __attribute__((host))
#define __shared__ __attribute__((shared))
#define __launch_bounds__(...) __attribute__((launch_bounds(__VA_ARGS__)))
#define __forceinline__ __attribute__((always_inline))
@ax3l
ax3l / awesome_standalone.md
Last active Feb 4, 2019
Awesome, Stand-Alone C++11 Projects
View awesome_standalone.md

Awesome, Stand-Alone C++11 Projects

Projects with wide adoption, broad compiler support, proper testing and great documentation.

Most of them are header-only (which is not necessarily a good thing for all tasks!), some of them even provide an amalgated (single-file) header.

CLI

(replace Boost.ProgramOptions)

@ax3l
ax3l / xeus_cling_openmp.ipynb
Last active May 15, 2018
Xeus-Cling with OpenMP
View xeus_cling_openmp.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ax3l
ax3l / symbols_cpp.md
Last active May 28, 2020
Symbol Visibility 101 by Boris Staletic @bstaletic
View symbols_cpp.md

Visible Symbols in C++ Projects

Intro

This is a spontaneous and verbatime log of a conversion with Boris Staletic @bstaletic from March, 24th 2018 on the pybind11 gitter. Thank you so much, Boris!

To confuse future readers, we decided to write down the discussion and I added typos and unnecessarily long sentences.

The issue came up with linking a CMake (library) target into a pybind11 module (in openPMD-api).

@ax3l
ax3l / PIConGPU_040-dev_Octopus.sh
Last active Mar 5, 2018
Octopus (Osaka U): PIConGPU 0.4.0-dev Quick-Start
View PIConGPU_040-dev_Octopus.sh
#!/usr/bin/env bash
#
# Author: Axel Huebl
#
# last updated: 2018-03-05
#
# execute:
# curl https://gist.githubusercontent.com/ax3l/080675215fdaf0c8bf0ad054ee8f7bc0/raw/PIConGPU_040-dev_Octopus.sh | bash
PIC_BRANCH="dev"
@ax3l
ax3l / PIConGPU_040-dev_osx.sh
Last active Mar 5, 2018
PIConGPU OSX Quick Start
View PIConGPU_040-dev_osx.sh
#!/usr/bin/env bash
#
# Author: Axel Huebl
#
# last updated: 2018-03-05
#
# execute:
# curl https://gist.githubusercontent.com/ax3l/9e77c1b688136ea37b05ff00ea0e420f/raw/PIConGPU_040-dev_osx.sh | bash
PIC_BRANCH="dev"
@ax3l
ax3l / CXXdefaults.md
Last active Jul 17, 2020
Compiler C++ Version Defaults
View CXXdefaults.md

C++ -std=... default of various commonly used C++ compilers

Compiler Version __cplusplus
g++ 4.7.4 199711L
4.8.4 199711L
4.9.2 199711L
5.5.0 199711L
6.1.0 201402L
7.4.0 201402L
@ax3l
ax3l / PIConGPU_040-dev_PizDaint.sh
Last active May 13, 2019
Piz Daint: PIConGPU 0.4.0-dev Quick-Start
View PIConGPU_040-dev_PizDaint.sh
#!/usr/bin/env bash
#
# Authors: Axel Huebl, Marco Garten, Klaus Steiniger
#
# last updated: 2019-05-13
#
# execute:
# wget -O - https://gist.githubusercontent.com/ax3l/68cb4caa597df3def9b01640959ea56b/raw/PIConGPU_040-dev_PizDaint.sh | bash
PIC_BRANCH="dev"
You can’t perform that action at this time.