In Ubuntu system operation, Pacman is a package manager that can manage the official Arch library and its own created packages, but sometimes it will go wrong when installing Pacman. The following small series will introduce you to how Ubuntu installs Pacman.
1, wget & lsquo; ftp: //ftp.archlinux.org/other/pacman/pacman-4.1.2.tar.gz’ download package
2, tar Xvf pacman-4.1.2.tar.gz, decompression software
3, cd pacman-4.1.2/, enter the code, execute. /configure, the prompt does not have libarchive
4, execute sudo apt-get libarchive-dev install libarchive
5, execute again. /configure, execute 6, error, error ---------------------------- -------------------------------------------------- - CC libalpm_la-be_sync.lo be_sync.c: In function ‘_alpm_validate_filename’: be_sync.c:499: error: ‘PATH_MAX’ undeclared ( First use in this function) be_sync.c:499: error: (Each undeclared identifier is reported only once be_sync.c:499: error: for each function it appears in.) make[3]: *** [libalpm_la-be_sync.lo] Error 1 make[2]: *** [all-recursive] Error 1 Make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2 ------------- -------------------------------------------------- ----------------- 7, gedit lib/libalpm/be_sync.c, code files, find the code ----- --------------------------------------- ----------------------------------- static int _alpm_validate_filename(alpm_db_t *db, const Char *pkgname, const char *filename) { size_t len = strlen(filename); if(filename[0] == ‘. ’) { errno = EINVAL; _alpm_log(db-"handle, ALPM_LOG_ERROR, _(“%s database is inconsistent: filename ” “ Of package %s is illegal\ ”), db-"treename, pkgname); return -1; } else if(memchr(filename, ‘/’, len ) == NULL) { errno = EINVAL; _alpm_log(db-"handle, ALPM_LOG_ERROR, _(“%s database is inconsistent: filename ” “of package %s is illegal\ ”), db-"treename, pkgname); return -1; } else if(len PATH PATH_MAX { errno = EINVAL; _alpm_log(db-"handle, ALPM_LOG_ERROR, _(“%s database is inconsistent: filename ” “of package %s is too long\ ”), db-"treename, pkgname); return -1; } return 0; } ----------------------------------------------- -------------------------------- Amend the following ---- -------------------------------------------------- ------------------------- static int _alpm_validate_filename(alpm_db_t *db, const char *pkgname, Const char *filename) { size_t len = strlen(filename); if(filename[0] == ‘. ’) { errno = EINVAL; _alpm_log(db-"handle, ALPM_LOG_ERROR, _(“%s database is inconsistent: filename ” “ Of package %s is illegal\ ”), db-"treename, pkgname); return -1; } else if(memchr(filename, ‘/’, len ) == NULL) { errno = EINVAL; _alpm_log(db-"handle, ALPM_LOG_ERROR, _(“%s database is inconsistent: filename ” “of package %s is illegal\ ”), db-"treename, pkgname); return -1; } /* else if(len PATH_MAX) { errno = EINVAL; _alpm_log(db-》handle, ALPM_LOG_ERROR, _(“%s database is inconsistent: filename ” “of package %s is too long\ ”), db-"treename, pkgname); return -1; } * / Return 0; } ---------------------------------- --------------------------------------------- Save, exit 8. Execute make&& make install and wait for the installation to complete. The above is the introduction of Ubuntu Pacman installation method, usually the installation will be executed when the make error, after the error, follow the code described in this article to install, and finally execute make && make install to complete the installation.
Debian system, some packages can not be deleted for some reason, very troublesome when cleaning up t
After the Linux system has been in operation for a long time, it will generate a lo
Recently, many Linux users have experienced problems when using OpenSSH. The soluti
Some Red Flag Linux users upgraded the system from 4.1 to 5 and found that after installing SAPGUI,
Linux method for copying files/folders using CP commands
How to solve the Linux system Tail command prompt No space left on device problem
How Linux uses the at command to perform tasks
How to fix the program error prompted by Ubuntu system?
Linux to see if the system is attacked by cc
How to install different versions of Linux system on the same computer
What should I do if Linux vi is stuck?
How to use the chown command to change the owner of the Linux file
Linux system management disk and file method
How to solve the slow start of the win10 system computer?
Let the mouse call the Windows 7 stereo window
Win7 system computer too card page loading slow how to do
How to quickly open the Charm column in Win10 system
Linux modify file and directory permissions chmod
How to let win8.1 Enterprise Edition keep the original installer and files after upgrading win10
How to activate win10 Enterprise Edition system
Boot Startup Item Settings Tutorial