Mageia Bugzilla – Attachment 10482 Details for
Bug 23853
Update android-tools to 9.0.0_r21
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Proposal spec file
android-tools.spec (text/plain), 13.70 KB, created by
Kristoffer Grundström
on 2018-11-17 01:16:23 CET
(
hide
)
Description:
Proposal spec file
Filename:
MIME Type:
Creator:
Kristoffer Grundström
Created:
2018-11-17 01:16:23 CET
Size:
13.70 KB
patch
obsolete
>Name: android-tools >Version: 9.0.0_r16 >Release: %mkrel 1 >Summary: Android platform tools (adb, fastboot, mkbootimg) ># The entire source code is Apache Software License except fastboot/ which is BSD >License: Apache 2.0 >Group: Development/Tools >URL: http://android.googlesource.com/ > >#http://developer.android.com/guide/developing/tools/ ># git clone --single-branch --depth 1 -b android-$VERSION https://android.googlesource.com/platform/system/core.git && cd core ># git archive -o ../core-${VERSION}.tar --prefix platform/system/core/ android-$VERSION ># ># git clone --single-branch --depth 1 -b android-$VERSION https://android.googlesource.com/platform/system/extras.git && cd extras ># git archive -o ../extras-${VERSION}.tar --prefix platform/system/extras/ android-$VERSION ># ># git clone --single-branch --depth 1 -b android-$VERSION https://android.googlesource.com/platform/external/e2fsprogs.git && cd e2fsprogs ># git archive -o ../e2fsprogs-${VERSION}.tar --prefix platform/external/e2fsprogs/ android-$VERSION ># ># git clone https://github.com/ggrandou/abootimg.git && cd abootimg ># git archive -o ../abootimg-$(date +%Y%m%d).tar --prefix abootimg/ origin/master ># ># git clone git://codeaurora.org/quic/kernel/skales && cd skales ># git archive -o ../skales-$(date +%Y%m%d).tar.xz --prefix skales/ origin/master >Source0: core-%{version}.tar.xz >Source1: extras-%{version}.tar.xz >Source2: e2fsprogs-%{version}.tar.xz >Source3: abootimg-%{date}.tar.xz >Source4: 51-android.rules >Source5: adb.service ># Useful for generating Android-style boot.img images containing ># non-Android kernels >Source6: skales-%{date}.tar.xz >Source7: package-source.sh >Patch1: adb-glib-2.28.patch >Patch2: adb-system-libraries.patch >Patch3: adb-system-openssl.patch >Patch4: fastboot-use-custom-mke2fs.patch >Patch5: libbase-clang-5.0.patch >Patch6: libcrypto_utils-openssl-1.1.patch >Patch7: make_ext4fs-add-keep-uids-option.patch >BuildRequires: pkgconfig(libusb-1.0) >BuildRequires: pkgconfig(zlib) >BuildRequires: pkgconfig(libcrypto) >BuildRequires: pkgconfig(blkid) >BuildRequires: pkgconfig(libselinux) >BuildRequires: pkgconfig(openssl) >BuildRequires: gtest-devel > >Provides: adb = %{version}-%{release} >Provides: fastboot = %{version}-%{release} >Provides: mkbootimg = %{version}-%{release} > >%description >This package provides various tools for working with (and on) Android devices: >adb -- The Android Debug Bridge client >fastboot -- A tool for talking to Android's "fastboot" bootloader >simg2img -- A tool for converting Android sparse images into regular > filesystems >img2simg -- A tool for converting regular filesystem images to Android > sparse images that can be used with fastboot >append2simg -- A tool to append to a sparse image >make_ext4fs -- A tool to generate ext4 sparse images > >For Mageia you must use the following commands : > >- adb >- fastboot-android >- mkbootimg > >%prep >%setup -q -a 1 -a 3 -a 4 -c %{name}-%{version} >ln -s core-%{version} core >ln -s extras-%{version} extras >ln -s e2fsprogs-%{version} e2fsprogs >ln -s abootimg-%{date} abootimg >%apply_patches > >%build >cd system/core/libsparse >for i in backed_block output_file sparse sparse_crc32 sparse_err; do > %{__cc} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o $i.o -c $i.c >done >for i in sparse_read; do > %{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../base/include -o $i.o -c $i.cpp >done >ar cru libsparse.a *.o >ranlib libsparse.a > ># We only need a small subset of libbase -- the other files are "missing" intentionally >cd ../base >for i in file logging parsenetaddress stringprintf strings errors_unix test_utils; do > %{__cxx} %{optflags} -std=gnu++14 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../include -o $i.o -c $i.cpp >done >ar cru libbase.a *.o >ranlib libbase.a > >cd ../libsparse >for i in simg2img img2simg append2simg; do > %{__cc} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o $i.o -c $i.c >done >%{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o simg2img simg2img.o $(pkg-config --libs zlib) libsparse.a ../base/libbase.a >%{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o img2simg img2simg.o $(pkg-config --libs zlib) libsparse.a ../base/libbase.a >%{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o append2simg append2simg.o $(pkg-config --libs zlib) libsparse.a ../base/libbase.a > ># We only need a small subset of libcutils -- the other files are "missing" intentionally >cd ../libcutils >for i in load_file socket_local_client_unix socket_network_client_unix socket_local_server_unix sockets_unix socket_inaddr_any_server_unix sockets threads fs_config canned_fs_config android_get_control_file; do > if [ -e $i.c ]; then > %{__cc} -std=gnu11 %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Dchar16_t=uint16_t -Iinclude -I../include -o $i.o -c $i.c > else > %{__cxx} -std=gnu++14 %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Dchar16_t=uint16_t -Iinclude -I../include -o $i.o -c $i.cpp > fi >done >ar cru libcutils.a *.o >ranlib libcutils.a > ># We only need a small subset of libutils -- the other files are "missing" intentionally >cd ../libutils >for i in FileMap; do > %{__cxx} -std=gnu++14 %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../include -o $i.o -c $i.cpp >done >ar cru libutils.a *.o >ranlib libutils.a > ># We only need a small subset of liblog -- the other files are "missing" intentionally >cd ../liblog >for i in log_event_write fake_log_device log_event_list logger_write config_write logger_lock fake_writer logger_name local_logger stderr_write logprint config_read; do > %{__cc} %{optflags} -std=gnu11 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -DLIBLOG_LOG_TAGS=1005 -DFAKE_LOG_DEVICE=1 -D_GNU_SOURCE -Iinclude -I../include -o $i.o -c $i.c >done >ar cru liblog.a *.o >ranlib liblog.a > >cd ../libziparchive >for i in zip_archive.cc; do > %{__cxx} -std=gnu++14 %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -o ${i/.cc/.o} -c $i -I. -Iinclude -I../include -I../base/include >done >ar cru libziparchive.a *.o >ranlib libziparchive.a > >cd ../libcrypto_utils >for i in *.c; do > %{__cc} -std=gnu11 %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -o ${i/.c/.o} -c $i -Iinclude >done >ar cru libcrypto_utils.a *.o >ranlib libcrypto_utils.a > >cd ../../extras/ext4_utils >for i in make_ext4fs ext4fixup ext4_utils allocate contents extent indirect sha1 wipe crc16 ext4_sb; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -Iinclude -I../../core/include -I../../core/libsparse/include -o $i.o -c $i.c >done >ar cru libext4_utils.a *.o >ranlib libext4_utils.a >pwd >%{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -o make_ext4fs make_ext4fs_main.c libext4_utils.a -Iinclude -I../../core/libcutils/include -I../../core/libsparse/include -I../../core/include $(pkg-config --libs libselinux) $(pkg-config --libs zlib) ../../core/libsparse/libsparse.a ../../core/libcutils/libcutils.a ../../core/liblog/liblog.a -lpthread > >cd ../../core/adb >for i in adb adb_auth_host adb_io adb_listeners adb_trace adb_utils fdevent sockets socket_spec sysdeps/errno transport transport_local transport_usb sysdeps_unix client/usb_dispatch client/usb_libusb client/usb_linux adb_client bugreport client/main console commandline diagnose_usb file_sync_client line_printer services shell_service_protocol transport_mdns_unsupported sysdeps/posix/network; do > %{__cxx} %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -DADB_HOST=1 -D_GNU_SOURCE=1 -fvisibility=hidden -std=gnu++14 -I../base/include -I../include -I../libcrypto_utils/include -I. -DADB_VERSION=\"26.1.0-eng.bero.$(date +%%Y%%m%%d.%%H%%M%%S)\" -DADB_REVISION='"%{version}-%{release}"' -o $i.o -c $i.cpp >done >%{__cxx} %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -fvisibility=hidden -std=gnu++14 -o adb *.o client/*.o sysdeps/*.o sysdeps/*/*.o -lpthread $(pkg-config --libs libcrypto) ../base/libbase.a ../libcutils/libcutils.a $(pkg-config --libs libusb-1.0) ../libcrypto_utils/libcrypto_utils.a > >cd ../fastboot >for i in bootimg_utils engine fastboot fs protocol socket tcp udp util usb_linux; do > %{__cxx} %{optflags} -std=gnu++14 -DFASTBOOT_VERSION=\"26.1.0-eng.bero.$(date +%%Y%%m%%d.%%H%%M%%S)\" -DFASTBOOT_REVISION='"%{version}-%{release}"' -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -D_GNU_SOURCE -I../base/include -I../include -I../adb -I../libsparse/include -I../mkbootimg -I../../extras/ext4_utils/include -I../../extras/f2fs_utils -I../libziparchive/include -o $i.o -c $i.cpp >done >%{__cxx} -std=gnu++14 %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -fvisibility=hidden -o fastboot -lz -lpthread *.o ../adb/diagnose_usb.o ../../extras/ext4_utils/libext4_utils.a ../libcutils/libcutils.a ../libsparse/libsparse.a ../libziparchive/libziparchive.a ../base/libbase.a ../libutils/libutils.a ../liblog/liblog.a > >cd ../../../external/e2fsprogs/lib/ext2fs ># Get rid of bits we don't need... >rm -f bmove.c dosio.c irel_ma.c nt_io.c tst_*.c gen_crc32ctable.c tdbtool.c >for i in *.c; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -I../../../../system/core/libsparse/include -o ${i/.c/.o} -c $i >done >ar cru libext2fs.a *.o >ranlib libext2fs.a > >cd ../et >for i in *.c; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i >done >ar cru libcom_err.a *.o >ranlib libcom_err.a > >cd ../e2p >for i in *.c; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i >done >ar cru libe2p.a *.o >ranlib libe2p.a > >cd ../uuid >rm -f gen_uuid_nt.c >for i in *.c; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i >done >ar cru libuuid.a *.o >ranlib libuuid.a > >cd ../blkid >for i in *.c; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i >done >ar cru libblkid.a *.o >ranlib libblkid.a > >cd ../support >for i in *.c; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i >done >ar cru libsupport.a *.o >ranlib libsupport.a > >cd ../../misc ># create_inode.c's copy_file_range isn't what unistd.h thinks it is >sed -i -e 's,copy_file_range,e2_copy_file_range,g' create_inode.c >for i in mke2fs util mk_hugefiles default_profile create_inode; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I../lib -I../lib/ext2fs -I../misc -o $i.o -c $i.c >done >%{__cxx} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../../core/include -I../../core/libsparse/include -o mke2fs *.o ../lib/ext2fs/*.o ../lib/et/libcom_err.a ../lib/support/libsupport.a ../lib/blkid/libblkid.a ../lib/e2p/libe2p.a ../lib/uuid/libuuid.a ../../../system/core/libsparse/libsparse.a ../../../system/core/libcutils/libcutils.a ../../../system/core/liblog/liblog.a ../../../system/core/base/libbase.a -lz > >cd ../contrib/android >cp ../../misc/create_inode.c . >for i in e2fsdroid block_range create_inode fsmap block_list base_fs perms basefs_allocator hashmap; do > %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I../../lib -I../../lib/ext2fs -I../../misc -I../../../../system/core/libcutils/include -I../../../../system/core/libsparse/include -o $i.o -c $i.c >done >%{__cxx} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../../core/include -I../../core/libsparse/include -o e2fsdroid *.o ../../lib/ext2fs/libext2fs.a ../../../../system/core/libsparse/libsparse.a ../../../../system/core/libcutils/libcutils.a ../../../../system/core/liblog/liblog.a ../../lib/et/libcom_err.a -lselinux ../../../../system/core/base/libbase.a -lz -lpthread > >pwd >cd ../../../../../abootimg >make CFLAGS="%{optflags}" LDFLAGS="%{optflags}" > > > > > >%install > >mkdir -p %{buildroot}%{_bindir} >install -c -m755 system/core/libsparse/simg2img %{buildroot}%{_bindir}/ >install -c -m755 system/core/libsparse/img2simg %{buildroot}%{_bindir}/ >install -c -m755 system/core/libsparse/append2simg %{buildroot}%{_bindir}/ > >install -c -m755 system/extras/ext4_utils/make_ext4fs %{buildroot}%{_bindir}/ > >install -c -m755 system/core/adb/adb %{buildroot}%{_bindir}/ >install -c -m755 system/core/fastboot/fastboot %{buildroot}%{_bindir}/ > >install -c -m755 external/e2fsprogs/contrib/android/e2fsdroid %{buildroot}%{_bindir}/ > >install -c -m755 ../abootimg/abootimg %{buildroot}%{_bindir}/ >install -c -m755 ../abootimg/abootimg-pack-initrd %{buildroot}%{_bindir}/ >install -c -m755 ../abootimg/abootimg-unpack-initrd %{buildroot}%{_bindir}/ > >install -c -m755 ../skales/dtbTool %{buildroot}%{_bindir}/ >install -c -m755 ../skales/mkbootimg %{buildroot}%{_bindir}/ > >%post >%_post_service adb > >%preun >%_preun_service adb > >%files >%{_bindir}/* > >%changelog >* Sat Sep 22 2018 daviddavid <daviddavid> 8.0.0_r4-3.mga7 > (not released yet) >+ Revision: 1295952 >- add patch to fix build with new glibc (thanks to Arusekk) >+ umeabot <umeabot> >- Mageia 7 Mass Rebuild
Name: android-tools Version: 9.0.0_r16 Release: %mkrel 1 Summary: Android platform tools (adb, fastboot, mkbootimg) # The entire source code is Apache Software License except fastboot/ which is BSD License: Apache 2.0 Group: Development/Tools URL: http://android.googlesource.com/ #http://developer.android.com/guide/developing/tools/ # git clone --single-branch --depth 1 -b android-$VERSION https://android.googlesource.com/platform/system/core.git && cd core # git archive -o ../core-${VERSION}.tar --prefix platform/system/core/ android-$VERSION # # git clone --single-branch --depth 1 -b android-$VERSION https://android.googlesource.com/platform/system/extras.git && cd extras # git archive -o ../extras-${VERSION}.tar --prefix platform/system/extras/ android-$VERSION # # git clone --single-branch --depth 1 -b android-$VERSION https://android.googlesource.com/platform/external/e2fsprogs.git && cd e2fsprogs # git archive -o ../e2fsprogs-${VERSION}.tar --prefix platform/external/e2fsprogs/ android-$VERSION # # git clone https://github.com/ggrandou/abootimg.git && cd abootimg # git archive -o ../abootimg-$(date +%Y%m%d).tar --prefix abootimg/ origin/master # # git clone git://codeaurora.org/quic/kernel/skales && cd skales # git archive -o ../skales-$(date +%Y%m%d).tar.xz --prefix skales/ origin/master Source0: core-%{version}.tar.xz Source1: extras-%{version}.tar.xz Source2: e2fsprogs-%{version}.tar.xz Source3: abootimg-%{date}.tar.xz Source4: 51-android.rules Source5: adb.service # Useful for generating Android-style boot.img images containing # non-Android kernels Source6: skales-%{date}.tar.xz Source7: package-source.sh Patch1: adb-glib-2.28.patch Patch2: adb-system-libraries.patch Patch3: adb-system-openssl.patch Patch4: fastboot-use-custom-mke2fs.patch Patch5: libbase-clang-5.0.patch Patch6: libcrypto_utils-openssl-1.1.patch Patch7: make_ext4fs-add-keep-uids-option.patch BuildRequires: pkgconfig(libusb-1.0) BuildRequires: pkgconfig(zlib) BuildRequires: pkgconfig(libcrypto) BuildRequires: pkgconfig(blkid) BuildRequires: pkgconfig(libselinux) BuildRequires: pkgconfig(openssl) BuildRequires: gtest-devel Provides: adb = %{version}-%{release} Provides: fastboot = %{version}-%{release} Provides: mkbootimg = %{version}-%{release} %description This package provides various tools for working with (and on) Android devices: adb -- The Android Debug Bridge client fastboot -- A tool for talking to Android's "fastboot" bootloader simg2img -- A tool for converting Android sparse images into regular filesystems img2simg -- A tool for converting regular filesystem images to Android sparse images that can be used with fastboot append2simg -- A tool to append to a sparse image make_ext4fs -- A tool to generate ext4 sparse images For Mageia you must use the following commands : - adb - fastboot-android - mkbootimg %prep %setup -q -a 1 -a 3 -a 4 -c %{name}-%{version} ln -s core-%{version} core ln -s extras-%{version} extras ln -s e2fsprogs-%{version} e2fsprogs ln -s abootimg-%{date} abootimg %apply_patches %build cd system/core/libsparse for i in backed_block output_file sparse sparse_crc32 sparse_err; do %{__cc} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o $i.o -c $i.c done for i in sparse_read; do %{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../base/include -o $i.o -c $i.cpp done ar cru libsparse.a *.o ranlib libsparse.a # We only need a small subset of libbase -- the other files are "missing" intentionally cd ../base for i in file logging parsenetaddress stringprintf strings errors_unix test_utils; do %{__cxx} %{optflags} -std=gnu++14 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../include -o $i.o -c $i.cpp done ar cru libbase.a *.o ranlib libbase.a cd ../libsparse for i in simg2img img2simg append2simg; do %{__cc} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o $i.o -c $i.c done %{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o simg2img simg2img.o $(pkg-config --libs zlib) libsparse.a ../base/libbase.a %{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o img2simg img2simg.o $(pkg-config --libs zlib) libsparse.a ../base/libbase.a %{__cxx} %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -o append2simg append2simg.o $(pkg-config --libs zlib) libsparse.a ../base/libbase.a # We only need a small subset of libcutils -- the other files are "missing" intentionally cd ../libcutils for i in load_file socket_local_client_unix socket_network_client_unix socket_local_server_unix sockets_unix socket_inaddr_any_server_unix sockets threads fs_config canned_fs_config android_get_control_file; do if [ -e $i.c ]; then %{__cc} -std=gnu11 %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Dchar16_t=uint16_t -Iinclude -I../include -o $i.o -c $i.c else %{__cxx} -std=gnu++14 %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Dchar16_t=uint16_t -Iinclude -I../include -o $i.o -c $i.cpp fi done ar cru libcutils.a *.o ranlib libcutils.a # We only need a small subset of libutils -- the other files are "missing" intentionally cd ../libutils for i in FileMap; do %{__cxx} -std=gnu++14 %{optflags} -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../include -o $i.o -c $i.cpp done ar cru libutils.a *.o ranlib libutils.a # We only need a small subset of liblog -- the other files are "missing" intentionally cd ../liblog for i in log_event_write fake_log_device log_event_list logger_write config_write logger_lock fake_writer logger_name local_logger stderr_write logprint config_read; do %{__cc} %{optflags} -std=gnu11 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -DLIBLOG_LOG_TAGS=1005 -DFAKE_LOG_DEVICE=1 -D_GNU_SOURCE -Iinclude -I../include -o $i.o -c $i.c done ar cru liblog.a *.o ranlib liblog.a cd ../libziparchive for i in zip_archive.cc; do %{__cxx} -std=gnu++14 %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -o ${i/.cc/.o} -c $i -I. -Iinclude -I../include -I../base/include done ar cru libziparchive.a *.o ranlib libziparchive.a cd ../libcrypto_utils for i in *.c; do %{__cc} -std=gnu11 %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -o ${i/.c/.o} -c $i -Iinclude done ar cru libcrypto_utils.a *.o ranlib libcrypto_utils.a cd ../../extras/ext4_utils for i in make_ext4fs ext4fixup ext4_utils allocate contents extent indirect sha1 wipe crc16 ext4_sb; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -Iinclude -I../../core/include -I../../core/libsparse/include -o $i.o -c $i.c done ar cru libext4_utils.a *.o ranlib libext4_utils.a pwd %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -o make_ext4fs make_ext4fs_main.c libext4_utils.a -Iinclude -I../../core/libcutils/include -I../../core/libsparse/include -I../../core/include $(pkg-config --libs libselinux) $(pkg-config --libs zlib) ../../core/libsparse/libsparse.a ../../core/libcutils/libcutils.a ../../core/liblog/liblog.a -lpthread cd ../../core/adb for i in adb adb_auth_host adb_io adb_listeners adb_trace adb_utils fdevent sockets socket_spec sysdeps/errno transport transport_local transport_usb sysdeps_unix client/usb_dispatch client/usb_libusb client/usb_linux adb_client bugreport client/main console commandline diagnose_usb file_sync_client line_printer services shell_service_protocol transport_mdns_unsupported sysdeps/posix/network; do %{__cxx} %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -DADB_HOST=1 -D_GNU_SOURCE=1 -fvisibility=hidden -std=gnu++14 -I../base/include -I../include -I../libcrypto_utils/include -I. -DADB_VERSION=\"26.1.0-eng.bero.$(date +%%Y%%m%%d.%%H%%M%%S)\" -DADB_REVISION='"%{version}-%{release}"' -o $i.o -c $i.cpp done %{__cxx} %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -fvisibility=hidden -std=gnu++14 -o adb *.o client/*.o sysdeps/*.o sysdeps/*/*.o -lpthread $(pkg-config --libs libcrypto) ../base/libbase.a ../libcutils/libcutils.a $(pkg-config --libs libusb-1.0) ../libcrypto_utils/libcrypto_utils.a cd ../fastboot for i in bootimg_utils engine fastboot fs protocol socket tcp udp util usb_linux; do %{__cxx} %{optflags} -std=gnu++14 -DFASTBOOT_VERSION=\"26.1.0-eng.bero.$(date +%%Y%%m%%d.%%H%%M%%S)\" -DFASTBOOT_REVISION='"%{version}-%{release}"' -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -D_GNU_SOURCE -I../base/include -I../include -I../adb -I../libsparse/include -I../mkbootimg -I../../extras/ext4_utils/include -I../../extras/f2fs_utils -I../libziparchive/include -o $i.o -c $i.cpp done %{__cxx} -std=gnu++14 %{optflags} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -fvisibility=hidden -o fastboot -lz -lpthread *.o ../adb/diagnose_usb.o ../../extras/ext4_utils/libext4_utils.a ../libcutils/libcutils.a ../libsparse/libsparse.a ../libziparchive/libziparchive.a ../base/libbase.a ../libutils/libutils.a ../liblog/liblog.a cd ../../../external/e2fsprogs/lib/ext2fs # Get rid of bits we don't need... rm -f bmove.c dosio.c irel_ma.c nt_io.c tst_*.c gen_crc32ctable.c tdbtool.c for i in *.c; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -I../../../../system/core/libsparse/include -o ${i/.c/.o} -c $i done ar cru libext2fs.a *.o ranlib libext2fs.a cd ../et for i in *.c; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i done ar cru libcom_err.a *.o ranlib libcom_err.a cd ../e2p for i in *.c; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i done ar cru libe2p.a *.o ranlib libe2p.a cd ../uuid rm -f gen_uuid_nt.c for i in *.c; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i done ar cru libuuid.a *.o ranlib libuuid.a cd ../blkid for i in *.c; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i done ar cru libblkid.a *.o ranlib libblkid.a cd ../support for i in *.c; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I. -I.. -o ${i/.c/.o} -c $i done ar cru libsupport.a *.o ranlib libsupport.a cd ../../misc # create_inode.c's copy_file_range isn't what unistd.h thinks it is sed -i -e 's,copy_file_range,e2_copy_file_range,g' create_inode.c for i in mke2fs util mk_hugefiles default_profile create_inode; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I../lib -I../lib/ext2fs -I../misc -o $i.o -c $i.c done %{__cxx} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../../core/include -I../../core/libsparse/include -o mke2fs *.o ../lib/ext2fs/*.o ../lib/et/libcom_err.a ../lib/support/libsupport.a ../lib/blkid/libblkid.a ../lib/e2p/libe2p.a ../lib/uuid/libuuid.a ../../../system/core/libsparse/libsparse.a ../../../system/core/libcutils/libcutils.a ../../../system/core/liblog/liblog.a ../../../system/core/base/libbase.a -lz cd ../contrib/android cp ../../misc/create_inode.c . for i in e2fsdroid block_range create_inode fsmap block_list base_fs perms basefs_allocator hashmap; do %{__cc} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -std=gnu11 -I../../lib -I../../lib/ext2fs -I../../misc -I../../../../system/core/libcutils/include -I../../../../system/core/libsparse/include -o $i.o -c $i.c done %{__cxx} %{optflags} -DANDROID -DHOST -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE=1 -D_LARGEFILE_SOURCE=1 -Iinclude -I../../core/include -I../../core/libsparse/include -o e2fsdroid *.o ../../lib/ext2fs/libext2fs.a ../../../../system/core/libsparse/libsparse.a ../../../../system/core/libcutils/libcutils.a ../../../../system/core/liblog/liblog.a ../../lib/et/libcom_err.a -lselinux ../../../../system/core/base/libbase.a -lz -lpthread pwd cd ../../../../../abootimg make CFLAGS="%{optflags}" LDFLAGS="%{optflags}" %install mkdir -p %{buildroot}%{_bindir} install -c -m755 system/core/libsparse/simg2img %{buildroot}%{_bindir}/ install -c -m755 system/core/libsparse/img2simg %{buildroot}%{_bindir}/ install -c -m755 system/core/libsparse/append2simg %{buildroot}%{_bindir}/ install -c -m755 system/extras/ext4_utils/make_ext4fs %{buildroot}%{_bindir}/ install -c -m755 system/core/adb/adb %{buildroot}%{_bindir}/ install -c -m755 system/core/fastboot/fastboot %{buildroot}%{_bindir}/ install -c -m755 external/e2fsprogs/contrib/android/e2fsdroid %{buildroot}%{_bindir}/ install -c -m755 ../abootimg/abootimg %{buildroot}%{_bindir}/ install -c -m755 ../abootimg/abootimg-pack-initrd %{buildroot}%{_bindir}/ install -c -m755 ../abootimg/abootimg-unpack-initrd %{buildroot}%{_bindir}/ install -c -m755 ../skales/dtbTool %{buildroot}%{_bindir}/ install -c -m755 ../skales/mkbootimg %{buildroot}%{_bindir}/ %post %_post_service adb %preun %_preun_service adb %files %{_bindir}/* %changelog * Sat Sep 22 2018 daviddavid <daviddavid> 8.0.0_r4-3.mga7 (not released yet) + Revision: 1295952 - add patch to fix build with new glibc (thanks to Arusekk) + umeabot <umeabot> - Mageia 7 Mass Rebuild
View Attachment As Raw
Actions:
View
Attachments on
bug 23853
:
10474
|
10475
|
10476
|
10477
|
10478
|
10479
|
10480
|
10481
|
10482
|
11104
|
11105
|
11106
|
11107
|
11108
|
11109
|
11110
|
11111
|
11112
|
11113
|
11114