stable #3
12
Dockerfile
12
Dockerfile
@ -64,18 +64,18 @@ RUN echo docker_cross_compiler > /etc/hostname
|
||||
|
||||
# Setup interactive shell.
|
||||
# Setup sudo. Remove password prompt for group "wheel".
|
||||
RUN echo "%wheel ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/quik_sudo_conf
|
||||
RUN echo "%wheel ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/refuel_sudo_conf
|
||||
|
||||
# Create a default user and switch.
|
||||
RUN adduser --comment "" --disabled-password quik
|
||||
RUN adduser --comment "" --disabled-password refuel
|
||||
RUN addgroup wheel
|
||||
RUN usermod -aG wheel quik
|
||||
USER quik
|
||||
WORKDIR /home/quik
|
||||
RUN usermod -aG wheel refuel
|
||||
USER refuel
|
||||
WORKDIR /home/refuel
|
||||
|
||||
# Copy bashrc
|
||||
RUN cp /etc/bash.bashrc ~/.bashrc
|
||||
COPY sh/bashrc.sh /home/quik/.bashrc
|
||||
COPY sh/bashrc.sh /home/refuel/.bashrc
|
||||
|
||||
# Execute an interactive shell.
|
||||
CMD bash
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for Linux-arm systems.
|
||||
# ReFuel Toolchain file for Linux-arm systems.
|
||||
# Copyright (C) 2023
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for Linux-arm64 (aarch64) systems.
|
||||
# ReFuel Toolchain file for Linux-arm64 (aarch64) systems.
|
||||
# Copyright (C) 2023
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for Linux-x64 (amd64) systems.
|
||||
# ReFuel Toolchain file for Linux-x64 (amd64) systems.
|
||||
# Copyright (C) 2023
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for Linux-x86 (i386) systems.
|
||||
# ReFuel Toolchain file for Linux-x86 (i386) systems.
|
||||
# Copyright (C) 2023
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for OSX-ARM64 systems.
|
||||
# ReFuel Toolchain file for OSX-ARM64 systems.
|
||||
# Copyright (C) 2024
|
||||
|
||||
set(CMAKE_SYSTEM_NAME OSX)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for OSX-ARM64 systems.
|
||||
# ReFuel Toolchain file for OSX-ARM64 systems.
|
||||
# Copyright (C) 2024
|
||||
|
||||
set(CMAKE_SYSTEM_NAME OSX)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for Windows-x64 systems.
|
||||
# ReFuel Toolchain file for Windows-x64 systems.
|
||||
# Copyright (C) 2023
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Windows)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# QUIK Toolchain file for Windows-x86 systems.
|
||||
# ReFuel Toolchain file for Windows-x86 systems.
|
||||
# Copyright (C) 2023
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Windows)
|
||||
|
@ -1,52 +0,0 @@
|
||||
#ifndef _QUIK_COMMON_H_
|
||||
#define _QUIK_COMMON_H_
|
||||
|
||||
#include "stdlib.h"
|
||||
|
||||
#if __GNUC__ || _MSC_VER
|
||||
#define __QUIK_FUNCTION__ __FUNCTION__
|
||||
#else
|
||||
#define __QUIK_FUNCTION__ NULL
|
||||
#endif
|
||||
|
||||
#if WIN32 || _MSC_VER > 0 || __MINGW__
|
||||
#define QEXTERN __declspec(dllexport)
|
||||
#else
|
||||
#define QEXTERN
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Callback for failed assert function for QUIK redist libraries.
|
||||
* @param[in] expr The expression that failed.
|
||||
* @param[in] file The failing file (if available)
|
||||
* @param[in] line The failing line number (if available)
|
||||
* @param[in] func The failing function (if available)
|
||||
*/
|
||||
typedef void (*quik_failed_assert_cb_t)(const char *expr, const char *file, int line, const char* func);
|
||||
|
||||
#define DECLARE_ASSERT_CB(NAME) \
|
||||
QEXTERN quik_failed_assert_cb_t NAME##_failed_assert
|
||||
#define DECLARE_ASSERT_STORE(NAME) \
|
||||
QEXTERN void NAME##_failed_assert_store(quik_failed_assert_cb_t cb)
|
||||
|
||||
#define DEFINE_ASSERT_CB(NAME) \
|
||||
quik_failed_assert_cb_t NAME##_failed_assert
|
||||
#define DEFINE_ASSERT_STORE(NAME) \
|
||||
void NAME##_failed_assert_store(quik_failed_assert_cb_t cb) { \
|
||||
NAME##_failed_assert = cb != NULL ? cb : quik_default_assert; \
|
||||
}
|
||||
|
||||
#define QUIK_DECLARE_LIB(NAME) \
|
||||
DECLARE_ASSERT_CB(NAME); \
|
||||
DECLARE_ASSERT_STORE(NAME);
|
||||
|
||||
#define QUIK_DEFINE_LIB(NAME) \
|
||||
DEFINE_ASSERT_CB(NAME); \
|
||||
DEFINE_ASSERT_STORE(NAME);
|
||||
|
||||
inline static void quik_default_assert(const char *expr, const char *file, int line, const char *function)
|
||||
{
|
||||
abort();
|
||||
}
|
||||
|
||||
#endif
|
54
include/rf_common.h
Normal file
54
include/rf_common.h
Normal file
@ -0,0 +1,54 @@
|
||||
#ifndef _REFUEL_COMMON_H_
|
||||
#define _REFUEL_COMMON_H_
|
||||
|
||||
#include "stdlib.h"
|
||||
#include "stdio.h"
|
||||
|
||||
#if __GNUC__ || _MSC_VER
|
||||
#define __REFUEL_FUNCTION__ __FUNCTION__
|
||||
#else
|
||||
#define __REFUEL_FUNCTION__ NULL
|
||||
#endif
|
||||
|
||||
#if WIN32 || _MSC_VER > 0 || __MINGW__
|
||||
#define RFEXTERN __declspec(dllexport)
|
||||
#else
|
||||
#define RFEXTERN
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Callback for failed assert function for QUIK redist libraries.
|
||||
* @param[in] expr The expression that failed.
|
||||
* @param[in] file The failing file (if available)
|
||||
* @param[in] line The failing line number (if available)
|
||||
* @param[in] func The failing function (if available)
|
||||
*/
|
||||
typedef void (*rf_failed_assert_cb_t)(const char *expr, const char *file, int line, const char* func);
|
||||
|
||||
#define DECLARE_ASSERT_CB(NAME) \
|
||||
RFEXTERN rf_failed_assert_cb_t NAME##_failed_assert
|
||||
#define DECLARE_ASSERT_STORE(NAME) \
|
||||
RFEXTERN void NAME##_failed_assert_store(rf_failed_assert_cb_t cb)
|
||||
|
||||
#define DEFINE_ASSERT_CB(NAME) \
|
||||
rf_failed_assert_cb_t NAME##_failed_assert
|
||||
#define DEFINE_ASSERT_STORE(NAME) \
|
||||
void NAME##_failed_assert_store(rf_failed_assert_cb_t cb) { \
|
||||
NAME##_failed_assert = cb != NULL ? cb : rf_default_assert; \
|
||||
}
|
||||
|
||||
#define REFUEL_DECLARE_LIB(NAME) \
|
||||
DECLARE_ASSERT_CB(NAME); \
|
||||
DECLARE_ASSERT_STORE(NAME);
|
||||
|
||||
#define REFUEL_DEFINE_LIB(NAME) \
|
||||
DEFINE_ASSERT_CB(NAME); \
|
||||
DEFINE_ASSERT_STORE(NAME);
|
||||
|
||||
inline static void rf_default_assert(const char *expr, const char *file, int line, const char *function)
|
||||
{
|
||||
fprintf(stderr, "Assert failed at %s:%d in %s()\n %s", file, line, function, expr);
|
||||
abort();
|
||||
}
|
||||
|
||||
#endif
|
@ -1,5 +1,5 @@
|
||||
source $HOME/src/sh/init.sh
|
||||
echo QUIK Project Copyright \(C\) 2023
|
||||
echo ReFuel Project - Copyright \(C\) 2023
|
||||
echo
|
||||
echo This is an interactive shell for QUIK build image.
|
||||
echo This is an interactive shell for ReFuel build image.
|
||||
echo SuperUser \(su/sudo\) commands are enabled without a password. Beware.
|
||||
|
@ -26,7 +26,7 @@ fi
|
||||
|
||||
if [ -z "$CMAKE_DIR"]
|
||||
then
|
||||
CMAKE_DIR="$SRC/Quik.Common/cmake"
|
||||
CMAKE_DIR="$SRC/docker-cross-compiler/cmake"
|
||||
fi
|
||||
|
||||
for ARCH in $ARCHS; do
|
@ -4,15 +4,27 @@ then
|
||||
$1 = $(dirname "$0")
|
||||
fi
|
||||
|
||||
if [ -z "$QUIK_API_KEY" ]
|
||||
if [ -z "$NUGET_API_KEY" ]
|
||||
then
|
||||
echo "Please define QUIK_API_KEY"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "$NUGET_USER_NAME" ]
|
||||
then
|
||||
echo "Please define NUGET_USER_NAME"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "$NUGET_INDEX" ]
|
||||
then
|
||||
echo "Please define NUGET_INDEX"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd $1
|
||||
dotnet nuget add source \
|
||||
-n QUIK -u themixedupstuff -p "$QUIK_API_KEY" \
|
||||
-n ReFuel -u "$NUGET_USER_NAME" -p "$NUGET_API_KEY" \
|
||||
--store-password-in-clear-text \
|
||||
https://git.mixedup.dev/api/packages/QUIK/nuget/index.json
|
||||
dotnet nuget push -s QUIK bin/*/*.nupkg
|
||||
"$NUGET_INDEX"
|
||||
dotnet nuget push -s ReFuel bin/*/*.nupkg
|
||||
|
Loading…
Reference in New Issue
Block a user