-
Notifications
You must be signed in to change notification settings - Fork 6.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[readline] readline port builds for MacOS #22000
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
aadb085
[readline] New readline-osx port for MacOS
zekoz dba44d9
Merge remote-tracking branch 'origin/master' into HEAD
BillyONeal 6219378
Bump port-version of readline and fix version database.
BillyONeal 9da517d
Merge remote-tracking branch 'origin/master' into HEAD
BillyONeal 684ce49
Remove unnecessary -D_CRT_SECURE_NO_WARNINGS.
BillyONeal File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
cmake_minimum_required(VERSION 3.0) | ||
project(readline C) | ||
|
||
add_definitions(-DREADLINE_LIBRARY) | ||
add_definitions(-DHAVE_CONFIG_H) | ||
|
||
if(BUILD_SHARED_LIBS) | ||
add_definitions(-DBUILD_READLINE_DLL) | ||
else() | ||
add_definitions(-DREADLINE_STATIC) | ||
endif() | ||
|
||
include_directories( | ||
${CMAKE_CURRENT_SOURCE_DIR} # thats where the config.h is located | ||
) | ||
|
||
add_library( | ||
readline | ||
readline.c | ||
funmap.c | ||
keymaps.c | ||
vi_mode.c | ||
parens.c | ||
rltty.c | ||
complete.c | ||
bind.c | ||
colors.c | ||
isearch.c | ||
display.c | ||
signals.c | ||
util.c | ||
kill.c | ||
undo.c | ||
macro.c | ||
input.c | ||
callback.c | ||
terminal.c | ||
xmalloc.c | ||
history.c | ||
histsearch.c | ||
histexpand.c | ||
histfile.c | ||
nls.c | ||
parse-colors.c | ||
search.c | ||
shell.c | ||
savestring.c | ||
tilde.c | ||
text.c | ||
misc.c | ||
compat.c | ||
mbutil.c | ||
xfree.c | ||
support/wcwidth.c) | ||
|
||
install( | ||
TARGETS readline | ||
RUNTIME DESTINATION bin | ||
LIBRARY DESTINATION lib | ||
ARCHIVE DESTINATION lib) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,303 @@ | ||
/* config.h. Generated from config.h.in by configure. */ | ||
/* config.h.in. Maintained by hand. */ | ||
|
||
/* Template definitions for autoconf */ | ||
#define __EXTENSIONS__ 1 | ||
#define _ALL_SOURCE 1 | ||
#define _GNU_SOURCE 1 | ||
/* #undef _POSIX_SOURCE */ | ||
/* #undef _POSIX_1_SOURCE */ | ||
#define _POSIX_PTHREAD_SEMANTICS 1 | ||
#define _TANDEM_SOURCE 1 | ||
/* #undef _MINIX */ | ||
|
||
/* Define NO_MULTIBYTE_SUPPORT to not compile in support for multibyte | ||
characters, even if the OS supports them. */ | ||
/* #undef NO_MULTIBYTE_SUPPORT */ | ||
|
||
/* #undef _FILE_OFFSET_BITS */ | ||
|
||
/* Define as the return type of signal handlers (int or void). */ | ||
#define RETSIGTYPE void | ||
|
||
#define VOID_SIGHANDLER 1 | ||
|
||
/* Characteristics of the compiler. */ | ||
/* #undef sig_atomic_t */ | ||
|
||
/* #undef size_t */ | ||
|
||
/* #undef ssize_t */ | ||
|
||
/* #undef const */ | ||
|
||
/* #undef volatile */ | ||
|
||
#define PROTOTYPES 1 | ||
#define __PROTOTYPES 1 | ||
|
||
/* #undef __CHAR_UNSIGNED__ */ | ||
|
||
/* Define if the `S_IS*' macros in <sys/stat.h> do not work properly. */ | ||
/* #undef STAT_MACROS_BROKEN */ | ||
|
||
/* Define if you have the chown function. */ | ||
#define HAVE_CHOWN 1 | ||
|
||
/* Define if you have the fcntl function. */ | ||
#define HAVE_FCNTL 1 | ||
|
||
/* Define if you have the fnmatch function. */ | ||
#define HAVE_FNMATCH 1 | ||
|
||
/* Define if you have the getpwent function. */ | ||
#define HAVE_GETPWENT 1 | ||
|
||
/* Define if you have the getpwnam function. */ | ||
#define HAVE_GETPWNAM 1 | ||
|
||
/* Define if you have the getpwuid function. */ | ||
#define HAVE_GETPWUID 1 | ||
|
||
/* Define if you have the isascii function. */ | ||
#define HAVE_ISASCII 1 | ||
|
||
/* Define if you have the iswctype function. */ | ||
#define HAVE_ISWCTYPE 1 | ||
|
||
/* Define if you have the iswlower function. */ | ||
#define HAVE_ISWLOWER 1 | ||
|
||
/* Define if you have the iswupper function. */ | ||
#define HAVE_ISWUPPER 1 | ||
|
||
/* Define if you have the isxdigit function. */ | ||
#define HAVE_ISXDIGIT 1 | ||
|
||
/* Define if you have the kill function. */ | ||
#define HAVE_KILL 1 | ||
|
||
/* Define if you have the lstat function. */ | ||
#define HAVE_LSTAT 1 | ||
|
||
/* Define if you have the mbrlen function. */ | ||
#define HAVE_MBRLEN 1 | ||
|
||
/* Define if you have the mbrtowc function. */ | ||
#define HAVE_MBRTOWC 1 | ||
|
||
/* Define if you have the mbsrtowcs function. */ | ||
#define HAVE_MBSRTOWCS 1 | ||
|
||
/* Define if you have the memmove function. */ | ||
#define HAVE_MEMMOVE 1 | ||
|
||
/* Define if you have the pselect function. */ | ||
#define HAVE_PSELECT 1 | ||
|
||
/* Define if you have the putenv function. */ | ||
#define HAVE_PUTENV 1 | ||
|
||
/* Define if you have the readlink function. */ | ||
#define HAVE_READLINK 1 | ||
|
||
/* Define if you have the select function. */ | ||
#define HAVE_SELECT 1 | ||
|
||
/* Define if you have the setenv function. */ | ||
#define HAVE_SETENV 1 | ||
|
||
/* Define if you have the setlocale function. */ | ||
#define HAVE_SETLOCALE 1 | ||
|
||
/* Define if you have the strcasecmp function. */ | ||
#define HAVE_STRCASECMP 1 | ||
|
||
/* Define if you have the strcoll function. */ | ||
#define HAVE_STRCOLL 1 | ||
|
||
/* #undef STRCOLL_BROKEN */ | ||
|
||
/* Define if you have the strpbrk function. */ | ||
#define HAVE_STRPBRK 1 | ||
|
||
/* Define if you have the tcgetattr function. */ | ||
#define HAVE_TCGETATTR 1 | ||
|
||
/* Define if you have the towlower function. */ | ||
#define HAVE_TOWLOWER 1 | ||
|
||
/* Define if you have the towupper function. */ | ||
#define HAVE_TOWUPPER 1 | ||
|
||
/* Define if you have the vsnprintf function. */ | ||
#define HAVE_VSNPRINTF 1 | ||
|
||
/* Define if you have the wcrtomb function. */ | ||
#define HAVE_WCRTOMB 1 | ||
|
||
/* Define if you have the wcscoll function. */ | ||
#define HAVE_WCSCOLL 1 | ||
|
||
/* Define if you have the wctype function. */ | ||
#define HAVE_WCTYPE 1 | ||
|
||
/* Define if you have the wcwidth function. */ | ||
#define HAVE_WCWIDTH 1 | ||
|
||
/* and whether it works */ | ||
/* #undef WCWIDTH_BROKEN */ | ||
|
||
#define STDC_HEADERS 1 | ||
|
||
/* Define if you have the <dirent.h> header file. */ | ||
#define HAVE_DIRENT_H 1 | ||
|
||
/* Define if you have the <fcntl.h> header file. */ | ||
#define HAVE_FCNTL_H 1 | ||
|
||
/* Define if you have the <langinfo.h> header file. */ | ||
#define HAVE_LANGINFO_H 1 | ||
|
||
/* Define if you have the <libaudit.h> header file. */ | ||
/* #undef HAVE_LIBAUDIT_H */ | ||
|
||
/* Define if you have the <limits.h> header file. */ | ||
#define HAVE_LIMITS_H 1 | ||
|
||
/* Define if you have the <locale.h> header file. */ | ||
#define HAVE_LOCALE_H 1 | ||
|
||
/* Define if you have the <memory.h> header file. */ | ||
#define HAVE_MEMORY_H 1 | ||
|
||
/* Define if you have the <ndir.h> header file. */ | ||
/* #undef HAVE_NDIR_H */ | ||
|
||
/* Define if you have the <ncurses/termcap.h> header file. */ | ||
/* #undef HAVE_NCURSES_TERMCAP_H */ | ||
|
||
/* Define if you have the <pwd.h> header file. */ | ||
#define HAVE_PWD_H 1 | ||
|
||
/* Define if you have the <stdarg.h> header file. */ | ||
#define HAVE_STDARG_H 1 | ||
|
||
/* Define if you have the <stdbool.h> header file. */ | ||
#define HAVE_STDBOOL_H 1 | ||
|
||
/* Define if you have the <stdlib.h> header file. */ | ||
#define HAVE_STDLIB_H 1 | ||
|
||
/* Define if you have the <string.h> header file. */ | ||
#define HAVE_STRING_H 1 | ||
|
||
/* Define if you have the <strings.h> header file. */ | ||
#define HAVE_STRINGS_H 1 | ||
|
||
/* Define if you have the <sys/dir.h> header file. */ | ||
/* #undef HAVE_SYS_DIR_H */ | ||
|
||
/* Define if you have the <sys/file.h> header file. */ | ||
#define HAVE_SYS_FILE_H 1 | ||
|
||
/* Define if you have the <sys/ioctl.h> header file. */ | ||
#define HAVE_SYS_IOCTL_H 1 | ||
|
||
/* Define if you have the <sys/ndir.h> header file. */ | ||
/* #undef HAVE_SYS_NDIR_H */ | ||
|
||
/* Define if you have the <sys/pte.h> header file. */ | ||
/* #undef HAVE_SYS_PTE_H */ | ||
|
||
/* Define if you have the <sys/ptem.h> header file. */ | ||
/* #undef HAVE_SYS_PTEM_H */ | ||
|
||
/* Define if you have the <sys/select.h> header file. */ | ||
#define HAVE_SYS_SELECT_H 1 | ||
|
||
/* Define if you have the <sys/stream.h> header file. */ | ||
/* #undef HAVE_SYS_STREAM_H */ | ||
|
||
/* Define if you have the <termcap.h> header file. */ | ||
#define HAVE_TERMCAP_H 1 | ||
|
||
/* Define if you have the <termio.h> header file. */ | ||
/* #undef HAVE_TERMIO_H */ | ||
|
||
/* Define if you have the <termios.h> header file. */ | ||
#define HAVE_TERMIOS_H 1 | ||
|
||
/* Define if you have the <unistd.h> header file. */ | ||
#define HAVE_UNISTD_H 1 | ||
|
||
/* Define if you have the <varargs.h> header file. */ | ||
/* #undef HAVE_VARARGS_H */ | ||
|
||
/* Define if you have the <wchar.h> header file. */ | ||
#define HAVE_WCHAR_H 1 | ||
|
||
/* Define if you have the <wctype.h> header file. */ | ||
#define HAVE_WCTYPE_H 1 | ||
|
||
#define HAVE_MBSTATE_T 1 | ||
|
||
/* Define if you have wchar_t in <wctype.h>. */ | ||
#define HAVE_WCHAR_T 1 | ||
|
||
/* Define if you have wctype_t in <wctype.h>. */ | ||
#define HAVE_WCTYPE_T 1 | ||
|
||
/* Define if you have wint_t in <wctype.h>. */ | ||
#define HAVE_WINT_T 1 | ||
|
||
/* Define if you have <langinfo.h> and nl_langinfo(CODESET). */ | ||
#define HAVE_LANGINFO_CODESET 1 | ||
|
||
/* Define if you have <linux/audit.h> and it defines AUDIT_USER_TTY */ | ||
#define HAVE_DECL_AUDIT_USER_TTY 0 | ||
|
||
/* Definitions pulled in from aclocal.m4. */ | ||
#define VOID_SIGHANDLER 1 | ||
|
||
/* #undef GWINSZ_IN_SYS_IOCTL */ | ||
|
||
#define STRUCT_WINSIZE_IN_SYS_IOCTL 1 | ||
|
||
/* #undef STRUCT_WINSIZE_IN_TERMIOS */ | ||
|
||
#define TIOCSTAT_IN_SYS_IOCTL 1 | ||
|
||
#define FIONREAD_IN_SYS_IOCTL 1 | ||
|
||
/* #undef SPEED_T_IN_SYS_TYPES */ | ||
|
||
#define HAVE_GETPW_DECLS 1 | ||
|
||
#define HAVE_STRUCT_DIRENT_D_INO 1 | ||
|
||
#define HAVE_STRUCT_DIRENT_D_FILENO 1 | ||
|
||
/* #undef HAVE_STRUCT_DIRENT_D_NAMLEN */ | ||
|
||
/* #undef HAVE_BSD_SIGNALS */ | ||
|
||
#define HAVE_POSIX_SIGNALS 1 | ||
|
||
/* #undef HAVE_USG_SIGHOLD */ | ||
|
||
/* #undef MUST_REINSTALL_SIGHANDLERS */ | ||
|
||
#define HAVE_POSIX_SIGSETJMP 1 | ||
|
||
#define CTYPE_NON_ASCII 1 | ||
|
||
/* modify settings or make new ones based on what autoconf tells us. */ | ||
|
||
/* Ultrix botches type-ahead when switching from canonical to | ||
non-canonical mode, at least through version 4.3 */ | ||
#if !defined (HAVE_TERMIOS_H) || !defined (HAVE_TCGETATTR) || defined (ultrix) | ||
# define TERMIOS_MISSING | ||
#endif | ||
|
||
/* VARARGS defines moved to rlstdc.h */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
vcpkg_download_distfile( | ||
ARCHIVE | ||
URLS https://ftp.gnu.org/gnu/readline/readline-8.1.tar.gz | ||
FILENAME readline-8.1.tar.gz | ||
SHA512 27790d0461da3093a7fee6e89a51dcab5dc61928ec42e9228ab36493b17220641d5e481ea3d8fee5ee0044c70bf960f55c7d3f1a704cf6b9c42e5c269b797e00 | ||
) | ||
|
||
vcpkg_extract_source_archive(SOURCE_PATH ARCHIVE "${ARCHIVE}") | ||
|
||
file( | ||
COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" | ||
DESTINATION "${SOURCE_PATH}") | ||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/config.h" DESTINATION "${SOURCE_PATH}") | ||
|
||
vcpkg_cmake_configure(SOURCE_PATH "${SOURCE_PATH}") | ||
|
||
vcpkg_cmake_install() | ||
|
||
file(MAKE_DIRECTORY "${CURRENT_PACKAGES_DIR}/include/readline") | ||
file(GLOB headers "${SOURCE_PATH}/*.h") | ||
file(COPY ${headers} DESTINATION "${CURRENT_PACKAGES_DIR}/include/readline") | ||
|
||
file( | ||
INSTALL "${SOURCE_PATH}/COPYING" | ||
DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" | ||
RENAME copyright) |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there are some problems here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you be more specific?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can confirm that those 2 macros are only supported in Windows. I checked the source code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In readline.h or rlstdc.h:
You can see thoses 2 macros are only avaliable in Windows build.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see you already addressed in #22321