?? objc.m4
字號:
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS# TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE# PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,# REPAIR OR CORRECTION.## 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING# WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR# REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,# INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING# OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED# TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY# YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER# PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE# POSSIBILITY OF SUCH DAMAGES.## END OF TERMS AND CONDITIONS## How to Apply These Terms to Your New Programs## If you develop a new program, and you want it to be of the greatest# possible use to the public, the best way to achieve this is to make it# free software which everyone can redistribute and change under these terms.## To do so, attach the following notices to the program. It is safest# to attach them to the start of each source file to most effectively# convey the exclusion of warranty; and each file should have at least# the "copyright" line and a pointer to where the full notice is found.## <one line to give the program's name and a brief idea of what it does.># Copyright (C) <year> <name of author>## This program is free software; you can redistribute it and/or modify# it under the terms of the GNU General Public License as published by# the Free Software Foundation; either version 2 of the License, or# (at your option) any later version.## This program is distributed in the hope that it will be useful,# but WITHOUT ANY WARRANTY; without even the implied warranty of# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the# GNU General Public License for more details.## You should have received a copy of the GNU General Public License# along with this program; if not, write to the Free Software# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA### Also add information on how to contact you by electronic and paper mail.## If the program is interactive, make it output a short notice like this# when it starts in an interactive mode:## Gnomovision version 69, Copyright (C) year name of author# Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.# This is free software, and you are welcome to redistribute it# under certain conditions; type `show c' for details.## The hypothetical commands `show w' and `show c' should show the appropriate# parts of the General Public License. Of course, the commands you use may# be called something other than `show w' and `show c'; they could even be# mouse-clicks or menu items--whatever suits your program.## You should also get your employer (if you work as a programmer) or your# school, if any, to sign a "copyright disclaimer" for the program, if# necessary. Here is a sample; alter the names:## Yoyodyne, Inc., hereby disclaims all copyright interest in the program# `Gnomovision' (which makes passes at compilers) written by James Hacker.## <signature of Ty Coon>, 1 April 1989# Ty Coon, President of Vice## This General Public License does not permit incorporating your program into# proprietary programs. If your program is a subroutine library, you may# consider it more useful to permit linking proprietary applications with the# library. If this is what you want to do, use the GNU Library General# Public License instead of this License.########### End of GNU General Public License (GPL), version 2 ############ ----------------------- #### 1. Language selection. #### ----------------------- ### ------------------------------ ## 1d. The Objective C language. ## ------------------------------ ## AC_LANG(Objective C)# --------------------# OBJCFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.m4_define([AC_LANG(Objective C)],[ac_ext=mac_cpp='$OBJCPP $CPPFLAGS'ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&AS_MESSAGE_LOG_FD'ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&AS_MESSAGE_LOG_FD'ac_compiler_gnu=$ac_cv_objc_compiler_gnu])# AC_LANG_OBJC# -------------------------AU_DEFUN([AC_LANG_OBJC], [AC_LANG(Objective C)])# _AC_LANG_ABBREV(Objective C)# ----------------------------m4_define([_AC_LANG_ABBREV(Objective C)], [objc])# _AC_LANG_PREFIX(Objective C)# ----------------------------m4_define([_AC_LANG_PREFIX(Objective C)], [OBJC])## ---------------------- #### 2.Producing programs. #### ---------------------- ### ------------------------- ## 2d. Objective C sources. ## ------------------------- ## AC_LANG_SOURCE(Objective C)(BODY)# ---------------------------------m4_copy([AC_LANG_SOURCE(C)], [AC_LANG_SOURCE(Objective C)])# AC_LANG_PROGRAM(Objective C)([PROLOGUE], [BODY])# ------------------------------------------------m4_copy([AC_LANG_PROGRAM(C)], [AC_LANG_PROGRAM(Objective C)])# AC_LANG_CALL(Objective C)(PROLOGUE, FUNCTION)# ---------------------------------------------m4_copy([AC_LANG_CALL(C)], [AC_LANG_CALL(Objective C)])# AC_LANG_FUNC_LINK_TRY(Objective C)(FUNCTION)# --------------------------------------------m4_copy([AC_LANG_FUNC_LINK_TRY(C)], [AC_LANG_FUNC_LINK_TRY(Objective C)])# AC_LANG_BOOL_COMPILE_TRY(Objective C)(PROLOGUE, EXPRESSION)# -----------------------------------------------------------m4_copy([AC_LANG_BOOL_COMPILE_TRY(C)], [AC_LANG_BOOL_COMPILE_TRY(Objective C)])# AC_LANG_INT_SAVE(Objective C)(PROLOGUE, EXPRESSION)# ---------------------------------------------------m4_copy([AC_LANG_INT_SAVE(C)], [AC_LANG_INT_SAVE(Objective C)])## -------------------------------------------- #### 3. Looking for Compilers and Preprocessors. #### -------------------------------------------- ### ------------------------------ ## 3d. The Objective C compiler. ## ------------------------------ ## AC_LANG_PREPROC(Objecitve C)# ----------------------------# Find the Objective C preprocessor. Must be AC_DEFUN'd to be AC_REQUIRE'able.AC_DEFUN([AC_LANG_PREPROC(Objective C)],[AC_REQUIRE([AC_PROG_OBJCPP])])# AC_PROG_OBJCPP# --------------# Find a working Objective C preprocessor.# We shouldn't have to require AC_PROG_CC, but this is due to the concurrency# between the AC_LANG_COMPILER_REQUIRE family and that of AC_PROG_OBJC.AC_DEFUN([AC_PROG_OBJCPP],[AC_REQUIRE([AC_PROG_OBJC])dnlAC_ARG_VAR([OBJCPP], [Objective C preprocessor])dnl_AC_ARG_VAR_CPPFLAGS()dnlAC_LANG_PUSH(Objective C)dnlAC_MSG_CHECKING([how to run the Objective C preprocessor])if test -z "$OBJCPP"; then AC_CACHE_VAL(ac_cv_prog_OBJCPP, [dnl # Double quotes because OBJCPP needs to be expanded for OBJCPP in "$OBJC -E" "/lib/cpp" do _AC_PROG_PREPROC_WORKS_IFELSE([break]) done ac_cv_prog_OBJCPP=$OBJCPP ])dnl OBJCPP=$ac_cv_prog_OBJCPPelse ac_cv_prog_OBJCPP=$OBJCPPfiAC_MSG_RESULT([$OBJCPP])_AC_PROG_PREPROC_WORKS_IFELSE([], [AC_MSG_FAILURE([Objective C preprocessor "$OBJCPP" fails sanity check])])AC_SUBST(OBJCPP)dnlAC_LANG_POP(Objective C)dnl])# AC_PROG_OBJCPP# AC_LANG_COMPILER(Objective C)# -----------------------------# Find the Objective C compiler. Must be AC_DEFUN'd to be AC_REQUIRE'able.AC_DEFUN([AC_LANG_COMPILER(Objective C)],[AC_REQUIRE([AC_PROG_OBJC])])# ac_cv_prog_objc# ---------------# We used to name the cache variable this way.AU_DEFUN([ac_cv_prog_objc],[ac_cv_objc_compiler_gnu])# AC_PROG_OBJC([LIST-OF-COMPILERS])# ---------------------------------# LIST-OF-COMPILERS is a space separated list of Objective C compilers# to search for (if not specified, a default list is used). This just gives# the user an opportunity to specify an alternative search list for the# Objective C compiler.# cc Native compiler# objc David Stes' Portable Object CompilerAN_MAKEVAR([OBJC], [AC_PROG_OBJC])AN_PROGRAM([gcc], [AC_PROG_OBJC])AN_PROGRAM([cc], [AC_PROG_OBJC])AC_DEFUN([AC_PROG_OBJC],[AC_LANG_PUSH(Objective C)dnlAC_ARG_VAR([OBJC], [Objective C compiler command])dnlAC_ARG_VAR([OBJCFLAGS], [Objective C compiler flags])dnl_AC_ARG_VAR_LDFLAGS()dnl_AC_ARG_VAR_CPPFLAGS()dnlAC_CHECK_TOOLS(OBJC, [$CCC m4_default([$1], [gcc cc objc])], gcc)# Provide some information about the compiler.echo "$as_me:$LINENO:" \ "checking for _AC_LANG compiler version" >&AS_MESSAGE_LOG_FDac_compiler=`set X $ac_compile; echo $[2]`_AC_EVAL([$ac_compiler --version </dev/null >&AS_MESSAGE_LOG_FD])_AC_EVAL([$ac_compiler -v </dev/null >&AS_MESSAGE_LOG_FD])_AC_EVAL([$ac_compiler -V </dev/null >&AS_MESSAGE_LOG_FD])m4_expand_once([_AC_COMPILER_EXEEXT])[]dnlm4_expand_once([_AC_COMPILER_OBJEXT])[]dnl_AC_LANG_COMPILER_GNUGOBJC=`test $ac_compiler_gnu = yes && echo yes`dnl _AC_PROG_OBJC_G_AC_PROG_OBJC_XAC_LANG_POP(Objective C)dnl])# AC_PROG_OBJC# _AC_PROG_OBJC_G# ---------------# Check whether -g works, even if OBJCFLAGS is set, in case the package# plays around with OBJCFLAGS (such as to build both debugging and# normal versions of a library), tasteless as that idea is.m4_define([_AC_PROG_OBJC_G],[ac_test_OBJCFLAGS=${OBJCFLAGS+set}ac_save_OBJCFLAGS=$OBJCFLAGSOBJCFLAGS="-g"AC_CACHE_CHECK(whether $OBJC accepts -g, ac_cv_prog_objc_g, [_AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], [ac_cv_prog_objc_g=yes], [ac_cv_prog_objc_g=no])])if test "$ac_test_OBJCFLAGS" = set; then OBJCFLAGS=$ac_save_OBJCFLAGSelif test $ac_cv_prog_objc_g = yes; then if test "$GOBJC" = yes; then OBJCFLAGS="-g -O2" else OBJCFLAGS="-g" fielse if test "$GOBJC" = yes; then OBJCFLAGS="-O2" else OBJCFLAGS= fifi[]dnl])# _AC_PROG_OBJC_G# _AC_PROG_OBJC_X# ---------------# Check whether -x objective-c worksm4_define([_AC_PROG_OBJC_X],[ac_test_OBJCFLAGS=${OBJCFLAGS+set}ac_save_OBJCFLAGS=$OBJCFLAGSOBJCFLAGS="$OBJCFLAGS -x objective-c"AC_CACHE_CHECK(whether $OBJC accepts -x objective-c, ac_cv_prog_objc_x, [_AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], [ac_cv_prog_objc_x=yes], [ac_cv_prog_objc_x=no])])if test $ac_cv_prog_objc_x = yes; then OBJCFLAGS="$ac_save_OBJCFLAGS -x objective-c"else OBJCFLAGS="$ac_save_OBJCFLAGS"fi[]dnl])# _AC_PROG_OBJC_X## ------------------------------- #### 4. Compilers' characteristics. #### ------------------------------- ### -------------------------------- ## 4b. C compiler characteristics. ## -------------------------------- ## libobjc and objc header tests shere?
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -