Opened 10 years ago

Closed 10 years ago

#26864 closed defect (fixed)

atlas @3.8.3 build fails with #error Use the "-maltivec" flag to enable PowerPC AltiVec support

Reported by: jpmasseria@… Owned by: jameskyle@…
Priority: Normal Milestone:
Component: ports Version: 1.9.1
Keywords: Cc: Veence (Vincent)
Port: atlas

Description

I am new to the Mac and also Macports.

I'm actually trying to install gedit which for some reason requires many ports including atlas.

My install of atlas fails with the following error in the error log:

#error Use the "-maltivec" flag to enable PowerPC AltiVec support

I'm running Mac OS X version 10.4.11 on an eMac with a 700 MHz PowerPC G4.

I'm following up on this as an intellectual exercise as I am interested in understanding what's going on.

I have performed:

sudo port -d selfupdate

sudo port clean --all atlas

sudo port install atlas

Attachments (1)

main.log (264.4 KB) - added by jpmasseria@… 10 years ago.

Download all attachments as: .zip

Change History (19)

Changed 10 years ago by jpmasseria@…

Attachment: main.log added

comment:1 Changed 10 years ago by jpmasseria@…

I have Xcode 2.5 installed.

comment:2 Changed 10 years ago by jmroot (Joshua Root)

Owner: changed from macports-tickets@… to jameskyle@…

Please remember to cc the maintainer.

comment:3 Changed 10 years ago by jpmasseria@…

Cc: jpmasseria@… added

Cc Me!

comment:4 Changed 10 years ago by jpmasseria@…

I was finally able to figure out the problem. The computer I'm using is an eMac that returns "hw.model: PowerMac4,4" for sysctl hw.model

Therefore I had to change the patch for archinfo_freebsd.c to include strstr(res,"c4,4") as shown below:

