[libc-commits] [libc] 5252aa2 - [libc][obvious] Make *abs and *div functions buildable in default mode.

Siva Chandra Reddy via libc-commits libc-commits at lists.llvm.org
Sun Sep 19 22:46:01 PDT 2021


Author: Siva Chandra Reddy
Date: 2021-09-20T05:44:49Z
New Revision: 5252aa2981ba19417b3ea68b22e8be33d5623368

URL: https://github.com/llvm/llvm-project/commit/5252aa2981ba19417b3ea68b22e8be33d5623368
DIFF: https://github.com/llvm/llvm-project/commit/5252aa2981ba19417b3ea68b22e8be33d5623368.diff

LOG: [libc][obvious] Make *abs and *div functions buildable in default mode.

Added: 
    

Modified: 
    libc/src/stdlib/CMakeLists.txt

Removed: 
    


################################################################################
diff  --git a/libc/src/stdlib/CMakeLists.txt b/libc/src/stdlib/CMakeLists.txt
index 4f676129dbd39..d787bdf1b81b4 100644
--- a/libc/src/stdlib/CMakeLists.txt
+++ b/libc/src/stdlib/CMakeLists.txt
@@ -68,33 +68,6 @@ add_entrypoint_object(
     libc.src.__support.str_conv_utils
 )
 
-if(NOT LLVM_LIBC_FULL_BUILD)
-  return()
-endif()
-
-if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
-  add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
-endif()
-
-add_entrypoint_object(
-  _Exit
-  ALIAS
-  DEPENDS
-    .${LIBC_TARGET_OS}._Exit
-)
-
-add_entrypoint_object(
-  abort
-  SRCS
-    abort.cpp
-  HDRS
-    abort.h
-  DEPENDS
-    libc.include.stdlib
-    libc.src.signal.raise
-    ._Exit
-)
-
 add_entrypoint_object(
   abs
   SRCS
@@ -154,3 +127,30 @@ add_entrypoint_object(
   DEPENDS
     libc.src.__support.integer_operations
 )
+
+if(NOT LLVM_LIBC_FULL_BUILD)
+  return()
+endif()
+
+if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
+  add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
+endif()
+
+add_entrypoint_object(
+  _Exit
+  ALIAS
+  DEPENDS
+    .${LIBC_TARGET_OS}._Exit
+)
+
+add_entrypoint_object(
+  abort
+  SRCS
+    abort.cpp
+  HDRS
+    abort.h
+  DEPENDS
+    libc.include.stdlib
+    libc.src.signal.raise
+    ._Exit
+)


        


More information about the libc-commits mailing list