The purpose of this mail library is to provide a portable, efficient framework for different kinds of mail access: IMAP, SMTP, POP and NNTP.
It provides an API for C language.
- IMAP
- SMTP
- POP
- NNTP
- RFC822/MIME message builder
- RFC822/MIME message parser
- Maildir
- mbox
- MH
You need to install autoconf, automake and libtool. They can be installed using brew.
$ ./autogen.sh
$ make
You can use flag --with-poll for using poll() instead of select() for checking connection status
$ gcc -c -o sample.o sample.c `libetpan-config --cflags`
$ gcc -o sample sample.o `libetpan-config --libs`
- Download Xcode
- Open
build-mac/libetpan.xcodeproj
- Choose the correct target "static libetpan" for Mac or "libetpan ios" for iOS.
- Build
- Add
libetpan.xcodeproj
as sub-project - Link with libetpan.a
- Add
libetpan.xcodeproj
as sub-project - Link with libetpan-ios.a
- Set "Other Linker Flags":
-lsasl2
- See README and Visual Studio Solution in build-windows folder
You need to install autoconf, automake and libtool. They can be installed using brew.
$ ./autogen.sh
$ make
- cd libetpan/build-android
$ export ANDROID_NDK=/Users/xxx/Library/Android/sdk/ndk/21.3.6528147 #Use ndk 21
$ ./build.sh
- cd libetpan/build-android/dependencies/openssl
$ export ANDROID_NDK=/Users/xxx/Library/Android/sdk/ndk/21.3.6528147 #Use ndk 21
$ ./build.sh
- cd libetpan/build-android/dependencies
$ ./download-cyrus-sasl.sh
- cd libetpan/build-android/dependencies/cyrus-sasl
$ export ANDROID_NDK=/Users/xxx/Library/Android/sdk/ndk/17.2.4988734 #Use ndk 17
$ ./build.sh
- cd libetpan/build-android
$ export ANDROID_NDK=/Users/xxx/Library/Android/sdk/ndk/21.3.6528147 #Use ndk 21
$ ./build.sh
See http://etpan.org/libetpan.html for more information and examples.