clfs-1.2
clfs-2.1
clfs-3.0.0-systemd
clfs-3.0.0-sysvinit
systemd
sysvinit
Last change
on this file since 10e90e4 was 7ed0e05, checked in by Jim Gifford <clfs@…>, 19 years ago |
r619@server (orig r617): ryan | 2005-08-07 00:07:42 -0700
Add new packages for blfs builds
|
-
Property mode
set to
100755
|
File size:
1.5 KB
|
Line | |
---|
1 | #!/bin/bash
|
---|
2 |
|
---|
3 | ### gsm ###
|
---|
4 |
|
---|
5 | cd ${SRC}
|
---|
6 | LOG=gsm-blfs.log
|
---|
7 |
|
---|
8 | SELF=`basename ${0}`
|
---|
9 | set_buildenv
|
---|
10 | set_libdirname
|
---|
11 | setup_multiarch
|
---|
12 |
|
---|
13 | unpack_tarball gsm-${GSM_VER}
|
---|
14 | cd ${PKGDIR}
|
---|
15 |
|
---|
16 | # Add support for building shared lib
|
---|
17 | sed -i -e '/^LIBGSM.*/a\
|
---|
18 | SHLIBGSM = libgsm.so.0' \
|
---|
19 | -e 's@^all:.*\$(LIBGSM)@& $(LIB)/$(SHLIBGSM)@' \
|
---|
20 | -e '/^GSM_INSTALL_TARGETS.*/a\
|
---|
21 | $(GSM_INSTALL_LIB)/$(SHLIBGSM) \\' \
|
---|
22 | -e 's@\$(LD) $(LFLAGS)@& -L$(LIB)@' \
|
---|
23 | -e '/\$(LD)/s@\(\$(TOAST_OBJECTS)\) \$(LIBGSM)@\1 -lgsm@g' \
|
---|
24 | Makefile
|
---|
25 |
|
---|
26 | cat >> Makefile <<"EOF"
|
---|
27 |
|
---|
28 | $(LIB)/$(SHLIBGSM): $(LIB) $(GSM_OBJECTS)
|
---|
29 | -rm $(RMFLAGS) $(LIB)/$(SHLIBGSM)
|
---|
30 | $(LD) $(LFLAGS) -shared -Wl,-soname=$(SHLIBGSM) \
|
---|
31 | $(GSM_OBJECTS) -o $(LIB)/$(SHLIBGSM)
|
---|
32 | $(LN) -sf $(SHLIBGSM) $(LIB)/libgsm.so
|
---|
33 |
|
---|
34 | $(GSM_INSTALL_LIB)/$(SHLIBGSM): $(LIB)/$(SHLIBGSM)
|
---|
35 | -rm $@
|
---|
36 | cp $? $@
|
---|
37 | chmod 755 $@
|
---|
38 | $(LN) -sf $(SHLIBGSM) $(GSM_INSTALL_LIB)/libgsm.so
|
---|
39 | EOF
|
---|
40 |
|
---|
41 | max_log_init gsm ${GSM_VER} "blfs (shared)" ${BUILDLOGS} ${LOG}
|
---|
42 | (
|
---|
43 | make CC="${CC-gcc} ${ARCH_CFLAGS} -ansi -pedantic" \
|
---|
44 | CCFLAGS="-c -O2 -pipe ${TGT_CFLAGS} -fPIC -DNeedFunctionPrototypes=1" \
|
---|
45 | addtst &&
|
---|
46 | make CC="${CC-gcc} ${ARCH_CFLAGS} -ansi -pedantic" \
|
---|
47 | CCFLAGS="-c -O2 -pipe ${TGT_CFLAGS} -fPIC -DNeedFunctionPrototypes=1" \
|
---|
48 | ) >> ${LOGFILE} 2>&1 &&
|
---|
49 | echo " o Build OK" &&
|
---|
50 |
|
---|
51 | min_log_init ${INSTLOGS} &&
|
---|
52 | make INSTALL_ROOT=/usr \
|
---|
53 | GSM_INSTALL_LIB=/usr/${libdirname} \
|
---|
54 | GSM_INSTALL_INC=/usr/include \
|
---|
55 | GSM_INSTALL_MAN=/usr/share/man \
|
---|
56 | install \
|
---|
57 | >> ${LOGFILE} 2>&1 &&
|
---|
58 | echo " o ALL OK" || barf
|
---|
59 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.