fix: recompile in the install section 33/298833/1 accepted/tizen/8.0/unified/20231005.095456 accepted/tizen/unified/20230914.164944
authorHyunggi Lee <hyunggi.lee@samsung.com>
Thu, 14 Sep 2023 04:47:42 +0000 (13:47 +0900)
committerHyunggi Lee <hyunggi.lee@samsung.com>
Thu, 14 Sep 2023 05:02:19 +0000 (14:02 +0900)
In the install section, I wanted to install the file built in the build section,
but the build is executed again.
CFLAGS values are not the same, changing compilation options causes rebuild
So, fix it by setting the environment variables the same as build section.

Change-Id: I7b5e7b4e782e22afbfdf5947fd2be94ca13e216a
Signed-off-by: Hyunggi Lee <hyunggi.lee@samsung.com>
packaging/python3-numpy.spec

index 2f22b701f44cb16120e87cab76b355e225a43a40..4053fad5ec467456ecde60a915b90ab565f09696 100644 (file)
@@ -52,6 +52,9 @@ export G_SLICE=always-malloc
 %{_bindir}/python3 setup.py build
 
 %install
+# https://github.com/numpy/numpy/issues/16005
+# if the CFLAGS is not set the same as the build section, the build will be performed again during installation.
+export CFLAGS="%{optflags} -fno-strict-aliasing"
 export G_SLICE=always-malloc
 %{_bindir}/python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}