aix

Header files not found when porting from AIX to linux

放肆的年华 提交于 2019-12-13 03:49:54
问题 I am got source files from an application on IBM AIX and I am trying to build them on Linux. However I am getting compilation errors header file not found. When compiled source from AIX on Linux got error these headers not found: usersec.h userpw.h sys/mode.h standards.h After I Googled I realized they are headers ( /usr/include/usersec.h ) for user management (user authentication and pwd verification etc) funtions on AIX. As there is no equivalent header on Linux, I like to know what is best

Python 2.7.5, import random is throwing error on AIX platfrom

拈花ヽ惹草 提交于 2019-12-13 03:27:50
问题 I am not able to do "import random" in python 2.7.5 on AIX operating system. It throws the following exceptions. Python 2.7.5 (default, Aug 2 2013, 23:28:11) [C] on aix6 Type "help", "copyright", "credits" or "license" for more information. >>> import random ERROR:root:code for hash md5 was not found. Traceback (most recent call last): File "/opt/freeware/lib/python2.7/hashlib.py", line 139, in <module> globals()[__func_name] = __get_hash(__func_name) File "/opt/freeware/lib/python2.7/hashlib

Migrating AIX specific C function calls to Linux

可紊 提交于 2019-12-13 03:26:42
问题 I have got source files from an application on IBM AIX and I am trying to build them on Linux. However, header files named usersec.h and userpw.h which are there on AIX are not present on Linux. Hence, on Linux I am getting compiler error for these functions: Declared in usersec.h int getuserattr (char *, char *, void *, int); More info about getuserattr is here Declared in userpw.h struct userpw { char *upw_passwd; /* user's passwd */ unsigned int upw_flags; /* flags of restrictions */ time

How do I configure ruby to compile in 64 bit mode on AIX

不羁岁月 提交于 2019-12-13 02:37:28
问题 I downloaded ruby 2.0.0 and ran ./configure make make install On a 64 bit linux machine this build a 64 bit version. On AIX, this built a 32 bit version. How do I configure it to compile in 64 bit mode? I tried export OBJECT_MODE=64 ./configure but it failed with checking for gcc... gcc checking whether the C compiler works... no Update: I managed to get this to compile with the following: export OBJECT_MODE=64 ## not sure if I needed this or not ./configure --disable-install-doc CC="gcc"

Regex limit in ruby 64 bit aix compilation

馋奶兔 提交于 2019-12-12 21:08:18
问题 I have compiled ruby 64 bit on an AIX Box. There doesn't seem to be any issue except when I use some specific regular expressions in my code. Here is an example: /([0-9]){1000}/.match("2") results in: RegexpError: too big quantifier in {,}: /([0-9]*){1000}/ When I try reducing the number of repetitions, it seems to work. I tried digging into the ruby code. But could not understand the reason. Is this some dependency or restriction that we have in AIX/64 bit ruby? Thanks in advance :) 回答1: I

Shell script to email results of SQLPlus query using Mailx in AIX

倾然丶 夕夏残阳落幕 提交于 2019-12-12 18:00:52
问题 I have the commands that I need. If I execute these commands at the prompt, everything works as expected. SQLPlus runs the query, exports the result to a file and then Mailx emails that file to me. sqlplus username/pwd@instance SPOOL /home/sadmin/sqlmail/spool.out set linesize 2000 set wrap off @/home/sadmin/sqlmail/query.sql SPOOL OFF exit mail -s "Subject" email@address.com < /home/sadmin/sqlmail/spool.out But, I can not, for the life of me, figure out how to put these in an .sh file so

How to autocomplete at the KornShell command line with the vi editor

流过昼夜 提交于 2019-12-12 08:47:33
问题 In the KornShell (ksh) on AIX UNIX Version 5.3 with the editor mode set to vi using: set -o vi What are the key-strokes at the shell command line to autocomplete a file or directory name? 回答1: ESC\ works fine on AIX4.2 at least. One thing I noticed is that it only autocompletes to the unique part of the file name. So if you have the files x.txt, x171go and x171stop, the following will happen: Press keys: Command line is: x x <ESC>\ x 1 x1 <ESC>\ x171 g<ESC>\ x171go 回答2: Extending the other

Change PS1 after running the 'script' command

不打扰是莪最后的温柔 提交于 2019-12-12 05:36:33
问题 I am looking to create a logging system for every command and some timestamps. I think the "script" command would be the best because you get a log of the input and output. Now the problem is when I start the script command the PS1 (the command line prompt, which shows the user and PWD ) gets changed from: PS1=`echo $LOGNAME`@`hostname`:'$PWD# ' to PS1=\s-\v\$ and I can't see to get it to switch back. I have tried to change it in both /etc/profile (where the script command is called) and in

Incorrect shared libraries picked in AIX

痴心易碎 提交于 2019-12-12 04:59:34
问题 While building a particular module, I get the below error: ld: 0711-317 ERROR: Undefined symbol: .MD5_Init ld: 0711-317 ERROR: Undefined symbol: .SHA1_Init ld: 0711-317 ERROR: Undefined symbol: .SHA224_Init ld: 0711-317 ERROR: Undefined symbol: .SHA256_Init ld: 0711-317 ERROR: Undefined symbol: .SHA384_Init ld: 0711-317 ERROR: Undefined symbol: .SHA512_Init ld: 0711-317 ERROR: Undefined symbol: .SHA1_Update ld: 0711-317 ERROR: Undefined symbol: .SHA1_Final ld: 0711-317 ERROR: Undefined symbol

Using 32-bit g++ to build 64-bit binaries on AIX

自古美人都是妖i 提交于 2019-12-12 04:48:16
问题 I am trying to build a 64-bit binary from C++ code using 32-bit g++ compiler. I am getting the following errors while building: => /usr/local/bin/g++ -shared -maix64 -fPIC -Wl,-bM:SRE -Wl,-bnoentry -Wl,-bE:gcc_shr_lib.so.exp -o gcc_shr_lib.so gcc_shr_lib.o -L/usr/local/lib ld: 0711-319 WARNING: Exported symbol not defined: gcc_whereAmI ld: 0711-317 ERROR: Undefined symbol: typeinfo for std::bad_alloc ld: 0711-317 ERROR: Undefined symbol: __gxx_personality_v0 ld: 0711-317 ERROR: Undefined