source: src/router/rules/glib.mk @ 31119

Last change on this file since 31119 was 31119, checked in by brainslayer, 4 months ago

clean up unused files

File size: 6.4 KB
Line 
1ifeq ($(ARCH),i386)
2        export SUBARCH:=pc
3else
4ifeq ($(ARCH),x86_64)
5        export SUBARCH:=pc
6else
7        export SUBARCH:=unknown
8endif
9endif
10
11
12glib20-configure: libffi zlib util-linux
13        make -C util-linux
14        make -C util-linux install DESTDIR=$(INSTALLDIR)/util-linux
15        mkdir -p $(INSTALLDIR)/util-linux/usr/lib
16        -cp -urv $(INSTALLDIR)/util-linux/usr/tmp/* $(INSTALLDIR)/util-linux/usr/lib
17        rm -rf $(INSTALLDIR)/util-linux/usr/tmp
18        rm -rf $(INSTALLDIR)/util-linux/usr/sbin
19        rm -rf $(INSTALLDIR)/util-linux/usr/bin
20        rm -rf $(INSTALLDIR)/util-linux/bin
21        rm -rf $(INSTALLDIR)/util-linux/sbin
22        rm -f $(INSTALLDIR)/util-linux/usr/lib/libuuid.a
23        rm -f $(INSTALLDIR)/util-linux/usr/lib/libuuid.la
24        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.a
25        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.la
26        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.so*
27        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.la
28
29        cd glib20/libiconv && ./configure --enable-shared --enable-static --host=$(ARCH)-linux CC="ccache $(CC)" CFLAGS="$(COPTS) -std=gnu89 $(MIPS16_OPT)  -D_GNU_SOURCE -fPIC -Drpl_malloc=malloc"
30        cd glib20/libiconv && touch *
31        $(MAKE) -C glib20/libiconv clean all
32
33        cd glib20/gettext && ./configure --disable-libmount --enable-shared --disable-static --disable-openmp --host=$(ARCH)-linux CC="ccache $(CC)" LDFLAGS="$(COPTS) -std=gnu89 $(MIPS16_OPT) -D_GNU_SOURCE -fPIC -Drpl_malloc=malloc " CFLAGS="$(COPTS)  $(MIPS16_OPT)  -D_GNU_SOURCE -fPIC -Drpl_malloc=malloc -I$(TOP)/glib20/libiconv/include" CXXFLAGS="$(COPTS)  $(MIPS16_OPT) -D_GNU_SOURCE -fPIC -Drpl_malloc=malloc -I$(TOP)/glib20/libiconv/include"
34        cd glib20/gettext && touch *
35        $(MAKE) -C glib20/gettext clean all
36
37        -cd glib20/libglib && ./autogen.sh
38        cd glib20/libglib && ./configure --enable-shared --disable-static --disable-fam --with-pcre=internal --enable-debug=no --disable-selinux --disable-man --host=$(ARCH)-linux CC="ccache $(CC)" CFLAGS="$(COPTS) -std=gnu89  -DNVALGRIND=1 $(MIPS16_OPT) -D_GNU_SOURCE=1  -I$(TOP)/zlib -fPIC -Drpl_malloc=malloc -I$(TOP)/glib20/gettext/gettext-runtime/intl  -I$(TOP)/glib20/libiconv/include -I$(TOP)/libffi/$(ARCH)-$(SUBARCH)-linux-gnu/include  -L$(TOP)/libffi/$(ARCH)-$(SUBARCH)-linux-gnu/.libs -lffi -L$(TOP)/glib20/libiconv/lib/.libs -L$(TOP)/glib20/gettext/gettext-runtime/intl/.libs -L$(TOP)/glib20/libglib/gmodule/.libs   -L$(TOP)/zlib -L$(TOP)/$(ARCH)-uclibc/install/util-linux/usr/lib -pthread -lpthread -liconv -lz -lblkid -luuid -lmount" --with-libiconv=gnu --disable-modular-tests \
39        LIBFFI_CFLAGS="-I$(TOP)/libffi/$(ARCH)-$(SUBARCH)-linux-gnu/include" \
40        LIBFFI_LIBS="-L$(TOP)/libffi/$(ARCH)-$(SUBARCH)-linux-gnu/.libs -lffi" \
41        ZLIB_CFLAGS="-I$(TOP)/zlib" \
42        ZLIB_LIBS="-L$(TOP)/zlib -lz" \
43        LIBMOUNT_CFLAGS="-I$(TOP)/$(ARCH)-uclibc/install/util-linux/usr/include" \
44        LIBMOUNT_LIBS="-L$(TOP)/$(ARCH)-uclibc/install/util-linux/usr/lib -lmount" \
45        glib_cv_stack_grows=no glib_cv_uscore=no ac_cv_func_mmap_fixed_mapped=yes ac_cv_func_posix_getpwuid_r=yes ac_cv_func_posix_getgrgid_r=yes
46        touch glib20/libiconv/*
47        touch glib20/gettext/*
48        touch glib20/libglib/*
49
50        $(MAKE) -C glib20/libglib clean all
51
52glib20: libffi zlib util-linux util-linux-install
53        make -C util-linux install DESTDIR=$(INSTALLDIR)/util-linux
54        mkdir -p $(INSTALLDIR)/util-linux/usr/lib
55        -cp -urv $(INSTALLDIR)/util-linux/usr/tmp/* $(INSTALLDIR)/util-linux/usr/lib
56        rm -rf $(INSTALLDIR)/util-linux/usr/tmp
57        rm -rf $(INSTALLDIR)/util-linux/usr/sbin
58        rm -rf $(INSTALLDIR)/util-linux/usr/bin
59        rm -rf $(INSTALLDIR)/util-linux/bin
60        rm -rf $(INSTALLDIR)/util-linux/sbin
61        rm -f $(INSTALLDIR)/util-linux/usr/lib/libuuid.a
62        rm -f $(INSTALLDIR)/util-linux/usr/lib/libuuid.la
63        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.a
64        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.la
65        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.so*
66        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.la
67        $(MAKE) -C glib20/libiconv all
68        $(MAKE) -C glib20/gettext all
69        $(MAKE) -C glib20/libglib all
70        rm -rf $(INSTALLDIR)/util-linux/usr/sbin
71        rm -rf $(INSTALLDIR)/util-linux/usr/bin
72        rm -rf $(INSTALLDIR)/util-linux/bin
73        rm -rf $(INSTALLDIR)/util-linux/sbin
74        rm -rf $(INSTALLDIR)/util-linux/usr/share
75        rm -rf $(INSTALLDIR)/util-linux/usr/include
76        rm -rf $(INSTALLDIR)/util-linux/usr/lib/pkgconfig
77        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.a
78        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.so*
79        rm -f $(INSTALLDIR)/util-linux/usr/lib/libmount.la
80        rm -f $(INSTALLDIR)/util-linux/usr/lib/libfdisk*
81        rm -f $(INSTALLDIR)/util-linux/usr/lib/libsmartcols*
82        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.a
83        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.la
84        rm -f $(INSTALLDIR)/util-linux/usr/lib/libuuid.a
85        rm -f $(INSTALLDIR)/util-linux/usr/lib/libuuid.la
86ifneq ($(CONFIG_ASTERISK),y)
87ifneq ($(CONFIG_ZABBIX),y)
88ifneq ($(CONFIG_MC),y)
89ifneq ($(CONFIG_LIBQMI),y)
90ifneq ($(CONFIG_WEBSERVER),y)
91        rm -f $(INSTALLDIR)/util-linux/usr/lib/libblkid.so*
92endif
93endif
94endif
95endif
96endif
97        rm -f $(INSTALLDIR)/util-linux/lib/libfdisk.so*
98        rm -f $(INSTALLDIR)/util-linux/lib/libsmartcols.so*
99
100
101
102glib20-clean:
103        $(MAKE) -C glib20/libiconv clean
104        $(MAKE) -C glib20/gettext clean
105        $(MAKE) -C glib20/libglib clean
106
107glib20-install:
108        install -D glib20/libglib/glib/.libs/libglib-2.0.so.0 $(INSTALLDIR)/glib20/usr/lib/libglib-2.0.so.0
109ifeq ($(CONFIG_MC),y)
110        install -D glib20/libglib/gmodule/.libs/libgmodule-2.0.so.0 $(INSTALLDIR)/glib20/usr/lib/libgmodule-2.0.so.0
111endif
112ifeq ($(CONFIG_LIBQMI),y)
113        install -D glib20/libglib/gmodule/.libs/libgmodule-2.0.so.0 $(INSTALLDIR)/glib20/usr/lib/libgmodule-2.0.so.0
114        install -D glib20/libglib/gthread/.libs/libgthread-2.0.so.0 $(INSTALLDIR)/glib20/usr/lib/libgthread-2.0.so.0
115        install -D glib20/libglib/gobject/.libs/libgobject-2.0.so.0 $(INSTALLDIR)/glib20/usr/lib/libgobject-2.0.so.0
116        install -D glib20/libglib/gio/.libs/libgio-2.0.so.0 $(INSTALLDIR)/glib20/usr/lib/libgio-2.0.so.0
117endif
118        install -D glib20/libiconv/lib/.libs/libiconv.so.2 $(INSTALLDIR)/glib20/usr/lib/libiconv.so.2
119        -install -D glib20/gettext/gettext-runtime/intl/.libs/libintl.so.8 $(INSTALLDIR)/glib20/usr/lib/libintl.so.8
120        -install -D glib20/gettext/gettext-runtime/intl/.libs/libgnuintl.so.8 $(INSTALLDIR)/glib20/usr/lib/libgnuintl.so.8
121#       install -D glib20/gettext/gettext-runtime/libasprintf/.libs/libasprintf.so.0 $(INSTALLDIR)/glib20/usr/lib/libasprintf.so.0
122        -install -D glib20/gettext/gettext-runtime/src/.libs/envsubst $(INSTALLDIR)/glib20/usr/bin/envsubst
123        -install -D glib20/gettext/gettext-runtime/src/.libs/gettext $(INSTALLDIR)/glib20/usr/bin/gettext
124        -install -D glib20/gettext/gettext-runtime/src/.libs/ngettext $(INSTALLDIR)/glib20/usr/bin/ngettext
125
Note: See TracBrowser for help on using the repository browser.