Browse Source

Fix various build failures

master
Kieran Kunhya 4 years ago
parent
commit
811a75ee84
3 changed files with 7 additions and 3 deletions
  1. +1
    -1
      Makefile
  2. +1
    -1
      examples/Makefile
  3. +5
    -1
      ietf/rtp2435.h

+ 1
- 1
Makefile View File

@ -70,7 +70,7 @@ HEADER_LIST = $$(find * -name '*.h')
FLAGS = -I. -Werror -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare -Wformat=2 FLAGS = -I. -Werror -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare -Wformat=2
compiler_c = $(CC) $(FLAGS) $(CFLAGS)
compiler_c = $(CC) $(FLAGS) $(CFLAGS) -std=gnu99
compiler_c++ = $(CXX) $(FLAGS) $(CXXFLAGS) compiler_c++ = $(CXX) $(FLAGS) $(CXXFLAGS)
compile = $(compiler_$1) -include "$$header" -c -x $1 /dev/null -o /dev/null compile = $(compiler_$1) -include "$$header" -c -x $1 /dev/null -o /dev/null

+ 1
- 1
examples/Makefile View File

@ -1,7 +1,7 @@
PREFIX ?= /usr/local PREFIX ?= /usr/local
WARN = -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare WARN = -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare
CPPFLAGS = -I. -I.. -I../.. CPPFLAGS = -I. -I.. -I../..
CFLAGS := $(WARN) -O2 -g $(CFLAGS)
CFLAGS := $(WARN) -O2 -g -std=gnu99 $(CFLAGS)
OBJ = dvb_print_si dvb_gen_si dvb_ecmg dvb_ecmg_test mpeg_print_pcr rtp_check_seqnum mpeg_restamp OBJ = dvb_print_si dvb_gen_si dvb_ecmg dvb_ecmg_test mpeg_print_pcr rtp_check_seqnum mpeg_restamp
ifeq "$(shell uname -s)" "Linux" ifeq "$(shell uname -s)" "Linux"

+ 5
- 1
ietf/rtp2435.h View File

@ -31,6 +31,10 @@
#ifndef __BITSTREAM_IETF_RTP2435_H__ #ifndef __BITSTREAM_IETF_RTP2435_H__
#define __BITSTREAM_IETF_RTP2435_H__ #define __BITSTREAM_IETF_RTP2435_H__
#include <stdio.h>
#include <stdint.h>
#include <stdbool.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" extern "C"
{ {
@ -125,7 +129,7 @@ static inline uint8_t *rtp2435_restart(uint8_t *header)
static inline uint8_t *rtp2435_quantization_table(uint8_t *header) static inline uint8_t *rtp2435_quantization_table(uint8_t *header)
{ {
uint8_t q = rtp2435_get_q(header); uint8_t q = rtp2435_get_q(header);
if (128 <= q && q <= 255) {
if (128 <= q) {
uint8_t *p; uint8_t *p;
if ((p = rtp2435_restart(header))) if ((p = rtp2435_restart(header)))
return p + RTP_2435_RESTART_HEADER_SIZE; return p + RTP_2435_RESTART_HEADER_SIZE;

Loading…
Cancel
Save