Re: [PATCH] Add pcre2 support for cmake build system.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/19/22 12:18 PM, Yuyi Wang wrote:
> Junio C Hamano <gitster@xxxxxxxxx> wrote:
> 
>> Is this "small fix to ensure it builds successfully"?  To those who
>> do not need/want to use pcre2, is this hunk still needed to "build
>> successfully", or is this something that becomes necessary only
>> because we have other hunks in this patch to add support to pcre2?
>>
>> If the former, then perhaps the change deserves to be its own patch
>> with own explanation why it is necessary, what breaks without it,
>> etc.
> 
> There are 2 fixes. They are all needed no matter pcre2 is wanted. I'm
> rather surprised that no one has noticed the CMakeLists.txt is broken.
> 
>> @@ -54,7 +54,7 @@ set(CMAKE_SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/../..)
>>  
>>  option(USE_VCPKG "Whether or not to use vcpkg for obtaining dependencies.  Only applicable to Windows platforms" ON)
>>  if(NOT WIN32)
>> -	set(USE_VCPKG OFF CACHE BOOL FORCE)
>> +	set(USE_VCPKG OFF CACHE BOOL "" FORCE)
>>  endif()
>>  
>>  if(NOT DEFINED CMAKE_EXPORT_COMPILE_COMMANDS)
> 
> This is the first fix. The original line didn't follow the grammar
> of `set`, and would simply fail.
> 
>> @@ -277,7 +287,7 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
>>  
>>  elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
>>  	add_compile_definitions(PROCFS_EXECUTABLE_PATH="/proc/self/exe" HAVE_DEV_TTY )
>> -	list(APPEND compat_SOURCES unix-socket.c unix-stream-server.c)
>> +	list(APPEND compat_SOURCES unix-socket.c unix-stream-server.c compat/linux/procinfo.c)
>>  endif()
>>  
>>  if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
> 
> This is the second fix, to solve the linkage error on Linux.
> 
> You're right, Junio. These fixes should be their own patch.
> Should I remove them? They are still small fixes, I think,
> and could I submit the two together in a new patch?

You can rewrite your branch history to have two commits, force
push your branch, and the GGG pull request will then have two
commits. This will translate to two patches (along with a
cover letter) when you "/submit" again.

Here are some links that might help you in this process:

[1] https://www.youtube.com/watch?v=4qLtKx9S9a8
[2] https://render.com/blog/git-organized-a-better-git-flow

Thanks,
-Stolee



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux