Sirs:

Please note initially that the error indicated occurs systematically in the 
actual project, but it was reproduced here using a simpler demonstration case 
for documentation.

I might have to defer to www.kernel.org || gcc.gnu.org depending upon your 
comments, as I feel that it is not Cygwin-related per se and any advice at this 
junction is well come.
It seems that world knows something about this situation that escapes me 
entirely...

If it is the case, I am happy to offer additional contextual info upon request.

As a very important observation, please note that gcc is invoked with 
'-fno-PIE' as one its arguments, despite the error message!

Attachment: cygcheck.out
Description: Binary data

09:22:33 **** Build of configuration Default for project 
LinuxDeviceDriversDevelopment-code ****
make 
/usr/bin/make V=1 -C C:/Users/Richard/progs/Cygwin/cygwin64/usr/src/linux 
M=$PWD modules
/usr/bin/make -f ./scripts/Makefile.build 
obj=/cygdrive/c/Users/Richard/eclipse-workspace/LinuxDeviceDriversDevelopment-code/Chapter02
 \
single-build= \
need-builtin=1 need-modorder=1
  gcc 
-Wp,-MD,/cygdrive/c/Users/Richard/eclipse-workspace/LinuxDeviceDriversDevelopment-code/Chapter02/.helloworld-params.o.d
 -nostdinc -isystem /usr/lib/gcc/x86_64-pc-cygwin/12/include  
-I./arch/x86/include -I./arch/x86/include/generated  -I./include 
-I./arch/x86/include/uapi -I./arch/x86/include/generated/uapi -I./include/uapi 
-I./include/generated/uapi -include ./include/linux/kconfig.h -Iubuntu/include  
-include ./include/linux/compiler_types.h -D__KERNEL__ -Wall -Wundef 
-Werror=strict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common 
-fshort-wchar -fno-PIE -Werror=implicit-function-declaration 
-Werror=implicit-int -Werror=return-type -Wno-format-security -std=gnu89 
-mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -fcf-protection=none -m64 
-falign-jumps=1 -falign-loops=1 -mno-80387 -mno-fp-ret-in-387 
-mpreferred-stack-boundary=3 -mskip-rax-setup -mtune=generic -mno-red-zone 
-mcmodel=kernel -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 
-DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_AVX=1 
-DCONFIG_AS_AVX2=1 -DCONFIG_AS_AVX512=1 -DCONFIG_AS_SHA1_NI=1 
-DCONFIG_AS_SHA256_NI=1 -Wno-sign-compare -fno-asynchronous-unwind-tables 
-mindirect-branch=thunk-extern -mindirect-branch-register -O2 
-fno-stack-protector -fomit-frame-pointer -Wdeclaration-after-statement -Wvla 
-Wno-pointer-sign  -DMODULE  -DKBUILD_BASENAME='"helloworld_params"' 
-DKBUILD_MODNAME='"helloworld_params"' -c -o 
/cygdrive/c/Users/Richard/eclipse-workspace/LinuxDeviceDriversDevelopment-code/Chapter02/helloworld-params.o
 
/cygdrive/c/Users/Richard/eclipse-workspace/LinuxDeviceDriversDevelopment-code/Chapter02/helloworld-params.c
cc1: error: code model kernel does not support PIC mode
make[2]: *** [scripts/Makefile.build:270: 
/cygdrive/c/Users/Richard/eclipse-workspace/LinuxDeviceDriversDevelopment-code/Chapter02/helloworld-params.o]
 Error 1
make[1]: *** [Makefile:1778: 
/cygdrive/c/Users/Richard/eclipse-workspace/LinuxDeviceDriversDevelopment-code/Chapter02]
 Error 2
make: *** [Makefile:12: modules] Error 2
"make" terminated with exit code 2. Build might be incomplete.

09:23:15 Build Failed. 3 errors, 0 warnings. (took 41s.795ms)

-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

Reply via email to