mirror of
https://github.com/danog/ir.git
synced 2024-12-02 09:38:29 +01:00
Test Unix x86 with asan/ubsan in CI (#49)
This commit is contained in:
parent
e97f195025
commit
9a8cbdf28c
6
.github/workflows/push.yml
vendored
6
.github/workflows/push.yml
vendored
@ -14,6 +14,8 @@ jobs:
|
||||
runs-on: ubuntu-22.04
|
||||
container:
|
||||
image: ubuntu:22.04
|
||||
env:
|
||||
CFLAGS: '-fsanitize=address,undefined'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: apt
|
||||
@ -33,6 +35,8 @@ jobs:
|
||||
runs-on: ubuntu-22.04
|
||||
container:
|
||||
image: ubuntu:22.04
|
||||
env:
|
||||
CFLAGS: '-fsanitize=address,undefined'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: apt
|
||||
@ -86,6 +90,8 @@ jobs:
|
||||
|
||||
MACOS_x86_64:
|
||||
runs-on: macos-11
|
||||
env:
|
||||
CFLAGS: '-fsanitize=address,undefined'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: brew
|
||||
|
12
Makefile
12
Makefile
@ -10,32 +10,32 @@ EXAMPLES_BUILD_DIR = $(BUILD_DIR)/examples
|
||||
CC = gcc
|
||||
CXX = g++
|
||||
BUILD_CC = gcc
|
||||
CFLAGS = -Wall -Wextra -Wno-unused-parameter
|
||||
override CFLAGS += -Wall -Wextra -Wno-unused-parameter
|
||||
LDFLAGS = -lm -ldl
|
||||
PHP = php
|
||||
LLK = llk
|
||||
#LLK = $(PHP) $(HOME)/php/llk/llk.php
|
||||
|
||||
ifeq (debug, $(BUILD))
|
||||
CFLAGS += -O0 -g -DIR_DEBUG=1
|
||||
override CFLAGS += -O0 -g -DIR_DEBUG=1
|
||||
endif
|
||||
ifeq (release, $(BUILD))
|
||||
CFLAGS += -O2 -g
|
||||
override CFLAGS += -O2 -g
|
||||
endif
|
||||
|
||||
ifeq (x86_64, $(TARGET))
|
||||
CFLAGS += -DIR_TARGET_X64
|
||||
override CFLAGS += -DIR_TARGET_X64
|
||||
DASM_ARCH = x86
|
||||
DASM_FLAGS = -M -D X64=1
|
||||
endif
|
||||
ifeq (x86, $(TARGET))
|
||||
CFLAGS += -m32 -DIR_TARGET_X86
|
||||
override CFLAGS += -m32 -DIR_TARGET_X86
|
||||
DASM_ARCH = x86
|
||||
DASM_FLAGS = -M
|
||||
endif
|
||||
ifeq (aarch64, $(TARGET))
|
||||
CC= aarch64-linux-gnu-gcc --sysroot=$(HOME)/php/ARM64
|
||||
CFLAGS += -DIR_TARGET_AARCH64
|
||||
override CFLAGS += -DIR_TARGET_AARCH64
|
||||
DASM_ARCH = aarch64
|
||||
DASM_FLAGS = -M
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user