Trying to cross-compile rsync 3.2.3 for an M1 Mac

Fred Fugate via rsync <[email protected]>
Newsgroups gmane.network.rsync.general
Message-ID <CAC7gbfzn09yroz3q1Dq-TDK0_DMs8dV_v5CM2OShW7EJCY5GRA@mail.gmail.com>
Hi,

On an Intel Mac, I'm trying to cross-compile rsync 3.2.3 for an M1 Mac. I
configured like this:

./configure \
CFLAGS='-target arm64-apple-macos' \
--host=aarch64-apple-darwin \
--prefix=/opt/fred \
--with-rsyncd-conf=/opt/fred/etc/rsyncd.conf  \
--disable-openssl \
--disable-xxhash \
--disable-zstd \
--disable-lz4 \
--disable-simd



configure ran well enough, but unfortunately I'm running into the following
issue at the end of the compilation:

[SNIP...]
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/secure/_stdio.h:56:9:
note: previous definition is here
#define snprintf(str, len, ...) \
        ^
1 warning generated.
gcc -I./zlib -I./popt -target arm64-apple-macos -DHAVE_CONFIG_H -Wall -W
 -o rsync flist.o rsync.o generator.o receiver.o cleanup.o sender.o
exclude.o util.o util2.o main.o checksum.o match.o syscall.o log.o backup.o
delete.o options.o io.o compat.o hlink.o token.o uidlist.o socket.o
hashtable.o usage.o fileio.o batch.o clientname.o chmod.o acls.o xattrs.o
progress.o pipe.o lib/md5-asm-x86_64.o  params.o loadparm.o clientserver.o
access.o connection.o authenticate.o lib/wildmatch.o lib/compat.o
lib/snprintf.o lib/mdfour.o lib/md5.o lib/permstring.o lib/pool_alloc.o
lib/sysacls.o lib/sysxattrs.o  zlib/deflate.o zlib/inffast.o zlib/inflate.o
zlib/inftrees.o zlib/trees.o zlib/zutil.o zlib/adler32.o zlib/compress.o
zlib/crc32.o popt/findme.o  popt/popt.o  popt/poptconfig.o popt/popthelp.o
popt/poptparse.o -liconv

ld: warning: ignoring file lib/md5-asm-x86_64.o, building for macOS-arm64
but attempting to link with file built for unknown-x86_64

Undefined symbols for architecture arm64:
  "_md5_process_asm", referenced from:
      _md5_update in md5.o

ld: symbol(s) not found for architecture arm64

clang: error: linker command failed with exit code 1 (use -v to see
invocation)

make: *** [rsync] Error 1




It seems that the rsync source tarfile includes lib/md5-asm-x86_64.S, but
for my compilation to work, I need a file called lib/md5-asm-aarch64.S ?

Where would I get this file? (or how would I build my
own lib/md5-asm-aarch64.S ?)


Thanks,
Fred

-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.