16 Star 0 Fork 31

OH RISC-V SIG/third_party_bzip2

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
0001-add-compile-option.patch 1.37 KB
一键复制 编辑 原始数据 按行查看 历史
From 70218c0c89b399fdc6febea92aae5dcc6ad32f56 Mon Sep 17 00:00:00 2001
From: lvying <lvying6@huawei.com>
Date: Sat, 19 Oct 2019 13:07:28 +0800
Subject: [PATCH 1/2] add compile option
Signed-off-by: lvying <lvying6@huawei.com>
---
Makefile | 4 ----
Makefile-libbz2_so | 5 ++---
2 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/Makefile b/Makefile
index f8a1772..69ea7b2 100644
--- a/Makefile
+++ b/Makefile
@@ -18,10 +18,6 @@ SHELL=/bin/sh
CC=gcc
AR=ar
RANLIB=ranlib
-LDFLAGS=
-
-BIGFILES=-D_FILE_OFFSET_BITS=64
-CFLAGS=-Wall -Winline -O2 -g $(BIGFILES)
# Where you want it installed when you do 'make install'
PREFIX=/usr/local
diff --git a/Makefile-libbz2_so b/Makefile-libbz2_so
index fb0f230..1eaf26a 100644
--- a/Makefile-libbz2_so
+++ b/Makefile-libbz2_so
@@ -24,7 +24,6 @@
SHELL=/bin/sh
CC=gcc
BIGFILES=-D_FILE_OFFSET_BITS=64
-CFLAGS=-fpic -fPIC -Wall -Winline -O2 -g $(BIGFILES)
OBJS= blocksort.o \
huffman.o \
@@ -35,8 +34,8 @@ OBJS= blocksort.o \
bzlib.o
all: $(OBJS)
- $(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.8 $(OBJS)
- $(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.8
+ $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname -Wl,libbz2.so.1 -o libbz2.so.1.0.8 $(OBJS)
+ $(CC) $(CFLAGS) $(LDFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.8
rm -f libbz2.so.1.0
ln -s libbz2.so.1.0.8 libbz2.so.1.0
--
1.8.3.1
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/riscv-sig/third_party_bzip2.git
git@gitee.com:riscv-sig/third_party_bzip2.git
riscv-sig
third_party_bzip2
third_party_bzip2
master

搜索帮助