--- CONFIG/src/backend/archinfo_freebsd.c.orig  2009-02-18 18:47:37.000000000 +0000
+++ CONFIG/src/backend/archinfo_freebsd.c       2010-01-01 11:45:22.000000000 +0000
@@ -69,7 +69,7 @@
             if (strstr(res,"c1,2")||strstr(res,"c3,1")||strstr(res,"c3,2")||
                 strstr(res,"c3,3")||strstr(res,"c3,4")||strstr(res,"c3,5")||
                 strstr(res,"c3,6")||strstr(res,"c4,2")||strstr(res,"c4,5")||
-                strstr(res,"c5,1"))
+                strstr(res,"c5,1")||strstr(res,"c10,1")||strstr(res,"c4,4"))
                mach = PPCG4;
             else if (strstr(res,"c11,2")|| strstr(res,"c12,1")||
                      strstr(res,"c7,2") || strstr(res,"c7,3") ||

The log file now shows:

:info:configure               flibchkF.o -l gfortran -lm
:info:configure rm -f *core* *.o config?.out
:info:configure 
:info:configure OS configured as OSX (11)
:info:configure 
:info:configure Assembly configured as GAS_PPC (4)
:info:configure 
:info:configure Vector ISA Extension configured as  AltiVec (1,2)
:info:configure 
:info:configure Architecture configured as  PPCG4 (4)
:info:configure 
:info:configure Clock rate configured as 700Mhz
:info:configure 
:info:configure Maximum number of threads configured as  1
:info:configure Cannot detect CPU throttling.

The build is still running, but I am confident that I have overcome the "-maltivec" flag issue as I can see compiles in the log file now using this option.

I will post my final results later when the build finishes.

John

comment:5 Changed 10 years ago by jpmasseria@…

Success! Clean build!

:info:build ATLAS install complete.  Examine 
:info:build ATLAS/bin/<arch>/INSTALL_LOG/SUMMARY.LOG for details.
:info:build /usr/bin/make clean

The if statement in archinfo_freebsd.c needs to include strstr(res,"c4,4") for the eMac.

I'm a novice at this so I need to research how to build an official patch and changeset for this.

John

comment:6 Changed 10 years ago by ryandesign (Ryan Schmidt)

Cc: jpmasseria@… removed

Is this still a problem with atlas 3.9.33?

comment:7 Changed 10 years ago by Veence (Vincent)

Resolution: invalid
Status: newclosed

Since there is no answer, I close the bug as invalid. Reopen it if this still fails with 3.9.35.

comment:8 Changed 10 years ago by jpmasseria@…

Resolution: invalid
Status: closedreopened

Sorry for the late response.

3.9.35 still fails for me on my eMac.

I had to apply the following patch to get it to work:

--- CONFIG/src/backend/archinfo_freebsd.c.orig  2009-02-18 18:47:37.000000000 +0000
+++ CONFIG/src/backend/archinfo_freebsd.c       2010-01-01 11:45:22.000000000 +0000
@@ -69,7 +69,7 @@
             if (strstr(res,"c1,2")||strstr(res,"c3,1")||strstr(res,"c3,2")||
                 strstr(res,"c3,3")||strstr(res,"c3,4")||strstr(res,"c3,5")||
                 strstr(res,"c3,6")||strstr(res,"c4,2")||strstr(res,"c4,5")||
-                strstr(res,"c5,1")||strstr(res,"c10,1"))
+                strstr(res,"c5,1")||strstr(res,"c10,1")||strstr(res,"c4,4"))
                mach = PPCG4;
             else if (strstr(res,"c11,2")|| strstr(res,"c12,1")||
                      strstr(res,"c7,2") || strstr(res,"c7,3") ||

But now I'm getting a different error later in the build process. I'm investigating that.

John

comment:9 Changed 10 years ago by jpmasseria@…

I think now I have the problem described in Ticket #28413.

I just fetched 3.9.37 using:

sudo port fetch atlas @3.9.37

Bottom line is that for an eMac to work you need to include the change I previously documented.

--- CONFIG/src/backend/archinfo_freebsd.c.orig  2009-02-18 18:47:37.000000000 +0000
+++ CONFIG/src/backend/archinfo_freebsd.c       2010-01-01 11:45:22.000000000 +0000
@@ -69,7 +69,7 @@
             if (strstr(res,"c1,2")||strstr(res,"c3,1")||strstr(res,"c3,2")||
                 strstr(res,"c3,3")||strstr(res,"c3,4")||strstr(res,"c3,5")||
                 strstr(res,"c3,6")||strstr(res,"c4,2")||strstr(res,"c4,5")||
-                strstr(res,"c5,1")||strstr(res,"c10,1"))
+                strstr(res,"c5,1")||strstr(res,"c10,1")||strstr(res,"c4,4"))
                mach = PPCG4;
             else if (strstr(res,"c11,2")|| strstr(res,"c12,1")||
                      strstr(res,"c7,2") || strstr(res,"c7,3") ||

John

comment:10 Changed 10 years ago by jpmasseria@…

Success! Atlas @3.9.37 built without error for me with the patch shown above.

jordyn-masserias-emac:~ jordynmasseria$ sudo port build atlas
Password:
--->  Computing dependencies for atlas
--->  Building atlas
jordyn-masserias-emac:~ jordynmasseria$ sudo port install atlas
Password:
--->  Computing dependencies for atlas
--->  Staging atlas into destroot
--->  Installing atlas @3.9.37_0+gcc44
--->  Activating atlas @3.9.37_0+gcc44
--->  Cleaning atlas
jordyn-masserias-emac:~ jordynmasseria$ 
hw.machine = Power Macintosh
hw.model = PowerMac4,4

John

comment:11 Changed 10 years ago by jmroot (Joshua Root)

Cc: vince@… added

comment:12 Changed 10 years ago by Veence (Vincent)

I have committed the patch in r76544. Thanks for digging this out! Please try again, and tell me if it is okay so we can close this bug.

comment:13 Changed 10 years ago by Veence (Vincent)

Resolution: fixed
Status: reopenedclosed

I close this bug. If you're still encountering the same error, reopen it.

comment:14 Changed 10 years ago by jpmasseria@…

Resolution: fixed
Status: closedreopened

Hello Vince,

I reopened this because this is still a problem. You can not build Atlas on a Macintosh eMac without the following patch:

--- CONFIG/src/backend/archinfo_freebsd.c.orig  2009-02-18 18:47:37.000000000 +0000
+++ CONFIG/src/backend/archinfo_freebsd.c       2010-01-01 11:45:22.000000000 +0000
@@ -69,7 +69,7 @@
             if (strstr(res,"c1,2")||strstr(res,"c3,1")||strstr(res,"c3,2")||
                 strstr(res,"c3,3")||strstr(res,"c3,4")||strstr(res,"c3,5")||
                 strstr(res,"c3,6")||strstr(res,"c4,2")||strstr(res,"c4,5")||
-                strstr(res,"c5,1")||strstr(res,"c10,1"))
+                strstr(res,"c5,1")||strstr(res,"c10,1")||strstr(res,"c4,4"))
                mach = PPCG4;
             else if (strstr(res,"c11,2")|| strstr(res,"c12,1")||
                      strstr(res,"c7,2") || strstr(res,"c7,3") ||

Please integrate this patch into a future version of atlas.

Thank you, John

comment:15 Changed 10 years ago by jmroot (Joshua Root)

That patch is already integrated. Check the link in comment:12.

comment:16 Changed 10 years ago by Veence (Vincent)

Resolution: invalid
Status: reopenedclosed

comment:17 Changed 10 years ago by jpmasseria@…

Resolution: invalid
Status: closedreopened

Hi Vince,

Yes you are right, somehow I missed your comment #12. Thanks for integrating the patch.

I'm not sure what an invalid resolution means, I guess I messed up the bug report when I reopened it on 3/2. I thought that it had been set to invalid instead of fixed.

Thanks again, Shouldn't you close this as fixed? John

comment:18 Changed 10 years ago by jmroot (Joshua Root)

Resolution: fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.